@unchainedshop/api 3.1.11 → 4.0.0-rc.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.
Files changed (690) hide show
  1. package/lib/context.d.ts +2 -2
  2. package/lib/context.d.ts.map +1 -1
  3. package/lib/context.js +1 -1
  4. package/lib/context.js.map +1 -1
  5. package/lib/createGraphQLServer.d.ts +2 -2
  6. package/lib/createGraphQLServer.d.ts.map +1 -1
  7. package/lib/errors.d.ts +2 -0
  8. package/lib/errors.d.ts.map +1 -1
  9. package/lib/errors.js +2 -0
  10. package/lib/errors.js.map +1 -1
  11. package/lib/express/createERCMetadataMiddleware.d.ts.map +1 -1
  12. package/lib/express/createERCMetadataMiddleware.js +9 -5
  13. package/lib/express/createERCMetadataMiddleware.js.map +1 -1
  14. package/lib/express/createMCPMiddleware.d.ts +8 -0
  15. package/lib/express/createMCPMiddleware.d.ts.map +1 -0
  16. package/lib/express/createMCPMiddleware.js +46 -0
  17. package/lib/express/createMCPMiddleware.js.map +1 -0
  18. package/lib/express/index.d.ts.map +1 -1
  19. package/lib/express/index.js +0 -2
  20. package/lib/express/index.js.map +1 -1
  21. package/lib/express/mcpHandler.d.ts.map +1 -0
  22. package/lib/express/mcpHandler.js +68 -0
  23. package/lib/express/mcpHandler.js.map +1 -0
  24. package/lib/fastify/ercMetadataHandler.d.ts.map +1 -1
  25. package/lib/fastify/ercMetadataHandler.js +9 -5
  26. package/lib/fastify/ercMetadataHandler.js.map +1 -1
  27. package/lib/fastify/index copy.d.ts.map +1 -0
  28. package/lib/fastify/index copy.js +157 -0
  29. package/lib/fastify/index copy.js.map +1 -0
  30. package/lib/fastify/index.d.ts.map +1 -1
  31. package/lib/fastify/index.js +0 -3
  32. package/lib/fastify/index.js.map +1 -1
  33. package/lib/fastify/mcpHandler.d.ts +8 -0
  34. package/lib/fastify/mcpHandler.d.ts.map +1 -0
  35. package/lib/fastify/mcpHandler.js +46 -0
  36. package/lib/fastify/mcpHandler.js.map +1 -0
  37. package/lib/loaders/assortmentLinkLoader.d.ts +12 -0
  38. package/lib/loaders/assortmentLinkLoader.d.ts.map +1 -0
  39. package/lib/loaders/assortmentLinkLoader.js +23 -0
  40. package/lib/loaders/assortmentLinkLoader.js.map +1 -0
  41. package/lib/loaders/assortmentLinksLoader.d.ts +14 -0
  42. package/lib/loaders/assortmentLinksLoader.d.ts.map +1 -0
  43. package/lib/loaders/assortmentLinksLoader.js +38 -0
  44. package/lib/loaders/assortmentLinksLoader.js.map +1 -0
  45. package/lib/loaders/assortmentLoader.d.ts +10 -0
  46. package/lib/loaders/assortmentLoader.d.ts.map +1 -0
  47. package/lib/loaders/assortmentLoader.js +15 -0
  48. package/lib/loaders/assortmentLoader.js.map +1 -0
  49. package/lib/loaders/assortmentMediaTextLoader.d.ts +12 -0
  50. package/lib/loaders/assortmentMediaTextLoader.d.ts.map +1 -0
  51. package/lib/loaders/assortmentMediaTextLoader.js +15 -0
  52. package/lib/loaders/assortmentMediaTextLoader.js.map +1 -0
  53. package/lib/loaders/assortmentMediasLoader.d.ts +10 -0
  54. package/lib/loaders/assortmentMediasLoader.d.ts.map +1 -0
  55. package/lib/loaders/assortmentMediasLoader.js +18 -0
  56. package/lib/loaders/assortmentMediasLoader.js.map +1 -0
  57. package/lib/loaders/assortmentProductLoader.d.ts +12 -0
  58. package/lib/loaders/assortmentProductLoader.d.ts.map +1 -0
  59. package/lib/loaders/assortmentProductLoader.js +14 -0
  60. package/lib/loaders/assortmentProductLoader.js.map +1 -0
  61. package/lib/loaders/assortmentProductsLoader.d.ts +10 -0
  62. package/lib/loaders/assortmentProductsLoader.d.ts.map +1 -0
  63. package/lib/loaders/assortmentProductsLoader.js +18 -0
  64. package/lib/loaders/assortmentProductsLoader.js.map +1 -0
  65. package/lib/loaders/assortmentTextLoader.d.ts +12 -0
  66. package/lib/loaders/assortmentTextLoader.d.ts.map +1 -0
  67. package/lib/loaders/assortmentTextLoader.js +15 -0
  68. package/lib/loaders/assortmentTextLoader.js.map +1 -0
  69. package/lib/loaders/buildTextMap.d.ts +2 -2
  70. package/lib/loaders/buildTextMap.d.ts.map +1 -1
  71. package/lib/loaders/countryLoader.d.ts +10 -0
  72. package/lib/loaders/countryLoader.d.ts.map +1 -0
  73. package/lib/loaders/countryLoader.js +14 -0
  74. package/lib/loaders/countryLoader.js.map +1 -0
  75. package/lib/loaders/currencyLoader.d.ts +10 -0
  76. package/lib/loaders/currencyLoader.d.ts.map +1 -0
  77. package/lib/loaders/currencyLoader.js +14 -0
  78. package/lib/loaders/currencyLoader.js.map +1 -0
  79. package/lib/loaders/deliveryProviderLoader.d.ts +10 -0
  80. package/lib/loaders/deliveryProviderLoader.d.ts.map +1 -0
  81. package/lib/loaders/deliveryProviderLoader.js +13 -0
  82. package/lib/loaders/deliveryProviderLoader.js.map +1 -0
  83. package/lib/loaders/fileLoader.d.ts +10 -0
  84. package/lib/loaders/fileLoader.d.ts.map +1 -0
  85. package/lib/loaders/fileLoader.js +13 -0
  86. package/lib/loaders/fileLoader.js.map +1 -0
  87. package/lib/loaders/filterLoader.d.ts +10 -0
  88. package/lib/loaders/filterLoader.d.ts.map +1 -0
  89. package/lib/loaders/filterLoader.js +14 -0
  90. package/lib/loaders/filterLoader.js.map +1 -0
  91. package/lib/loaders/filterTextLoader.d.ts +14 -0
  92. package/lib/loaders/filterTextLoader.d.ts.map +1 -0
  93. package/lib/loaders/filterTextLoader.js +15 -0
  94. package/lib/loaders/filterTextLoader.js.map +1 -0
  95. package/lib/loaders/index.d.ts +79 -49
  96. package/lib/loaders/index.d.ts.map +1 -1
  97. package/lib/loaders/index.js +47 -268
  98. package/lib/loaders/index.js.map +1 -1
  99. package/lib/loaders/languageLoader.d.ts +10 -0
  100. package/lib/loaders/languageLoader.d.ts.map +1 -0
  101. package/lib/loaders/languageLoader.js +14 -0
  102. package/lib/loaders/languageLoader.js.map +1 -0
  103. package/lib/loaders/orderLoader.d.ts +10 -0
  104. package/lib/loaders/orderLoader.d.ts.map +1 -0
  105. package/lib/loaders/orderLoader.js +16 -0
  106. package/lib/loaders/orderLoader.js.map +1 -0
  107. package/lib/loaders/paymentProviderLoader.d.ts +10 -0
  108. package/lib/loaders/paymentProviderLoader.d.ts.map +1 -0
  109. package/lib/loaders/paymentProviderLoader.js +13 -0
  110. package/lib/loaders/paymentProviderLoader.js.map +1 -0
  111. package/lib/loaders/productLoader.d.ts +10 -0
  112. package/lib/loaders/productLoader.d.ts.map +1 -0
  113. package/lib/loaders/productLoader.js +16 -0
  114. package/lib/loaders/productLoader.js.map +1 -0
  115. package/lib/loaders/productLoaderBySKU.d.ts +10 -0
  116. package/lib/loaders/productLoaderBySKU.d.ts.map +1 -0
  117. package/lib/loaders/productLoaderBySKU.js +16 -0
  118. package/lib/loaders/productLoaderBySKU.js.map +1 -0
  119. package/lib/loaders/productMediaTextLoader.d.ts +12 -0
  120. package/lib/loaders/productMediaTextLoader.d.ts.map +1 -0
  121. package/lib/loaders/productMediaTextLoader.js +15 -0
  122. package/lib/loaders/productMediaTextLoader.js.map +1 -0
  123. package/lib/loaders/productMediasLoader.d.ts +10 -0
  124. package/lib/loaders/productMediasLoader.d.ts.map +1 -0
  125. package/lib/loaders/productMediasLoader.js +18 -0
  126. package/lib/loaders/productMediasLoader.js.map +1 -0
  127. package/lib/loaders/productTextLoader.d.ts +12 -0
  128. package/lib/loaders/productTextLoader.d.ts.map +1 -0
  129. package/lib/loaders/productTextLoader.js +15 -0
  130. package/lib/loaders/productTextLoader.js.map +1 -0
  131. package/lib/loaders/userLoader.d.ts +10 -0
  132. package/lib/loaders/userLoader.d.ts.map +1 -0
  133. package/lib/loaders/userLoader.js +17 -0
  134. package/lib/loaders/userLoader.js.map +1 -0
  135. package/lib/loaders/utils.d.ts +7 -0
  136. package/lib/loaders/utils.d.ts.map +1 -0
  137. package/lib/loaders/utils.js +29 -0
  138. package/lib/loaders/utils.js.map +1 -0
  139. package/lib/locale-context.d.ts +3 -3
  140. package/lib/locale-context.d.ts.map +1 -1
  141. package/lib/locale-context.js +9 -10
  142. package/lib/locale-context.js.map +1 -1
  143. package/lib/mcp/index.d.ts +95 -0
  144. package/lib/mcp/index.d.ts.map +1 -0
  145. package/lib/mcp/index.js +138 -0
  146. package/lib/mcp/index.js.map +1 -0
  147. package/lib/mcp/server.d.ts +4 -0
  148. package/lib/mcp/server.d.ts.map +1 -0
  149. package/lib/mcp/server.js +60 -0
  150. package/lib/mcp/server.js.map +1 -0
  151. package/lib/mcp/types.d.ts +28 -0
  152. package/lib/mcp/types.d.ts.map +1 -0
  153. package/lib/mcp/types.js +2 -0
  154. package/lib/mcp/types.js.map +1 -0
  155. package/lib/middleware/accountLockout.d.ts.map +1 -0
  156. package/lib/middleware/accountLockout.js +84 -0
  157. package/lib/middleware/accountLockout.js.map +1 -0
  158. package/lib/middleware/rateLimiter.d.ts.map +1 -0
  159. package/lib/middleware/rateLimiter.js +91 -0
  160. package/lib/middleware/rateLimiter.js.map +1 -0
  161. package/lib/plugins/inputValidation.d.ts.map +1 -0
  162. package/lib/plugins/inputValidation.js +95 -0
  163. package/lib/plugins/inputValidation.js.map +1 -0
  164. package/lib/resolvers/mutations/accounts/createUser.d.ts.map +1 -1
  165. package/lib/resolvers/mutations/accounts/createUser.js +4 -5
  166. package/lib/resolvers/mutations/accounts/createUser.js.map +1 -1
  167. package/lib/resolvers/mutations/accounts/impersonate.js +1 -1
  168. package/lib/resolvers/mutations/accounts/impersonate.js.map +1 -1
  169. package/lib/resolvers/mutations/accounts/loginAsGuest.d.ts.map +1 -1
  170. package/lib/resolvers/mutations/accounts/loginAsGuest.js +4 -5
  171. package/lib/resolvers/mutations/accounts/loginAsGuest.js.map +1 -1
  172. package/lib/resolvers/mutations/accounts/loginWithPassword.js +3 -3
  173. package/lib/resolvers/mutations/accounts/loginWithPassword.js.map +1 -1
  174. package/lib/resolvers/mutations/accounts/loginWithWebAuthn.js +3 -3
  175. package/lib/resolvers/mutations/accounts/loginWithWebAuthn.js.map +1 -1
  176. package/lib/resolvers/mutations/accounts/resetPassword.js +3 -3
  177. package/lib/resolvers/mutations/accounts/resetPassword.js.map +1 -1
  178. package/lib/resolvers/mutations/accounts/stopImpersonation.js +1 -1
  179. package/lib/resolvers/mutations/accounts/stopImpersonation.js.map +1 -1
  180. package/lib/resolvers/mutations/accounts/verifyEmail.js +3 -3
  181. package/lib/resolvers/mutations/accounts/verifyEmail.js.map +1 -1
  182. package/lib/resolvers/mutations/assortments/reorderAssortmentFilters.d.ts +2 -2
  183. package/lib/resolvers/mutations/assortments/reorderAssortmentFilters.d.ts.map +1 -1
  184. package/lib/resolvers/mutations/assortments/reorderAssortmentFilters.js.map +1 -1
  185. package/lib/resolvers/mutations/assortments/reorderAssortmentLinks.d.ts +2 -2
  186. package/lib/resolvers/mutations/assortments/reorderAssortmentLinks.d.ts.map +1 -1
  187. package/lib/resolvers/mutations/assortments/reorderAssortmentLinks.js.map +1 -1
  188. package/lib/resolvers/mutations/assortments/reorderAssortmentMedia.d.ts +2 -2
  189. package/lib/resolvers/mutations/assortments/reorderAssortmentMedia.d.ts.map +1 -1
  190. package/lib/resolvers/mutations/assortments/reorderAssortmentMedia.js.map +1 -1
  191. package/lib/resolvers/mutations/assortments/reorderAssortmentProducts.d.ts +2 -2
  192. package/lib/resolvers/mutations/assortments/reorderAssortmentProducts.d.ts.map +1 -1
  193. package/lib/resolvers/mutations/assortments/reorderAssortmentProducts.js.map +1 -1
  194. package/lib/resolvers/mutations/assortments/updateAssortmentMediaTexts.d.ts +1 -1
  195. package/lib/resolvers/mutations/assortments/updateAssortmentMediaTexts.d.ts.map +1 -1
  196. package/lib/resolvers/mutations/assortments/updateAssortmentMediaTexts.js.map +1 -1
  197. package/lib/resolvers/mutations/assortments/updateAssortmentTexts.d.ts +1 -1
  198. package/lib/resolvers/mutations/assortments/updateAssortmentTexts.d.ts.map +1 -1
  199. package/lib/resolvers/mutations/assortments/updateAssortmentTexts.js.map +1 -1
  200. package/lib/resolvers/mutations/enrollments/createEnrollment.js +3 -3
  201. package/lib/resolvers/mutations/enrollments/createEnrollment.js.map +1 -1
  202. package/lib/resolvers/mutations/enrollments/updateEnrollment.d.ts +2 -2
  203. package/lib/resolvers/mutations/enrollments/updateEnrollment.d.ts.map +1 -1
  204. package/lib/resolvers/mutations/filters/createFilter.d.ts.map +1 -1
  205. package/lib/resolvers/mutations/filters/createFilter.js +2 -6
  206. package/lib/resolvers/mutations/filters/createFilter.js.map +1 -1
  207. package/lib/resolvers/mutations/filters/updateFilterTexts.d.ts +2 -2
  208. package/lib/resolvers/mutations/filters/updateFilterTexts.d.ts.map +1 -1
  209. package/lib/resolvers/mutations/orders/addCartDiscount.js +1 -1
  210. package/lib/resolvers/mutations/orders/addCartDiscount.js.map +1 -1
  211. package/lib/resolvers/mutations/orders/addCartProduct.js +1 -1
  212. package/lib/resolvers/mutations/orders/addCartProduct.js.map +1 -1
  213. package/lib/resolvers/mutations/orders/addCartQuotation.d.ts +2 -2
  214. package/lib/resolvers/mutations/orders/addCartQuotation.d.ts.map +1 -1
  215. package/lib/resolvers/mutations/orders/addCartQuotation.js +1 -1
  216. package/lib/resolvers/mutations/orders/addCartQuotation.js.map +1 -1
  217. package/lib/resolvers/mutations/orders/addMultipleCartProducts.d.ts +4 -4
  218. package/lib/resolvers/mutations/orders/addMultipleCartProducts.d.ts.map +1 -1
  219. package/lib/resolvers/mutations/orders/addMultipleCartProducts.js +1 -1
  220. package/lib/resolvers/mutations/orders/addMultipleCartProducts.js.map +1 -1
  221. package/lib/resolvers/mutations/orders/checkoutCart.js +1 -1
  222. package/lib/resolvers/mutations/orders/checkoutCart.js.map +1 -1
  223. package/lib/resolvers/mutations/orders/createCart.js +1 -1
  224. package/lib/resolvers/mutations/orders/createCart.js.map +1 -1
  225. package/lib/resolvers/mutations/orders/emptyCart.js +1 -1
  226. package/lib/resolvers/mutations/orders/emptyCart.js.map +1 -1
  227. package/lib/resolvers/mutations/orders/signPaymentProviderForCheckout.js +1 -1
  228. package/lib/resolvers/mutations/orders/signPaymentProviderForCheckout.js.map +1 -1
  229. package/lib/resolvers/mutations/orders/updateCart.js +1 -1
  230. package/lib/resolvers/mutations/orders/updateCart.js.map +1 -1
  231. package/lib/resolvers/mutations/orders/updateCartItem.d.ts +2 -2
  232. package/lib/resolvers/mutations/orders/updateCartItem.d.ts.map +1 -1
  233. package/lib/resolvers/mutations/products/addProductAssignment.d.ts +1 -1
  234. package/lib/resolvers/mutations/products/addProductAssignment.d.ts.map +1 -1
  235. package/lib/resolvers/mutations/products/addProductAssignment.js +35 -2
  236. package/lib/resolvers/mutations/products/addProductAssignment.js.map +1 -1
  237. package/lib/resolvers/mutations/products/createProductVariation.d.ts +2 -2
  238. package/lib/resolvers/mutations/products/createProductVariation.d.ts.map +1 -1
  239. package/lib/resolvers/mutations/products/createProductVariation.js.map +1 -1
  240. package/lib/resolvers/mutations/products/removeProductAssignment.d.ts +1 -1
  241. package/lib/resolvers/mutations/products/removeProductAssignment.d.ts.map +1 -1
  242. package/lib/resolvers/mutations/products/removeProductAssignment.js.map +1 -1
  243. package/lib/resolvers/mutations/products/reorderProductMedia.d.ts +2 -2
  244. package/lib/resolvers/mutations/products/reorderProductMedia.d.ts.map +1 -1
  245. package/lib/resolvers/mutations/products/reorderProductMedia.js.map +1 -1
  246. package/lib/resolvers/mutations/products/updateProductMediaTexts.d.ts +1 -1
  247. package/lib/resolvers/mutations/products/updateProductMediaTexts.d.ts.map +1 -1
  248. package/lib/resolvers/mutations/products/updateProductMediaTexts.js.map +1 -1
  249. package/lib/resolvers/mutations/products/updateProductVariationTexts.d.ts +1 -1
  250. package/lib/resolvers/mutations/products/updateProductVariationTexts.d.ts.map +1 -1
  251. package/lib/resolvers/mutations/quotations/requestQuotation.d.ts +2 -2
  252. package/lib/resolvers/mutations/quotations/requestQuotation.d.ts.map +1 -1
  253. package/lib/resolvers/mutations/quotations/requestQuotation.js +3 -3
  254. package/lib/resolvers/mutations/quotations/requestQuotation.js.map +1 -1
  255. package/lib/resolvers/mutations/users/heartbeat.d.ts +1 -1
  256. package/lib/resolvers/mutations/users/heartbeat.d.ts.map +1 -1
  257. package/lib/resolvers/mutations/users/heartbeat.js +3 -3
  258. package/lib/resolvers/mutations/users/heartbeat.js.map +1 -1
  259. package/lib/resolvers/mutations/users/setRoles.d.ts +1 -1
  260. package/lib/resolvers/mutations/users/setRoles.d.ts.map +1 -1
  261. package/lib/resolvers/mutations/users/setRoles.js.map +1 -1
  262. package/lib/resolvers/mutations/users/setUserTags.d.ts +1 -1
  263. package/lib/resolvers/mutations/users/setUserTags.d.ts.map +1 -1
  264. package/lib/resolvers/mutations/users/setUserTags.js.map +1 -1
  265. package/lib/resolvers/mutations/warehousing/invalidateToken.js +1 -3
  266. package/lib/resolvers/mutations/warehousing/invalidateToken.js.map +1 -1
  267. package/lib/resolvers/mutations/worker/allocateWork.d.ts +1 -1
  268. package/lib/resolvers/mutations/worker/allocateWork.d.ts.map +1 -1
  269. package/lib/resolvers/mutations/worker/allocateWork.js.map +1 -1
  270. package/lib/resolvers/queries/assortments/assortments.d.ts +1 -1
  271. package/lib/resolvers/queries/assortments/assortments.d.ts.map +1 -1
  272. package/lib/resolvers/queries/countries/countries.d.ts +1 -1
  273. package/lib/resolvers/queries/countries/countries.d.ts.map +1 -1
  274. package/lib/resolvers/queries/countries/countries.js.map +1 -1
  275. package/lib/resolvers/queries/currencies/currencies.d.ts +1 -1
  276. package/lib/resolvers/queries/currencies/currencies.d.ts.map +1 -1
  277. package/lib/resolvers/queries/currencies/currencies.js.map +1 -1
  278. package/lib/resolvers/queries/enrollments/enrollments.d.ts +1 -1
  279. package/lib/resolvers/queries/enrollments/enrollments.d.ts.map +1 -1
  280. package/lib/resolvers/queries/filters/filters.d.ts +1 -1
  281. package/lib/resolvers/queries/filters/filters.d.ts.map +1 -1
  282. package/lib/resolvers/queries/filters/searchAssortments.js +2 -2
  283. package/lib/resolvers/queries/filters/searchAssortments.js.map +1 -1
  284. package/lib/resolvers/queries/filters/searchProducts.js +3 -3
  285. package/lib/resolvers/queries/filters/searchProducts.js.map +1 -1
  286. package/lib/resolvers/queries/languages/languages.d.ts +1 -1
  287. package/lib/resolvers/queries/languages/languages.d.ts.map +1 -1
  288. package/lib/resolvers/queries/languages/languages.js.map +1 -1
  289. package/lib/resolvers/queries/orders/orders.d.ts +1 -1
  290. package/lib/resolvers/queries/orders/orders.d.ts.map +1 -1
  291. package/lib/resolvers/queries/orders/orders.js.map +1 -1
  292. package/lib/resolvers/queries/products/productReviews.d.ts +1 -1
  293. package/lib/resolvers/queries/products/productReviews.d.ts.map +1 -1
  294. package/lib/resolvers/queries/products/products.d.ts +1 -1
  295. package/lib/resolvers/queries/products/products.d.ts.map +1 -1
  296. package/lib/resolvers/queries/quotations/quotations.d.ts +1 -1
  297. package/lib/resolvers/queries/quotations/quotations.d.ts.map +1 -1
  298. package/lib/resolvers/queries/quotations/quotations.js.map +1 -1
  299. package/lib/resolvers/queries/users/impersonator.d.ts.map +1 -1
  300. package/lib/resolvers/queries/users/impersonator.js +1 -1
  301. package/lib/resolvers/queries/users/impersonator.js.map +1 -1
  302. package/lib/resolvers/queries/users/user.d.ts.map +1 -1
  303. package/lib/resolvers/queries/users/user.js.map +1 -1
  304. package/lib/resolvers/queries/users/users.d.ts +1 -1
  305. package/lib/resolvers/queries/users/users.d.ts.map +1 -1
  306. package/lib/resolvers/queries/worker/workQueue.d.ts +3 -3
  307. package/lib/resolvers/queries/worker/workQueue.d.ts.map +1 -1
  308. package/lib/resolvers/type/assortment/assortment-filter-types.d.ts +4 -8
  309. package/lib/resolvers/type/assortment/assortment-filter-types.d.ts.map +1 -1
  310. package/lib/resolvers/type/assortment/assortment-filter-types.js +4 -6
  311. package/lib/resolvers/type/assortment/assortment-filter-types.js.map +1 -1
  312. package/lib/resolvers/type/assortment/assortment-link-types.d.ts +2 -2
  313. package/lib/resolvers/type/assortment/assortment-link-types.d.ts.map +1 -1
  314. package/lib/resolvers/type/assortment/assortment-media-types.js +2 -2
  315. package/lib/resolvers/type/assortment/assortment-media-types.js.map +1 -1
  316. package/lib/resolvers/type/assortment/assortment-path-link-types.d.ts +2 -2
  317. package/lib/resolvers/type/assortment/assortment-path-link-types.d.ts.map +1 -1
  318. package/lib/resolvers/type/assortment/assortment-path-link-types.js +2 -2
  319. package/lib/resolvers/type/assortment/assortment-path-link-types.js.map +1 -1
  320. package/lib/resolvers/type/assortment/assortment-product-types.d.ts +2 -2
  321. package/lib/resolvers/type/assortment/assortment-product-types.d.ts.map +1 -1
  322. package/lib/resolvers/type/assortment/assortment-types.d.ts +2 -2
  323. package/lib/resolvers/type/assortment/assortment-types.d.ts.map +1 -1
  324. package/lib/resolvers/type/assortment/assortment-types.js +5 -5
  325. package/lib/resolvers/type/assortment/assortment-types.js.map +1 -1
  326. package/lib/resolvers/type/bookmark-types.d.ts.map +1 -1
  327. package/lib/resolvers/type/bookmark-types.js +2 -3
  328. package/lib/resolvers/type/bookmark-types.js.map +1 -1
  329. package/lib/resolvers/type/country-types.d.ts +1 -1
  330. package/lib/resolvers/type/country-types.d.ts.map +1 -1
  331. package/lib/resolvers/type/country-types.js +4 -7
  332. package/lib/resolvers/type/country-types.js.map +1 -1
  333. package/lib/resolvers/type/delivery-provider-types.d.ts +10 -13
  334. package/lib/resolvers/type/delivery-provider-types.d.ts.map +1 -1
  335. package/lib/resolvers/type/delivery-provider-types.js +8 -9
  336. package/lib/resolvers/type/delivery-provider-types.js.map +1 -1
  337. package/lib/resolvers/type/enrollment/enrollment-delivery-types.d.ts +2 -6
  338. package/lib/resolvers/type/enrollment/enrollment-delivery-types.d.ts.map +1 -1
  339. package/lib/resolvers/type/enrollment/enrollment-delivery-types.js +4 -3
  340. package/lib/resolvers/type/enrollment/enrollment-delivery-types.js.map +1 -1
  341. package/lib/resolvers/type/enrollment/enrollment-payment-types.d.ts +2 -6
  342. package/lib/resolvers/type/enrollment/enrollment-payment-types.d.ts.map +1 -1
  343. package/lib/resolvers/type/enrollment/enrollment-payment-types.js +2 -3
  344. package/lib/resolvers/type/enrollment/enrollment-payment-types.js.map +1 -1
  345. package/lib/resolvers/type/enrollment/enrollment-period-types.d.ts +2 -6
  346. package/lib/resolvers/type/enrollment/enrollment-period-types.d.ts.map +1 -1
  347. package/lib/resolvers/type/enrollment/enrollment-period-types.js +2 -3
  348. package/lib/resolvers/type/enrollment/enrollment-period-types.js.map +1 -1
  349. package/lib/resolvers/type/enrollment/enrollment-plan-tyes.d.ts +2 -6
  350. package/lib/resolvers/type/enrollment/enrollment-plan-tyes.d.ts.map +1 -1
  351. package/lib/resolvers/type/enrollment/enrollment-plan-tyes.js +2 -3
  352. package/lib/resolvers/type/enrollment/enrollment-plan-tyes.js.map +1 -1
  353. package/lib/resolvers/type/enrollment/enrollment-types.d.ts +15 -14
  354. package/lib/resolvers/type/enrollment/enrollment-types.d.ts.map +1 -1
  355. package/lib/resolvers/type/enrollment/enrollment-types.js +3 -6
  356. package/lib/resolvers/type/enrollment/enrollment-types.js.map +1 -1
  357. package/lib/resolvers/type/filter/filter-option-types.d.ts +6 -9
  358. package/lib/resolvers/type/filter/filter-option-types.d.ts.map +1 -1
  359. package/lib/resolvers/type/filter/filter-option-types.js +2 -3
  360. package/lib/resolvers/type/filter/filter-option-types.js.map +1 -1
  361. package/lib/resolvers/type/filter/filter-types.d.ts +16 -8
  362. package/lib/resolvers/type/filter/filter-types.d.ts.map +1 -1
  363. package/lib/resolvers/type/filter/filter-types.js +2 -3
  364. package/lib/resolvers/type/filter/filter-types.js.map +1 -1
  365. package/lib/resolvers/type/filter/loaded-filter-types.d.ts +2 -3
  366. package/lib/resolvers/type/filter/loaded-filter-types.d.ts.map +1 -1
  367. package/lib/resolvers/type/index.d.ts +273 -261
  368. package/lib/resolvers/type/index.d.ts.map +1 -1
  369. package/lib/resolvers/type/login-method-response-types.js +1 -1
  370. package/lib/resolvers/type/login-method-response-types.js.map +1 -1
  371. package/lib/resolvers/type/order/order-delivery-discount-types.d.ts +1 -1
  372. package/lib/resolvers/type/order/order-delivery-discount-types.d.ts.map +1 -1
  373. package/lib/resolvers/type/order/order-delivery-discount-types.js +1 -2
  374. package/lib/resolvers/type/order/order-delivery-discount-types.js.map +1 -1
  375. package/lib/resolvers/type/order/order-delivery-pickup-types.d.ts +13 -12
  376. package/lib/resolvers/type/order/order-delivery-pickup-types.d.ts.map +1 -1
  377. package/lib/resolvers/type/order/order-delivery-pickup-types.js +10 -14
  378. package/lib/resolvers/type/order/order-delivery-pickup-types.js.map +1 -1
  379. package/lib/resolvers/type/order/order-delivery-shipping-types.d.ts +12 -12
  380. package/lib/resolvers/type/order/order-delivery-shipping-types.d.ts.map +1 -1
  381. package/lib/resolvers/type/order/order-delivery-shipping-types.js +7 -10
  382. package/lib/resolvers/type/order/order-delivery-shipping-types.js.map +1 -1
  383. package/lib/resolvers/type/order/order-delivery-types.d.ts +1 -1
  384. package/lib/resolvers/type/order/order-delivery-types.d.ts.map +1 -1
  385. package/lib/resolvers/type/order/order-delivery-types.js +2 -3
  386. package/lib/resolvers/type/order/order-delivery-types.js.map +1 -1
  387. package/lib/resolvers/type/order/order-discount-types.d.ts +11 -13
  388. package/lib/resolvers/type/order/order-discount-types.d.ts.map +1 -1
  389. package/lib/resolvers/type/order/order-discount-types.js +9 -16
  390. package/lib/resolvers/type/order/order-discount-types.js.map +1 -1
  391. package/lib/resolvers/type/order/order-global-discount-types.d.ts +1 -1
  392. package/lib/resolvers/type/order/order-global-discount-types.d.ts.map +1 -1
  393. package/lib/resolvers/type/order/order-global-discount-types.js +1 -2
  394. package/lib/resolvers/type/order/order-global-discount-types.js.map +1 -1
  395. package/lib/resolvers/type/order/order-item-discount-types.d.ts +1 -1
  396. package/lib/resolvers/type/order/order-item-discount-types.d.ts.map +1 -1
  397. package/lib/resolvers/type/order/order-item-discount-types.js +1 -2
  398. package/lib/resolvers/type/order/order-item-discount-types.js.map +1 -1
  399. package/lib/resolvers/type/order/order-item-types.d.ts +5 -5
  400. package/lib/resolvers/type/order/order-item-types.d.ts.map +1 -1
  401. package/lib/resolvers/type/order/order-item-types.js +14 -17
  402. package/lib/resolvers/type/order/order-item-types.js.map +1 -1
  403. package/lib/resolvers/type/order/order-payment-card-types.d.ts +11 -10
  404. package/lib/resolvers/type/order/order-payment-card-types.d.ts.map +1 -1
  405. package/lib/resolvers/type/order/order-payment-card-types.js +6 -9
  406. package/lib/resolvers/type/order/order-payment-card-types.js.map +1 -1
  407. package/lib/resolvers/type/order/order-payment-discount-types.d.ts +1 -1
  408. package/lib/resolvers/type/order/order-payment-discount-types.d.ts.map +1 -1
  409. package/lib/resolvers/type/order/order-payment-discount-types.js +2 -4
  410. package/lib/resolvers/type/order/order-payment-discount-types.js.map +1 -1
  411. package/lib/resolvers/type/order/order-payment-generic-types.d.ts +11 -10
  412. package/lib/resolvers/type/order/order-payment-generic-types.d.ts.map +1 -1
  413. package/lib/resolvers/type/order/order-payment-generic-types.js +6 -9
  414. package/lib/resolvers/type/order/order-payment-generic-types.js.map +1 -1
  415. package/lib/resolvers/type/order/order-payment-invoice-types.d.ts +11 -10
  416. package/lib/resolvers/type/order/order-payment-invoice-types.d.ts.map +1 -1
  417. package/lib/resolvers/type/order/order-payment-invoice-types.js +6 -9
  418. package/lib/resolvers/type/order/order-payment-invoice-types.js.map +1 -1
  419. package/lib/resolvers/type/order/order-payment-types.d.ts +1 -1
  420. package/lib/resolvers/type/order/order-payment-types.d.ts.map +1 -1
  421. package/lib/resolvers/type/order/order-payment-types.js +2 -3
  422. package/lib/resolvers/type/order/order-payment-types.js.map +1 -1
  423. package/lib/resolvers/type/order/order-types.d.ts +6 -6
  424. package/lib/resolvers/type/order/order-types.d.ts.map +1 -1
  425. package/lib/resolvers/type/order/order-types.js +7 -15
  426. package/lib/resolvers/type/order/order-types.js.map +1 -1
  427. package/lib/resolvers/type/payment/payment-credentials-types.d.ts.map +1 -1
  428. package/lib/resolvers/type/payment/payment-credentials-types.js +6 -9
  429. package/lib/resolvers/type/payment/payment-credentials-types.js.map +1 -1
  430. package/lib/resolvers/type/payment/payment-provider-types.d.ts +2 -2
  431. package/lib/resolvers/type/payment/payment-provider-types.d.ts.map +1 -1
  432. package/lib/resolvers/type/payment/payment-provider-types.js +8 -9
  433. package/lib/resolvers/type/payment/payment-provider-types.js.map +1 -1
  434. package/lib/resolvers/type/price-types.d.ts +3 -4
  435. package/lib/resolvers/type/price-types.d.ts.map +1 -1
  436. package/lib/resolvers/type/price-types.js +2 -2
  437. package/lib/resolvers/type/price-types.js.map +1 -1
  438. package/lib/resolvers/type/product/product-assortment-path-types.d.ts +1 -1
  439. package/lib/resolvers/type/product/product-assortment-path-types.d.ts.map +1 -1
  440. package/lib/resolvers/type/product/product-bundle-types.d.ts +10 -10
  441. package/lib/resolvers/type/product/product-bundle-types.d.ts.map +1 -1
  442. package/lib/resolvers/type/product/product-catalog-price-types.d.ts.map +1 -1
  443. package/lib/resolvers/type/product/product-catalog-price-types.js +4 -6
  444. package/lib/resolvers/type/product/product-catalog-price-types.js.map +1 -1
  445. package/lib/resolvers/type/product/product-configurable-types.d.ts +20 -20
  446. package/lib/resolvers/type/product/product-configurable-types.d.ts.map +1 -1
  447. package/lib/resolvers/type/product/product-configurable-types.js +10 -12
  448. package/lib/resolvers/type/product/product-configurable-types.js.map +1 -1
  449. package/lib/resolvers/type/product/product-discount.d.ts +1 -1
  450. package/lib/resolvers/type/product/product-discount.js +1 -1
  451. package/lib/resolvers/type/product/product-discount.js.map +1 -1
  452. package/lib/resolvers/type/product/product-media-types.js +2 -2
  453. package/lib/resolvers/type/product/product-media-types.js.map +1 -1
  454. package/lib/resolvers/type/product/product-plan-types.d.ts +18 -18
  455. package/lib/resolvers/type/product/product-plan-types.d.ts.map +1 -1
  456. package/lib/resolvers/type/product/product-plan-types.js +16 -16
  457. package/lib/resolvers/type/product/product-plan-types.js.map +1 -1
  458. package/lib/resolvers/type/product/product-review-types.d.ts +1 -1
  459. package/lib/resolvers/type/product/product-review-types.d.ts.map +1 -1
  460. package/lib/resolvers/type/product/product-review-types.js +2 -3
  461. package/lib/resolvers/type/product/product-review-types.js.map +1 -1
  462. package/lib/resolvers/type/product/product-simple-types.d.ts +22 -22
  463. package/lib/resolvers/type/product/product-simple-types.d.ts.map +1 -1
  464. package/lib/resolvers/type/product/product-simple-types.js +3 -11
  465. package/lib/resolvers/type/product/product-simple-types.js.map +1 -1
  466. package/lib/resolvers/type/product/product-tokenized-types.d.ts +20 -20
  467. package/lib/resolvers/type/product/product-tokenized-types.d.ts.map +1 -1
  468. package/lib/resolvers/type/product/product-tokenized-types.js +1 -5
  469. package/lib/resolvers/type/product/product-tokenized-types.js.map +1 -1
  470. package/lib/resolvers/type/product/product-types.d.ts +9 -9
  471. package/lib/resolvers/type/product/product-types.d.ts.map +1 -1
  472. package/lib/resolvers/type/product/product-types.js +2 -5
  473. package/lib/resolvers/type/product/product-types.js.map +1 -1
  474. package/lib/resolvers/type/product/product-variation-assignment-types.d.ts +2 -2
  475. package/lib/resolvers/type/product/product-variation-assignment-types.d.ts.map +1 -1
  476. package/lib/resolvers/type/product/product-variation-assignment-types.js +1 -1
  477. package/lib/resolvers/type/product/product-variation-assignment-types.js.map +1 -1
  478. package/lib/resolvers/type/product/product-variation-assignment-vector.js +2 -2
  479. package/lib/resolvers/type/product/product-variation-assignment-vector.js.map +1 -1
  480. package/lib/resolvers/type/product/product-variation-option-types.js +3 -3
  481. package/lib/resolvers/type/product/product-variation-option-types.js.map +1 -1
  482. package/lib/resolvers/type/product/product-variation-types.d.ts +2 -2
  483. package/lib/resolvers/type/product/product-variation-types.d.ts.map +1 -1
  484. package/lib/resolvers/type/product/product-variation-types.js +3 -3
  485. package/lib/resolvers/type/product/product-variation-types.js.map +1 -1
  486. package/lib/resolvers/type/product-search-result-types.d.ts +5 -6
  487. package/lib/resolvers/type/product-search-result-types.d.ts.map +1 -1
  488. package/lib/resolvers/type/quotation-types.d.ts +8 -15
  489. package/lib/resolvers/type/quotation-types.d.ts.map +1 -1
  490. package/lib/resolvers/type/quotation-types.js +3 -6
  491. package/lib/resolvers/type/quotation-types.js.map +1 -1
  492. package/lib/resolvers/type/shop-types.d.ts +1 -1
  493. package/lib/resolvers/type/shop-types.d.ts.map +1 -1
  494. package/lib/resolvers/type/shop-types.js +4 -6
  495. package/lib/resolvers/type/shop-types.js.map +1 -1
  496. package/lib/resolvers/type/token-types.d.ts +2 -2
  497. package/lib/resolvers/type/token-types.d.ts.map +1 -1
  498. package/lib/resolvers/type/token-types.js +12 -26
  499. package/lib/resolvers/type/token-types.js.map +1 -1
  500. package/lib/resolvers/type/user-types.d.ts +22 -22
  501. package/lib/resolvers/type/user-types.d.ts.map +1 -1
  502. package/lib/resolvers/type/user-types.js +5 -16
  503. package/lib/resolvers/type/user-types.js.map +1 -1
  504. package/lib/resolvers/type/work-types.d.ts.map +1 -1
  505. package/lib/resolvers/type/work-types.js +0 -1
  506. package/lib/resolvers/type/work-types.js.map +1 -1
  507. package/lib/roles/all.d.ts.map +1 -1
  508. package/lib/roles/all.js +0 -1
  509. package/lib/roles/all.js.map +1 -1
  510. package/lib/schema/types/assortment.js +5 -5
  511. package/lib/schema/types/country.js +1 -1
  512. package/lib/schema/types/delivery.d.ts.map +1 -1
  513. package/lib/schema/types/delivery.js +6 -2
  514. package/lib/schema/types/delivery.js.map +1 -1
  515. package/lib/schema/types/filter.js +3 -3
  516. package/lib/schema/types/payment.d.ts.map +1 -1
  517. package/lib/schema/types/payment.js +6 -2
  518. package/lib/schema/types/payment.js.map +1 -1
  519. package/lib/schema/types/price.js +1 -1
  520. package/lib/schema/types/product/bundle-product.js +1 -1
  521. package/lib/schema/types/product/configurable-product.js +6 -6
  522. package/lib/schema/types/product/plan-product.js +5 -5
  523. package/lib/schema/types/product/product.js +4 -4
  524. package/lib/schema/types/product/simple-product.js +4 -4
  525. package/lib/schema/types/product/tokenized-product.js +5 -5
  526. package/lib/schema/types/warehousing.js +1 -1
  527. package/lib/utils/inputValidation.d.ts.map +1 -0
  528. package/lib/utils/inputValidation.js +51 -0
  529. package/lib/utils/inputValidation.js.map +1 -0
  530. package/package.json +12 -12
  531. package/src/context.ts +3 -3
  532. package/src/createGraphQLServer.ts +2 -2
  533. package/src/errors.ts +10 -0
  534. package/src/express/createERCMetadataMiddleware.ts +11 -5
  535. package/src/express/index.ts +2 -3
  536. package/src/fastify/ercMetadataHandler.ts +11 -5
  537. package/src/fastify/index.ts +2 -3
  538. package/src/loaders/assortmentLinkLoader.ts +32 -0
  539. package/src/loaders/assortmentLinksLoader.ts +46 -0
  540. package/src/loaders/assortmentLoader.ts +20 -0
  541. package/src/loaders/assortmentMediaTextLoader.ts +26 -0
  542. package/src/loaders/assortmentMediasLoader.ts +21 -0
  543. package/src/loaders/assortmentProductLoader.ts +19 -0
  544. package/src/loaders/assortmentProductsLoader.ts +22 -0
  545. package/src/loaders/assortmentTextLoader.ts +24 -0
  546. package/src/loaders/buildTextMap.ts +1 -1
  547. package/src/loaders/countryLoader.ts +20 -0
  548. package/src/loaders/currencyLoader.ts +20 -0
  549. package/src/loaders/deliveryProviderLoader.ts +19 -0
  550. package/src/loaders/fileLoader.ts +19 -0
  551. package/src/loaders/filterLoader.ts +20 -0
  552. package/src/loaders/filterTextLoader.ts +26 -0
  553. package/src/loaders/index.ts +48 -360
  554. package/src/loaders/languageLoader.ts +20 -0
  555. package/src/loaders/orderLoader.ts +22 -0
  556. package/src/loaders/paymentProviderLoader.ts +19 -0
  557. package/src/loaders/productLoader.ts +22 -0
  558. package/src/loaders/productLoaderBySKU.ts +22 -0
  559. package/src/loaders/productMediaTextLoader.ts +24 -0
  560. package/src/loaders/productMediasLoader.ts +21 -0
  561. package/src/loaders/productTextLoader.ts +22 -0
  562. package/src/loaders/userLoader.ts +23 -0
  563. package/src/loaders/utils.ts +35 -0
  564. package/src/locale-context.ts +16 -22
  565. package/src/resolvers/mutations/accounts/createUser.ts +4 -6
  566. package/src/resolvers/mutations/accounts/impersonate.ts +1 -1
  567. package/src/resolvers/mutations/accounts/loginAsGuest.ts +4 -6
  568. package/src/resolvers/mutations/accounts/loginWithPassword.ts +3 -3
  569. package/src/resolvers/mutations/accounts/loginWithWebAuthn.ts +3 -3
  570. package/src/resolvers/mutations/accounts/resetPassword.ts +3 -3
  571. package/src/resolvers/mutations/accounts/stopImpersonation.ts +1 -1
  572. package/src/resolvers/mutations/accounts/verifyEmail.ts +3 -3
  573. package/src/resolvers/mutations/assortments/reorderAssortmentFilters.ts +1 -1
  574. package/src/resolvers/mutations/assortments/reorderAssortmentLinks.ts +1 -1
  575. package/src/resolvers/mutations/assortments/reorderAssortmentMedia.ts +1 -1
  576. package/src/resolvers/mutations/assortments/reorderAssortmentProducts.ts +1 -1
  577. package/src/resolvers/mutations/assortments/updateAssortmentMediaTexts.ts +1 -1
  578. package/src/resolvers/mutations/assortments/updateAssortmentTexts.ts +1 -1
  579. package/src/resolvers/mutations/enrollments/createEnrollment.ts +3 -3
  580. package/src/resolvers/mutations/enrollments/updateEnrollment.ts +2 -2
  581. package/src/resolvers/mutations/filters/createFilter.ts +2 -6
  582. package/src/resolvers/mutations/filters/updateFilterTexts.ts +1 -1
  583. package/src/resolvers/mutations/orders/addCartDiscount.ts +1 -1
  584. package/src/resolvers/mutations/orders/addCartProduct.ts +1 -1
  585. package/src/resolvers/mutations/orders/addCartQuotation.ts +2 -2
  586. package/src/resolvers/mutations/orders/addMultipleCartProducts.ts +4 -4
  587. package/src/resolvers/mutations/orders/checkoutCart.ts +1 -1
  588. package/src/resolvers/mutations/orders/createCart.ts +1 -1
  589. package/src/resolvers/mutations/orders/emptyCart.ts +1 -1
  590. package/src/resolvers/mutations/orders/signPaymentProviderForCheckout.ts +1 -1
  591. package/src/resolvers/mutations/orders/updateCart.ts +1 -1
  592. package/src/resolvers/mutations/orders/updateCartItem.ts +1 -1
  593. package/src/resolvers/mutations/products/addProductAssignment.ts +50 -3
  594. package/src/resolvers/mutations/products/createProductVariation.ts +5 -1
  595. package/src/resolvers/mutations/products/removeProductAssignment.ts +1 -1
  596. package/src/resolvers/mutations/products/reorderProductMedia.ts +1 -1
  597. package/src/resolvers/mutations/products/updateProductMediaTexts.ts +1 -1
  598. package/src/resolvers/mutations/products/updateProductVariationTexts.ts +1 -1
  599. package/src/resolvers/mutations/quotations/requestQuotation.ts +4 -4
  600. package/src/resolvers/mutations/users/heartbeat.ts +3 -3
  601. package/src/resolvers/mutations/users/setRoles.ts +1 -1
  602. package/src/resolvers/mutations/users/setUserTags.ts +1 -1
  603. package/src/resolvers/mutations/warehousing/invalidateToken.ts +3 -3
  604. package/src/resolvers/mutations/worker/allocateWork.ts +1 -1
  605. package/src/resolvers/queries/assortments/assortments.ts +1 -1
  606. package/src/resolvers/queries/countries/countries.ts +1 -1
  607. package/src/resolvers/queries/currencies/currencies.ts +1 -1
  608. package/src/resolvers/queries/enrollments/enrollments.ts +1 -1
  609. package/src/resolvers/queries/filters/filters.ts +1 -1
  610. package/src/resolvers/queries/filters/searchAssortments.ts +2 -2
  611. package/src/resolvers/queries/filters/searchProducts.ts +3 -3
  612. package/src/resolvers/queries/languages/languages.ts +1 -1
  613. package/src/resolvers/queries/orders/orders.ts +1 -1
  614. package/src/resolvers/queries/products/productReviews.ts +1 -1
  615. package/src/resolvers/queries/products/products.ts +1 -1
  616. package/src/resolvers/queries/quotations/quotations.ts +1 -1
  617. package/src/resolvers/queries/users/impersonator.ts +2 -1
  618. package/src/resolvers/queries/users/user.ts +1 -0
  619. package/src/resolvers/queries/users/users.ts +1 -1
  620. package/src/resolvers/queries/worker/workQueue.ts +3 -3
  621. package/src/resolvers/type/assortment/assortment-filter-types.ts +6 -16
  622. package/src/resolvers/type/assortment/assortment-link-types.ts +2 -2
  623. package/src/resolvers/type/assortment/assortment-media-types.ts +2 -2
  624. package/src/resolvers/type/assortment/assortment-path-link-types.ts +3 -3
  625. package/src/resolvers/type/assortment/assortment-product-types.ts +2 -2
  626. package/src/resolvers/type/assortment/assortment-types.ts +6 -6
  627. package/src/resolvers/type/bookmark-types.ts +2 -3
  628. package/src/resolvers/type/country-types.ts +5 -8
  629. package/src/resolvers/type/delivery-provider-types.ts +26 -47
  630. package/src/resolvers/type/enrollment/enrollment-delivery-types.ts +5 -11
  631. package/src/resolvers/type/enrollment/enrollment-payment-types.ts +3 -11
  632. package/src/resolvers/type/enrollment/enrollment-period-types.ts +3 -11
  633. package/src/resolvers/type/enrollment/enrollment-plan-tyes.ts +3 -11
  634. package/src/resolvers/type/enrollment/enrollment-types.ts +10 -25
  635. package/src/resolvers/type/filter/filter-option-types.ts +10 -15
  636. package/src/resolvers/type/filter/filter-types.ts +5 -13
  637. package/src/resolvers/type/filter/loaded-filter-types.ts +2 -2
  638. package/src/resolvers/type/login-method-response-types.ts +1 -1
  639. package/src/resolvers/type/order/order-delivery-discount-types.ts +1 -2
  640. package/src/resolvers/type/order/order-delivery-pickup-types.ts +12 -28
  641. package/src/resolvers/type/order/order-delivery-shipping-types.ts +9 -23
  642. package/src/resolvers/type/order/order-delivery-types.ts +2 -3
  643. package/src/resolvers/type/order/order-discount-types.ts +12 -39
  644. package/src/resolvers/type/order/order-global-discount-types.ts +1 -2
  645. package/src/resolvers/type/order/order-item-discount-types.ts +1 -2
  646. package/src/resolvers/type/order/order-item-types.ts +19 -27
  647. package/src/resolvers/type/order/order-payment-card-types.ts +8 -21
  648. package/src/resolvers/type/order/order-payment-discount-types.ts +1 -2
  649. package/src/resolvers/type/order/order-payment-generic-types.ts +8 -20
  650. package/src/resolvers/type/order/order-payment-invoice-types.ts +8 -20
  651. package/src/resolvers/type/order/order-payment-types.ts +2 -3
  652. package/src/resolvers/type/order/order-types.ts +10 -22
  653. package/src/resolvers/type/payment/payment-credentials-types.ts +6 -10
  654. package/src/resolvers/type/payment/payment-provider-types.ts +9 -10
  655. package/src/resolvers/type/price-types.ts +4 -4
  656. package/src/resolvers/type/product/product-assortment-path-types.ts +1 -1
  657. package/src/resolvers/type/product/product-bundle-types.ts +1 -1
  658. package/src/resolvers/type/product/product-catalog-price-types.ts +4 -6
  659. package/src/resolvers/type/product/product-configurable-types.ts +20 -21
  660. package/src/resolvers/type/product/product-discount.ts +1 -1
  661. package/src/resolvers/type/product/product-media-types.ts +2 -2
  662. package/src/resolvers/type/product/product-plan-types.ts +22 -22
  663. package/src/resolvers/type/product/product-review-types.ts +3 -4
  664. package/src/resolvers/type/product/product-simple-types.ts +7 -19
  665. package/src/resolvers/type/product/product-tokenized-types.ts +3 -10
  666. package/src/resolvers/type/product/product-types.ts +10 -13
  667. package/src/resolvers/type/product/product-variation-assignment-types.ts +2 -2
  668. package/src/resolvers/type/product/product-variation-assignment-vector.ts +2 -2
  669. package/src/resolvers/type/product/product-variation-option-types.ts +3 -3
  670. package/src/resolvers/type/product/product-variation-types.ts +5 -5
  671. package/src/resolvers/type/product-search-result-types.ts +5 -5
  672. package/src/resolvers/type/quotation-types.ts +11 -25
  673. package/src/resolvers/type/shop-types.ts +5 -7
  674. package/src/resolvers/type/token-types.ts +15 -32
  675. package/src/resolvers/type/user-types.ts +27 -39
  676. package/src/resolvers/type/work-types.ts +0 -2
  677. package/src/roles/all.ts +0 -1
  678. package/src/schema/types/assortment.ts +5 -5
  679. package/src/schema/types/country.ts +1 -1
  680. package/src/schema/types/delivery.ts +6 -2
  681. package/src/schema/types/filter.ts +3 -3
  682. package/src/schema/types/payment.ts +6 -2
  683. package/src/schema/types/price.ts +1 -1
  684. package/src/schema/types/product/bundle-product.ts +1 -1
  685. package/src/schema/types/product/configurable-product.ts +6 -6
  686. package/src/schema/types/product/plan-product.ts +5 -5
  687. package/src/schema/types/product/product.ts +4 -4
  688. package/src/schema/types/product/simple-product.ts +4 -4
  689. package/src/schema/types/product/tokenized-product.ts +5 -5
  690. package/src/schema/types/warehousing.ts +1 -1
@@ -1 +1 @@
1
- {"version":3,"file":"searchAssortments.js","sourceRoot":"","sources":["../../../../src/resolvers/queries/filters/searchAssortments.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,GAAG,EAAE,MAAM,uBAAuB,CAAC;AAC5C,OAAO,EAAE,wBAAwB,EAAE,MAAM,oBAAoB,CAAC;AAE9D,MAAM,CAAC,O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CAAC,KAAK,EAAE;QAC/C,mBAAmB;QACnB,MAAM;KACP,CAAC,CAAC;AACL,CAAC"}
@@ -1,7 +1,7 @@
1
1
  import { log } from '@unchainedshop/logger';
2
2
  import { QueryStringRequiredError } from '../../../errors.js';
3
3
  export default async function searchProducts(root, query, context) {
4
- const { modules, services, userId, localeContext } = context;
4
+ const { modules, services, userId, locale } = context;
5
5
  const forceLiveCollection = false;
6
6
  const { queryString, includeInactive, filterQuery, assortmentId, ignoreChildAssortments, ...rest } = query;
7
7
  log(`query search ${assortmentId} ${JSON.stringify(query)}`, { userId });
@@ -14,10 +14,10 @@ export default async function searchProducts(root, query, context) {
14
14
  const filterIds = await modules.assortments.filters.findFilterIds({
15
15
  assortmentId,
16
16
  });
17
- return services.filters.searchProducts({ queryString, includeInactive, filterQuery, productIds, filterIds, ...rest }, { forceLiveCollection, locale: localeContext });
17
+ return services.filters.searchProducts({ queryString, includeInactive, filterQuery, productIds, filterIds, ...rest }, { forceLiveCollection, locale: locale });
18
18
  }
19
19
  if (!queryString)
20
20
  throw new QueryStringRequiredError({});
21
- return services.filters.searchProducts({ queryString, includeInactive, filterQuery, ...rest }, { forceLiveCollection, locale: localeContext });
21
+ return services.filters.searchProducts({ queryString, includeInactive, filterQuery, ...rest }, { forceLiveCollection, locale: locale });
22
22
  }
23
23
  //# sourceMappingURL=searchProducts.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"searchProducts.js","sourceRoot":"","sources":["../../../../src/resolvers/queries/filters/searchProducts.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,uBAAuB,CAAC;AAE5C,OAAO,EAAE,wBAAwB,EAAE,MAAM,oBAAoB,CAAC;AAG9D,MAAM,CAAC,OAAO,CAAC,KAAK,UAAU,cAAc,CAC1C,IAAW,EACX,KAOC,EACD,OAAgB;IAEhB,MAAM,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,aAAa,EAAE,GAAG,OAAO,CAAC;IAC7D,M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U,cAAc,CAC1C,IAAW,EACX,KAOC,EACD,OAAgB;IAEhB,MAAM,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC;IACtD,MAAM,mBAAmB,GAAG,KAAK,CAAC;IAClC,MAAM,EAAE,WAAW,EAAE,eAAe,EAAE,WAAW,EAAE,YAAY,EAAE,sBAAsB,EAAE,GAAG,IAAI,EAAE,GAChG,KAAK,CAAC;IAER,GAAG,CAAC,gBAAgB,YAAY,IAAI,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,EAAE,EAAE,EAAE,MAAM,EAAE,CAAC,CAAC;IAEzE,IAAI,YAAY,EAAE,CAAC;QACjB,MAAM,UAAU,GAAG,MAAM,OAAO,CAAC,WAAW,CAAC,cAAc,CAAC;YAC1D,YAAY;YACZ,mBAAmB;YACnB,sBAAsB;SACvB,CAAC,CAAC;QACH,MAAM,SAAS,GAAG,MAAM,OAAO,CAAC,WAAW,CAAC,OAAO,CAAC,aAAa,CAAC;YAChE,YAAY;SACb,CAAC,CAAC;QACH,OAAO,QAAQ,CAAC,OAAO,CAAC,cAAc,CACpC,EAAE,WAAW,EAAE,eAAe,EAAE,WAAW,EAAE,UAAU,EAAE,SAAS,EAAE,GAAG,IAAI,EAAE,EAC7E,EAAE,mBAAmB,EAAE,MAAM,EAAE,MAAM,EAAE,CACxC,CAAC;IACJ,CAAC;IAED,IAAI,CAAC,WAAW;QAAE,MAAM,IAAI,wBAAwB,CAAC,EAAE,CAAC,CAAC;IAEzD,OAAO,QAAQ,CAAC,OAAO,CAAC,cAAc,CACpC,EAAE,WAAW,EAAE,eAAe,EAAE,WAAW,EAAE,GAAG,IAAI,EAAE,EACtD,EAAE,mBAAmB,EAAE,MAAM,EAAE,MAAM,EAAE,CACxC,CAAC;AACJ,CAAC"}
@@ -4,6 +4,6 @@ import { Context } from '../../../context.js';
4
4
  export default function languages(root: never, params: LanguageQuery & {
5
5
  limit: number;
6
6
  offset: number;
7
- sort?: Array<SortOption>;
7
+ sort?: SortOption[];
8
8
  }, { modules, userId }: Context): Promise<import("@unchainedshop/core-languages").Language[]>;
9
9
  //# sourceMappingURL=languages.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"languages.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/queries/languages/languages.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AAC9D,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,wBAA8B,SAAS,CACrC,IAAI,EAAE,KAAK,EACX,MAAM,EAAE,aAAa,GAAG;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAC;IAAC,IAAI,CAAC,EAAE,KAAK,CAAC,UAAU,CAAC,CAAA;CAAE,EACnF,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,OAAO,+DAU7B"}
1
+ {"version":3,"file":"languages.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/queries/languages/languages.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AAC9D,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,wBAA8B,SAAS,CACrC,IAAI,EAAE,KAAK,EACX,MAAM,EAAE,aAAa,GAAG;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAC;IAAC,IAAI,CAAC,EAAE,UAAU,EAAE,CAAA;CAAE,EAC9E,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,OAAO,+DAU7B"}
@@ -1 +1 @@
1
- {"version":3,"file":"languages.js","sourceRoot":"","sources":["../../../../src/resolvers/queries/languages/languages.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,uBAAuB,CAAC;AAK5C,MAAM,CAAC,OAAO,CAAC,KAAK,UAAU,SAAS,CACrC,IAAW,EACX,MAAmF,EACnF,EAAE,OAAO,EAAE,MAAM,EAAW;IAE5B,GAAG,CACD,oBAAoB,MAAM,CAAC,KAAK,IAAI,MAAM,CAAC,MAAM,IAC/C,MAAM,CAAC,eAAe,CAAC,CAAC,CAAC,iBAAiB,CAAC,CAAC,CAAC,EAC/C,EAAE,EACF,EAAE,MAAM,EAAE,CACX,CAAC;IAEF,OAAO,OAAO,CAAC,SAAS,CAAC,aAAa,CAAC,MAAM,CAAC,CAAC;AACjD,CAAC"}
1
+ {"version":3,"file":"languages.js","sourceRoot":"","sources":["../../../../src/resolvers/queries/languages/languages.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,uBAAuB,CAAC;AAK5C,MAAM,CAAC,OAAO,CAAC,KAAK,UAAU,SAAS,CACrC,IAAW,EACX,MAA8E,EAC9E,EAAE,OAAO,EAAE,MAAM,EAAW;IAE5B,GAAG,CACD,oBAAoB,MAAM,CAAC,KAAK,IAAI,MAAM,CAAC,MAAM,IAC/C,MAAM,CAAC,eAAe,CAAC,CAAC,CAAC,iBAAiB,CAAC,CAAC,CAAC,EAC/C,EAAE,EACF,EAAE,MAAM,EAAE,CACX,CAAC;IAEF,OAAO,OAAO,CAAC,SAAS,CAAC,aAAa,CAAC,MAAM,CAAC,CAAC;AACjD,CAAC"}
@@ -4,6 +4,6 @@ import { Context } from '../../../context.js';
4
4
  export default function orders(root: never, params: OrderQuery & {
5
5
  limit?: number;
6
6
  offset?: number;
7
- sort?: Array<SortOption>;
7
+ sort?: SortOption[];
8
8
  }, { modules, userId }: Context): Promise<import("@unchainedshop/core-orders").Order[]>;
9
9
  //# sourceMappingURL=orders.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"orders.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/queries/orders/orders.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AACxD,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,wBAA8B,MAAM,CAClC,IAAI,EAAE,KAAK,EACX,MAAM,EAAE,UAAU,GAAG;IAAE,KAAK,CAAC,EAAE,MAAM,CAAC;IAAC,MAAM,CAAC,EAAE,MAAM,CAAC;IAAC,IAAI,CAAC,EAAE,KAAK,CAAC,UAAU,CAAC,CAAA;CAAE,EAClF,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,OAAO,yDAS7B"}
1
+ {"version":3,"file":"orders.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/queries/orders/orders.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AACxD,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,wBAA8B,MAAM,CAClC,IAAI,EAAE,KAAK,EACX,MAAM,EAAE,UAAU,GAAG;IAAE,KAAK,CAAC,EAAE,MAAM,CAAC;IAAC,MAAM,CAAC,EAAE,MAAM,CAAC;IAAC,IAAI,CAAC,EAAE,UAAU,EAAE,CAAA;CAAE,EAC7E,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,OAAO,yDAS7B"}
@@ -1 +1 @@
1
- {"version":3,"file":"orders.js","sourceRoot":"","sources":["../../../../src/resolvers/queries/orders/orders.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,uBAAuB,CAAC;AAK5C,MAAM,CAAC,OAAO,CAAC,KAAK,UAAU,MAAM,CAClC,IAAW,EACX,MAAkF,EAClF,EAAE,OAAO,EAAE,MAAM,EAAW;IAE5B,MAAM,EAAE,YAAY,EAAE,KAAK,EAAE,MAAM,EAAE,WAAW,EAAE,GAAG,MAAM,CAAC;IAE5D,GAAG,CAAC,iBAAiB,KAAK,IAAI,MAAM,IAAI,YAAY,IAAI,WAAW,EAAE,EAAE;QACrE,MAAM;KACP,CAAC,CAAC;IAEH,OAAO,OAAO,CAAC,MAAM,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC;AAC3C,CAAC"}
1
+ {"version":3,"file":"orders.js","sourceRoot":"","sources":["../../../../src/resolvers/queries/orders/orders.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,uBAAuB,CAAC;AAK5C,MAAM,CAAC,OAAO,CAAC,KAAK,UAAU,MAAM,CAClC,IAAW,EACX,MAA6E,EAC7E,EAAE,OAAO,EAAE,MAAM,EAAW;IAE5B,MAAM,EAAE,YAAY,EAAE,KAAK,EAAE,MAAM,EAAE,WAAW,EAAE,GAAG,MAAM,CAAC;IAE5D,GAAG,CAAC,iBAAiB,KAAK,IAAI,MAAM,IAAI,YAAY,IAAI,WAAW,EAAE,EAAE;QACrE,MAAM;KACP,CAAC,CAAC;IAEH,OAAO,OAAO,CAAC,MAAM,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC;AAC3C,CAAC"}
@@ -3,7 +3,7 @@ import { Context } from '../../../context.js';
3
3
  export default function productReviews(root: never, params: {
4
4
  limit: number;
5
5
  offset: number;
6
- sort: Array<SortOption>;
6
+ sort: SortOption[];
7
7
  queryString?: string;
8
8
  }, { modules, userId }: Context): Promise<import("@unchainedshop/core-products").ProductReview[]>;
9
9
  //# sourceMappingURL=productReviews.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"productReviews.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/queries/products/productReviews.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,wBAA8B,cAAc,CAC1C,IAAI,EAAE,KAAK,EACX,MAAM,EAAE;IACN,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,KAAK,CAAC,UAAU,CAAC,CAAC;IACxB,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,EACD,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,OAAO,mEAS7B"}
1
+ {"version":3,"file":"productReviews.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/queries/products/productReviews.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,wBAA8B,cAAc,CAC1C,IAAI,EAAE,KAAK,EACX,MAAM,EAAE;IACN,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,UAAU,EAAE,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,EACD,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,OAAO,mEAS7B"}
@@ -2,7 +2,7 @@ import { SortOption } from '@unchainedshop/utils';
2
2
  import { ProductQuery } from '@unchainedshop/core-products';
3
3
  import { Context } from '../../../context.js';
4
4
  export default function products(root: never, params: ProductQuery & {
5
- sort: Array<SortOption>;
5
+ sort: SortOption[];
6
6
  limit: number;
7
7
  offset: number;
8
8
  }, { modules, userId }: Context): Promise<import("@unchainedshop/core-products").Product[]>;
@@ -1 +1 @@
1
- {"version":3,"file":"products.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/queries/products/products.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AAC5D,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,wBAA8B,QAAQ,CACpC,IAAI,EAAE,KAAK,EACX,MAAM,EAAE,YAAY,GAAG;IACrB,IAAI,EAAE,KAAK,CAAC,UAAU,CAAC,CAAC;IACxB,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;CAChB,EACD,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,OAAO,6DAS7B"}
1
+ {"version":3,"file":"products.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/queries/products/products.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AAC5D,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,wBAA8B,QAAQ,CACpC,IAAI,EAAE,KAAK,EACX,MAAM,EAAE,YAAY,GAAG;IACrB,IAAI,EAAE,UAAU,EAAE,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;CAChB,EACD,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,OAAO,6DAS7B"}
@@ -4,6 +4,6 @@ import { Context } from '../../../context.js';
4
4
  export default function quotations(root: never, params: QuotationQuery & {
5
5
  limit?: number;
6
6
  offset?: number;
7
- sort?: Array<SortOption>;
7
+ sort?: SortOption[];
8
8
  }, { modules, userId }: Context): Promise<import("@unchainedshop/core-quotations").Quotation[]>;
9
9
  //# sourceMappingURL=quotations.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"quotations.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/queries/quotations/quotations.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EAAE,cAAc,EAAE,MAAM,gCAAgC,CAAC;AAChE,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,wBAA8B,UAAU,CACtC,IAAI,EAAE,KAAK,EACX,MAAM,EAAE,cAAc,GAAG;IAAE,KAAK,CAAC,EAAE,MAAM,CAAC;IAAC,MAAM,CAAC,EAAE,MAAM,CAAC;IAAC,IAAI,CAAC,EAAE,KAAK,CAAC,UAAU,CAAC,CAAA;CAAE,EACtF,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,OAAO,iEAK7B"}
1
+ {"version":3,"file":"quotations.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/queries/quotations/quotations.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EAAE,cAAc,EAAE,MAAM,gCAAgC,CAAC;AAChE,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,wBAA8B,UAAU,CACtC,IAAI,EAAE,KAAK,EACX,MAAM,EAAE,cAAc,GAAG;IAAE,KAAK,CAAC,EAAE,MAAM,CAAC;IAAC,MAAM,CAAC,EAAE,MAAM,CAAC;IAAC,IAAI,CAAC,EAAE,UAAU,EAAE,CAAA;CAAE,EACjF,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,OAAO,iEAK7B"}
@@ -1 +1 @@
1
- {"version":3,"file":"quotations.js","sourceRoot":"","sources":["../../../../src/resolvers/queries/quotations/quotations.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,uBAAuB,CAAC;AAK5C,MAAM,CAAC,OAAO,CAAC,KAAK,UAAU,UAAU,CACtC,IAAW,EACX,MAAsF,EACtF,EAAE,OAAO,EAAE,MAAM,EAAW;IAE5B,GAAG,CAAC,qBAAqB,MAAM,CAAC,KAAK,IAAI,MAAM,CAAC,MAAM,EAAE,EAAE,EAAE,MAAM,EAAE,CAAC,CAAC;IAEtE,OAAO,OAAO,CAAC,UAAU,CAAC,cAAc,CAAC,MAAM,CAAC,CAAC;AACnD,CAAC"}
1
+ {"version":3,"file":"quotations.js","sourceRoot":"","sources":["../../../../src/resolvers/queries/quotations/quotations.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,uBAAuB,CAAC;AAK5C,MAAM,CAAC,OAAO,CAAC,KAAK,UAAU,UAAU,CACtC,IAAW,EACX,MAAiF,EACjF,EAAE,OAAO,EAAE,MAAM,EAAW;IAE5B,GAAG,CAAC,qBAAqB,MAAM,CAAC,KAAK,IAAI,MAAM,CAAC,MAAM,EAAE,EAAE,EAAE,MAAM,EAAE,CAAC,CAAC;IAEtE,OAAO,OAAO,CAAC,UAAU,CAAC,cAAc,CAAC,MAAM,CAAC,CAAC;AACnD,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"impersonator.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/queries/users/impersonator.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,wBAA8B,YAAY,CACxC,IAAI,EAAE,KAAK,EACX,MAAM,EAAE,GAAG,EACX,EAAE,MAAM,EAAE,OAAO,EAAE,cAAc,EAAE,EAAE,OAAO,qDAM7C"}
1
+ {"version":3,"file":"impersonator.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/queries/users/impersonator.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,wBAA8B,YAAY,CACxC,IAAI,EAAE,KAAK,EACX,MAAM,EAAE,GAAG,EACX,EAAE,MAAM,EAAE,OAAO,EAAE,cAAc,EAAE,EAAE,OAAO,qDAO7C"}
@@ -3,6 +3,6 @@ export default async function impersonator(root, params, { userId, modules, impe
3
3
  log(`query impersonator`, { userId });
4
4
  if (!impersonatorId)
5
5
  return null;
6
- return modules.users.findUserById(impersonatorId);
6
+ return modules.users.findUser({ userId: impersonatorId });
7
7
  }
8
8
  //# sourceMappingURL=impersonator.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"impersonator.js","sourceRoot":"","sources":["../../../../src/resolvers/queries/users/impersonator.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,uBAAuB,CAAC;AAG5C,MAAM,CAAC,OAAO,CAAC,KAAK,UAAU,YAAY,CACxC,IAAW,EACX,MAAW,EACX,EAAE,MAAM,EAAE,OAAO,EAAE,cAAc,EAAW;IAE5C,GAAG,CAAC,oBAAoB,EAAE,EAAE,MAAM,EAAE,CAAC,CAAC;IAEtC,IAAI,CAAC,cAAc;QAAE,OAAO,IAAI,CAAC;IACjC,OAAO,OAAO,CAAC,KAAK,CAAC,YAAY,CAAC,cAAc,CAAC,CAAC;AACpD,CAAC"}
1
+ {"version":3,"file":"impersonator.js","sourceRoot":"","sources":["../../../../src/resolvers/queries/users/impersonator.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,uBAAuB,CAAC;AAG5C,MAAM,CAAC,OAAO,CAAC,KAAK,UAAU,YAAY,CACxC,IAAW,EACX,MAAW,EACX,EAAE,MAAM,EAAE,OAAO,EAAE,cAAc,EAAW;IAE5C,GAAG,CAAC,oBAAoB,EAAE,EAAE,MAAM,EAAE,CAAC,CAAC;IAEtC,IAAI,CAAC,cAAc;QAAE,OAAO,IAAI,CAAC;IAEjC,OAAO,OAAO,CAAC,KAAK,CAAC,QAAQ,CAAC,EAAE,MAAM,EAAE,cAAc,EAAE,CAAC,CAAC;AAC5D,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"user.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/queries/users/user.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,wBAA8B,IAAI,CAChC,IAAI,EAAE,KAAK,EACX,MAAM,EAAE;IAAE,MAAM,CAAC,EAAE,MAAM,CAAA;CAAE,EAC3B,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,OAAO,qDAI7B"}
1
+ {"version":3,"file":"user.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/queries/users/user.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,wBAA8B,IAAI,CAChC,IAAI,EAAE,KAAK,EACX,MAAM,EAAE;IAAE,MAAM,CAAC,EAAE,MAAM,CAAA;CAAE,EAC3B,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,OAAO,qDAK7B"}
@@ -1 +1 @@
1
- {"version":3,"file":"user.js","sourceRoot":"","sources":["../../../../src/resolvers/queries/users/user.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,uBAAuB,CAAC;AAG5C,MAAM,CAAC,OAAO,CAAC,KAAK,UAAU,IAAI,CAChC,IAAW,EACX,MAA2B,EAC3B,EAAE,OAAO,EAAE,MAAM,EAAW;IAE5B,GAAG,CAAC,cAAc,MAAM,CAAC,MAAM,EAAE,EAAE,EAAE,EAAE,EAAE,MAAM,EAAE,CAAC,CAAC;IACnD,OAAO,OAAO,CAAC,KAAK,CAAC,YAAY,CAAC,MAAM,CAAC,MAAM,IAAI,MAAM,CAAC,CAAC;AAC7D,CAAC"}
1
+ {"version":3,"file":"user.js","sourceRoot":"","sources":["../../../../src/resolvers/queries/users/user.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,uBAAuB,CAAC;AAG5C,MAAM,CAAC,OAAO,CAAC,KAAK,UAAU,IAAI,CAChC,IAAW,EACX,MAA2B,EAC3B,EAAE,OAAO,EAAE,MAAM,EAAW;IAE5B,GAAG,CAAC,cAAc,MAAM,CAAC,MAAM,EAAE,EAAE,EAAE,EAAE,EAAE,MAAM,EAAE,CAAC,CAAC;IAEnD,OAAO,OAAO,CAAC,KAAK,CAAC,YAAY,CAAC,MAAM,CAAC,MAAM,IAAI,MAAM,CAAC,CAAC;AAC7D,CAAC"}
@@ -4,7 +4,7 @@ import { Context } from '../../../context.js';
4
4
  export default function users(root: never, params: UserQuery & {
5
5
  limit?: number;
6
6
  offset?: number;
7
- sort?: Array<SortOption>;
7
+ sort?: SortOption[];
8
8
  includeGuests?: boolean;
9
9
  emailVerified?: boolean;
10
10
  lastLogin?: DateFilterInput;
@@ -1 +1 @@
1
- {"version":3,"file":"users.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/queries/users/users.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AACnE,OAAO,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AACtD,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,wBAA8B,KAAK,CACjC,IAAI,EAAE,KAAK,EACX,MAAM,EAAE,SAAS,GAAG;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,KAAK,CAAC,UAAU,CAAC,CAAC;IACzB,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,SAAS,CAAC,EAAE,eAAe,CAAC;CAC7B,EACD,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,OAAO,uDAa7B"}
1
+ {"version":3,"file":"users.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/queries/users/users.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AACnE,OAAO,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AACtD,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,wBAA8B,KAAK,CACjC,IAAI,EAAE,KAAK,EACX,MAAM,EAAE,SAAS,GAAG;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,UAAU,EAAE,CAAC;IACpB,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,SAAS,CAAC,EAAE,eAAe,CAAC;CAC7B,EACD,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,OAAO,uDAa7B"}
@@ -5,12 +5,12 @@ export default function workQueue(root: never, { limit, offset, status, types, c
5
5
  limit?: number;
6
6
  offset?: number;
7
7
  queryString?: string;
8
- status?: Array<WorkStatus>;
9
- types?: Array<string>;
8
+ status?: WorkStatus[];
9
+ types?: string[];
10
10
  created?: {
11
11
  start: Date;
12
12
  end: Date;
13
13
  };
14
- sort?: Array<SortOption>;
14
+ sort?: SortOption[];
15
15
  }, { modules, userId }: Context): Promise<import("@unchainedshop/core-worker").Work[]>;
16
16
  //# sourceMappingURL=workQueue.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"workQueue.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/queries/worker/workQueue.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AACxD,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,wBAA8B,SAAS,CACrC,IAAI,EAAE,KAAK,EACX,EACE,KAAK,EACL,MAAM,EACN,MAAM,EACN,KAAK,EACL,OAAO,EACP,WAAW,EACX,IAAI,GACL,EAAE;IACD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,MAAM,CAAC,EAAE,KAAK,CAAC,UAAU,CAAC,CAAC;IAC3B,KAAK,CAAC,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;IACtB,OAAO,CAAC,EAAE;QACR,KAAK,EAAE,IAAI,CAAC;QACZ,GAAG,EAAE,IAAI,CAAC;KACX,CAAC;IACF,IAAI,CAAC,EAAE,KAAK,CAAC,UAAU,CAAC,CAAC;CAC1B,EACD,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,OAAO,wDAc7B"}
1
+ {"version":3,"file":"workQueue.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/queries/worker/workQueue.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AACxD,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,wBAA8B,SAAS,CACrC,IAAI,EAAE,KAAK,EACX,EACE,KAAK,EACL,MAAM,EACN,MAAM,EACN,KAAK,EACL,OAAO,EACP,WAAW,EACX,IAAI,GACL,EAAE;IACD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,MAAM,CAAC,EAAE,UAAU,EAAE,CAAC;IACtB,KAAK,CAAC,EAAE,MAAM,EAAE,CAAC;IACjB,OAAO,CAAC,EAAE;QACR,KAAK,EAAE,IAAI,CAAC;QACZ,GAAG,EAAE,IAAI,CAAC;KACX,CAAC;IACF,IAAI,CAAC,EAAE,UAAU,EAAE,CAAC;CACrB,EACD,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE,OAAO,wDAc7B"}
@@ -1,11 +1,7 @@
1
- import { Assortment, AssortmentFilter as AssortmentFilterType } from '@unchainedshop/core-assortments';
2
- import { Filter } from '@unchainedshop/core-filters';
1
+ import { AssortmentFilter as AssortmentFilterType } from '@unchainedshop/core-assortments';
3
2
  import { Context } from '../../../context.js';
4
- type HelperType<T> = (assortmentFilter: AssortmentFilterType, _: never, context: Context) => T;
5
- export type AssortmentFilterHelperTypes = {
6
- assortment: HelperType<Promise<Assortment>>;
7
- filter: HelperType<Promise<Filter>>;
3
+ export declare const AssortmentFilter: {
4
+ assortment(obj: AssortmentFilterType, _: any, { loaders }: Context): Promise<import("@unchainedshop/core-assortments").Assortment>;
5
+ filter(obj: AssortmentFilterType, _: any, { loaders }: Context): Promise<import("@unchainedshop/core-filters").Filter>;
8
6
  };
9
- export declare const AssortmentFilter: AssortmentFilterHelperTypes;
10
- export {};
11
7
  //# sourceMappingURL=assortment-filter-types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"assortment-filter-types.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/type/assortment/assortment-filter-types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,gBAAgB,IAAI,oBAAoB,EAAE,MAAM,iCAAiC,CAAC;AACvG,OAAO,EAAE,MAAM,EAAE,MAAM,6BAA6B,CAAC;AACrD,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,KAAK,UAAU,CAAC,CAAC,IAAI,CAAC,gBAAgB,EAAE,oBAAoB,EAAE,CAAC,EAAE,KAAK,EAAE,OAAO,EAAE,OAAO,KAAK,CAAC,CAAC;AAE/F,MAAM,MAAM,2BAA2B,GAAG;IACxC,UAAU,EAAE,UAAU,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC,CAAC;IAC5C,MAAM,EAAE,UAAU,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC;CACrC,CAAC;AAEF,eAAO,MAAM,gBAAgB,EAAE,2BAc9B,CAAC"}
1
+ {"version":3,"file":"assortment-filter-types.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/type/assortment/assortment-filter-types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,IAAI,oBAAoB,EAAE,MAAM,iCAAiC,CAAC;AAC3F,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,eAAO,MAAM,gBAAgB;oBACL,oBAAoB,uBAAkB,OAAO;gBAMjD,oBAAoB,uBAAkB,OAAO;CAKhE,CAAC"}
@@ -1,15 +1,13 @@
1
1
  export const AssortmentFilter = {
2
- assortment: async (obj, _, { loaders }) => {
3
- const assortment = await loaders.assortmentLoader.load({
2
+ async assortment(obj, _, { loaders }) {
3
+ return loaders.assortmentLoader.load({
4
4
  assortmentId: obj.assortmentId,
5
5
  });
6
- return assortment;
7
6
  },
8
- filter: async (obj, _, { loaders }) => {
9
- const filter = await loaders.filterLoader.load({
7
+ async filter(obj, _, { loaders }) {
8
+ return loaders.filterLoader.load({
10
9
  filterId: obj.filterId,
11
10
  });
12
- return filter;
13
11
  },
14
12
  };
15
13
  //# sourceMappingURL=assortment-filter-types.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"assortment-filter-types.js","sourceRoot":"","sources":["../../../../src/resolvers/type/assortment/assortment-filter-types.ts"],"names":[],"mappings":"AAWA,MAAM,CAAC,MAAM,gBAAgB,GAAgC;IAC3D,UAAU,EAAE,KAAK,EAAE,GAAG,EAAE,CAAC,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE;QACxC,MAAM,UAAU,GAAG,MAAM,OAAO,CAAC,gBAAgB,CAAC,IAAI,CAAC;YACrD,YAAY,EAAE,GAAG,CAAC,YAAY;SAC/B,CAAC,CAAC;QACH,OAAO,UAAU,CAAC;IACpB,CAAC;IAED,MAAM,EAAE,KAAK,EAAE,GAAG,EAAE,CAAC,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE;QACpC,MAAM,MAAM,GAAG,MAAM,OAAO,CAAC,YAAY,CAAC,IAAI,CAAC;YAC7C,QAAQ,EAAE,GAAG,CAAC,QAAQ;SACvB,CAAC,CAAC;QACH,OAAO,MAAM,CAAC;IAChB,CAAC;CACF,CAAC"}
1
+ {"version":3,"file":"assortment-filter-types.js","sourceRoot":"","sources":["../../../../src/resolvers/type/assortment/assortment-filter-types.ts"],"names":[],"mappings":"AAGA,MAAM,CAAC,MAAM,gBAAgB,GAAG;IAC9B,KAAK,CAAC,UAAU,CAAC,GAAyB,EAAE,CAAC,EAAE,EAAE,OAAO,EAAW;QACjE,OAAO,OAAO,CAAC,gBAAgB,CAAC,IAAI,CAAC;YACnC,YAAY,EAAE,GAAG,CAAC,YAAY;SAC/B,CAAC,CAAC;IACL,CAAC;IAED,KAAK,CAAC,MAAM,CAAC,GAAyB,EAAE,CAAC,EAAE,EAAE,OAAO,EAAW;QAC7D,OAAO,OAAO,CAAC,YAAY,CAAC,IAAI,CAAC;YAC/B,QAAQ,EAAE,GAAG,CAAC,QAAQ;SACvB,CAAC,CAAC;IACL,CAAC;CACF,CAAC"}
@@ -1,10 +1,10 @@
1
1
  import { Context } from '../../../context.js';
2
2
  import { Assortment, AssortmentLink as AssortmentLinkType } from '@unchainedshop/core-assortments';
3
3
  type HelperType<T> = (assortmentLink: AssortmentLinkType, _: never, context: Context) => T;
4
- export type AssortmentLinkHelperTypes = {
4
+ export interface AssortmentLinkHelperTypes {
5
5
  child: HelperType<Promise<Assortment>>;
6
6
  parent: HelperType<Promise<Assortment>>;
7
- };
7
+ }
8
8
  export declare const AssortmentLink: AssortmentLinkHelperTypes;
9
9
  export {};
10
10
  //# sourceMappingURL=assortment-link-types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"assortment-link-types.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/type/assortment/assortment-link-types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAC9C,OAAO,EAAE,UAAU,EAAE,cAAc,IAAI,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AAEnG,KAAK,UAAU,CAAC,CAAC,IAAI,CAAC,cAAc,EAAE,kBAAkB,EAAE,CAAC,EAAE,KAAK,EAAE,OAAO,EAAE,OAAO,KAAK,CAAC,CAAC;AAE3F,MAAM,MAAM,yBAAyB,GAAG;IACtC,KAAK,EAAE,UAAU,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC,CAAC;IACvC,MAAM,EAAE,UAAU,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC,CAAC;CACzC,CAAC;AAEF,eAAO,MAAM,cAAc,EAAE,yBAc5B,CAAC"}
1
+ {"version":3,"file":"assortment-link-types.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/type/assortment/assortment-link-types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAC9C,OAAO,EAAE,UAAU,EAAE,cAAc,IAAI,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AAEnG,KAAK,UAAU,CAAC,CAAC,IAAI,CAAC,cAAc,EAAE,kBAAkB,EAAE,CAAC,EAAE,KAAK,EAAE,OAAO,EAAE,OAAO,KAAK,CAAC,CAAC;AAE3F,MAAM,WAAW,yBAAyB;IACxC,KAAK,EAAE,UAAU,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC,CAAC;IACvC,MAAM,EAAE,UAAU,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC,CAAC;CACzC;AAED,eAAO,MAAM,cAAc,EAAE,yBAc5B,CAAC"}
@@ -1,9 +1,9 @@
1
1
  export const AssortmentMedia = {
2
2
  async texts(obj, { forceLocale }, requestContext) {
3
- const { localeContext, loaders } = requestContext;
3
+ const { locale, loaders } = requestContext;
4
4
  return loaders.assortmentMediaTextLoader.load({
5
5
  assortmentMediaId: obj._id,
6
- locale: forceLocale || localeContext.baseName,
6
+ locale: forceLocale ? new Intl.Locale(forceLocale) : locale,
7
7
  });
8
8
  },
9
9
  async file(obj, _, requestContext) {
@@ -1 +1 @@
1
- {"version":3,"file":"assortment-media-types.js","sourceRoot":"","sources":["../../../../src/resolvers/type/assortment/assortment-media-types.ts"],"names":[],"mappings":"AAWA,MAAM,CAAC,MAAM,eAAe,GAA+B;IACzD,KAAK,CAAC,KAAK,CAAC,GAAG,EAAE,EAAE,WAAW,EAAE,EAAE,cAAc;QAC9C,MAAM,EAAE,aAAa,EAAE,OAAO,EAAE,GAAG,cAAc,CAAC;QAClD,OAAO,OAAO,CAAC,yBAAyB,CAAC,IAAI,CAAC;YAC5C,iBAAiB,EAAE,GAAG,CAAC,GAAG;YAC1B,MAAM,EAAE,WAAW,IAAI,aAAa,CAAC,QAAQ;SAC9C,CAAC,CAAC;IACL,CAAC;IAED,KAAK,CAAC,IAAI,CAAC,GAAG,EAAE,CAAC,EAAE,cAAc;QAC/B,MAAM,EAAE,OAAO,EAAE,GAAG,cAAc,CAAC;QACnC,OAAO,OAAO,CAAC,UAAU,CAAC,IAAI,CAAC;YAC7B,MAAM,EAAE,GAAG,CAAC,OAAO;SACpB,CAAC,CAAC;IACL,CAAC;CACF,CAAC"}
1
+ {"version":3,"file":"assortment-media-types.js","sourceRoot":"","sources":["../../../../src/resolvers/type/assortment/assortment-media-types.ts"],"names":[],"mappings":"AAWA,MAAM,CAAC,MAAM,eAAe,GAA+B;IACzD,KAAK,CAAC,KAAK,CAAC,GAAG,EAAE,EAAE,WAAW,EAAE,EAAE,cAAc;QAC9C,MAAM,EAAE,MAAM,EAAE,OAAO,EAAE,GAAG,cAAc,CAAC;QAC3C,OAAO,OAAO,CAAC,yBAAyB,CAAC,IAAI,CAAC;YAC5C,iBAAiB,EAAE,GAAG,CAAC,GAAG;YAC1B,MAAM,EAAE,WAAW,CAAC,CAAC,CAAC,IAAI,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,MAAM;SAC5D,CAAC,CAAC;IACL,CAAC;IAED,KAAK,CAAC,IAAI,CAAC,GAAG,EAAE,CAAC,EAAE,cAAc;QAC/B,MAAM,EAAE,OAAO,EAAE,GAAG,cAAc,CAAC;QACnC,OAAO,OAAO,CAAC,UAAU,CAAC,IAAI,CAAC;YAC7B,MAAM,EAAE,GAAG,CAAC,OAAO;SACpB,CAAC,CAAC;IACL,CAAC;CACF,CAAC"}
@@ -3,8 +3,8 @@ import { Context } from '../../../context.js';
3
3
  export declare const AssortmentPathLink: {
4
4
  link(linkObj: any): any;
5
5
  assortmentId(linkObj: any): any;
6
- assortmentTexts: ({ childAssortmentId }: AssortmentLink, params: {
6
+ assortmentTexts: ({ childAssortmentId }: AssortmentLink, { forceLocale }: {
7
7
  forceLocale?: string;
8
- }, { loaders, localeContext }: Context) => Promise<import("@unchainedshop/core-assortments").AssortmentText>;
8
+ }, { loaders, locale }: Context) => Promise<import("@unchainedshop/core-assortments").AssortmentText>;
9
9
  };
10
10
  //# sourceMappingURL=assortment-path-link-types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"assortment-path-link-types.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/type/assortment/assortment-path-link-types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAC;AACjE,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,eAAO,MAAM,kBAAkB;;;6CAWJ,cAAc,UAC7B;QAAE,WAAW,CAAC,EAAE,MAAM,CAAA;KAAE,8BACJ,OAAO;CAQtC,CAAC"}
1
+ {"version":3,"file":"assortment-path-link-types.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/type/assortment/assortment-path-link-types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAC;AACjE,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,eAAO,MAAM,kBAAkB;;;6CAWJ,cAAc,mBACpB;QAAE,WAAW,CAAC,EAAE,MAAM,CAAA;KAAE,uBACpB,OAAO;CAQ/B,CAAC"}
@@ -7,10 +7,10 @@ export const AssortmentPathLink = {
7
7
  assortmentId(linkObj) {
8
8
  return linkObj.childAssortmentId;
9
9
  },
10
- assortmentTexts: async ({ childAssortmentId }, params, { loaders, localeContext }) => {
10
+ assortmentTexts: async ({ childAssortmentId }, { forceLocale }, { loaders, locale }) => {
11
11
  const text = await loaders.assortmentTextLoader.load({
12
12
  assortmentId: childAssortmentId,
13
- locale: params.forceLocale || localeContext.baseName,
13
+ locale: forceLocale ? new Intl.Locale(forceLocale) : locale,
14
14
  });
15
15
  return text;
16
16
  },
@@ -1 +1 @@
1
- {"version":3,"file":"assortment-path-link-types.js","sourceRoot":"","sources":["../../../../src/resolvers/type/assortment/assortment-path-link-types.ts"],"names":[],"mappings":"AAGA,MAAM,CAAC,MAAM,kBAAkB,GAAG;IAChC,IAAI,CAAC,OAAO;QACV,IAAI,OAAO,CAAC,GAAG;YAAE,OAAO,OAAO,CAAC;QAChC,OAAO,IAAI,CAAC;IACd,CAAC;IAED,YAAY,CAAC,OAAO;QAClB,OAAO,OAAO,CAAC,iBAAiB,CAAC;IACnC,CAAC;IAED,eAAe,EAAE,KAAK,EACpB,EAAE,iBAAiB,EAAkB,EACrC,MAAgC,EAChC,EAAE,OAAO,EAAE,aAAa,EAAW,EACnC,EAAE;QACF,MAAM,IAAI,GAAG,MAAM,OAAO,CAAC,oBAAoB,CAAC,IAAI,CAAC;YACnD,YAAY,EAAE,iBAAiB;YAC/B,MAAM,EAAE,MAAM,CAAC,WAAW,IAAI,aAAa,CAAC,QAAQ;SACrD,CAAC,CAAC;QACH,OAAO,IAAI,CAAC;IACd,CAAC;CACF,CAAC"}
1
+ {"version":3,"file":"assortment-path-link-types.js","sourceRoot":"","sources":["../../../../src/resolvers/type/assortment/assortment-path-link-types.ts"],"names":[],"mappings":"AAGA,MAAM,CAAC,MAAM,kBAAkB,GAAG;IAChC,IAAI,CAAC,OAAO;QACV,IAAI,OAAO,CAAC,GAAG;YAAE,OAAO,OAAO,CAAC;QAChC,OAAO,IAAI,CAAC;IACd,CAAC;IAED,YAAY,CAAC,OAAO;QAClB,OAAO,OAAO,CAAC,iBAAiB,CAAC;IACnC,CAAC;IAED,eAAe,EAAE,KAAK,EACpB,EAAE,iBAAiB,EAAkB,EACrC,EAAE,WAAW,EAA4B,EACzC,EAAE,OAAO,EAAE,MAAM,EAAW,EAC5B,EAAE;QACF,MAAM,IAAI,GAAG,MAAM,OAAO,CAAC,oBAAoB,CAAC,IAAI,CAAC;YACnD,YAAY,EAAE,iBAAiB;YAC/B,MAAM,EAAE,WAAW,CAAC,CAAC,CAAC,IAAI,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,MAAM;SAC5D,CAAC,CAAC;QACH,OAAO,IAAI,CAAC;IACd,CAAC;CACF,CAAC"}
@@ -2,10 +2,10 @@ import { Context } from '../../../context.js';
2
2
  import { Assortment, AssortmentProduct as AssortmentProductType } from '@unchainedshop/core-assortments';
3
3
  import { Product } from '@unchainedshop/core-products';
4
4
  type HelperType<T> = (assortmentProduct: AssortmentProductType, _: never, context: Context) => T;
5
- export type AssortmentProductHelperTypes = {
5
+ export interface AssortmentProductHelperTypes {
6
6
  assortment: HelperType<Promise<Assortment>>;
7
7
  product: HelperType<Promise<Product>>;
8
- };
8
+ }
9
9
  export declare const AssortmentProduct: AssortmentProductHelperTypes;
10
10
  export {};
11
11
  //# sourceMappingURL=assortment-product-types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"assortment-product-types.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/type/assortment/assortment-product-types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAC9C,OAAO,EAAE,UAAU,EAAE,iBAAiB,IAAI,qBAAqB,EAAE,MAAM,iCAAiC,CAAC;AACzG,OAAO,EAAE,OAAO,EAAE,MAAM,8BAA8B,CAAC;AAEvD,KAAK,UAAU,CAAC,CAAC,IAAI,CAAC,iBAAiB,EAAE,qBAAqB,EAAE,CAAC,EAAE,KAAK,EAAE,OAAO,EAAE,OAAO,KAAK,CAAC,CAAC;AAEjG,MAAM,MAAM,4BAA4B,GAAG;IACzC,UAAU,EAAE,UAAU,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC,CAAC;IAC5C,OAAO,EAAE,UAAU,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC;CACvC,CAAC;AAEF,eAAO,MAAM,iBAAiB,EAAE,4BAc/B,CAAC"}
1
+ {"version":3,"file":"assortment-product-types.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/type/assortment/assortment-product-types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAC9C,OAAO,EAAE,UAAU,EAAE,iBAAiB,IAAI,qBAAqB,EAAE,MAAM,iCAAiC,CAAC;AACzG,OAAO,EAAE,OAAO,EAAE,MAAM,8BAA8B,CAAC;AAEvD,KAAK,UAAU,CAAC,CAAC,IAAI,CAAC,iBAAiB,EAAE,qBAAqB,EAAE,CAAC,EAAE,KAAK,EAAE,OAAO,EAAE,OAAO,KAAK,CAAC,CAAC;AAEjG,MAAM,WAAW,4BAA4B;IAC3C,UAAU,EAAE,UAAU,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC,CAAC;IAC5C,OAAO,EAAE,UAAU,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC;CACvC;AAED,eAAO,MAAM,iBAAiB,EAAE,4BAc/B,CAAC"}
@@ -3,7 +3,7 @@ import { Assortment } from '@unchainedshop/core-assortments';
3
3
  import { SearchFilterQuery } from '@unchainedshop/core-filters';
4
4
  export declare const AssortmentTypes: {
5
5
  assortmentPaths(obj: Assortment, _: any, { modules, loaders }: Context): Promise<{
6
- links: Array<import("@unchainedshop/core-assortments").AssortmentPathLink>;
6
+ links: import("@unchainedshop/core-assortments").AssortmentPathLink[];
7
7
  }[]>;
8
8
  children: (obj: Assortment, { includeInactive }: {
9
9
  includeInactive: boolean;
@@ -16,7 +16,7 @@ export declare const AssortmentTypes: {
16
16
  media(obj: Assortment, params: {
17
17
  limit: number;
18
18
  offset: number;
19
- tags?: Array<string>;
19
+ tags?: string[];
20
20
  }, { modules, loaders }: Context): Promise<import("@unchainedshop/core-assortments").AssortmentMediaType[]>;
21
21
  productAssignments(obj: Assortment, _: any, { modules }: Context): Promise<import("@unchainedshop/core-assortments").AssortmentProduct[]>;
22
22
  texts(obj: Assortment, { forceLocale }: {
@@ -1 +1 @@
1
- {"version":3,"file":"assortment-types.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/type/assortment/assortment-types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAC9C,OAAO,EAAE,UAAU,EAAE,MAAM,iCAAiC,CAAC;AAC7D,OAAO,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AAEhE,eAAO,MAAM,eAAe;yBACL,UAAU,gCAA2B,OAAO;;;oBAmB1D,UAAU,uBACM;QAAE,eAAe,EAAE,OAAO,CAAA;KAAE,eACpC,OAAO;gCASR,UAAU,uBACO;QAAE,eAAe,EAAE,OAAO,CAAA;KAAE,wBACnC,OAAO;2BAeF,UAAU,uBAAkB,OAAO;kCAY5B,UAAU,uBAAkB,OAAO;eAOhE,UAAU,UACP;QACN,KAAK,EAAE,MAAM,CAAC;QACd,MAAM,EAAE,MAAM,CAAC;QACf,IAAI,CAAC,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;KACtB,wBACqB,OAAO;4BAcD,UAAU,uBAAkB,OAAO;eAYhD,UAAU,mBAAmB;QAAE,WAAW,CAAC,EAAE,MAAM,CAAA;KAAE,kBAAkB,OAAO;0BASxF,UAAU,SACR;QACL,WAAW,CAAC,EAAE,MAAM,CAAC;QACrB,WAAW,CAAC,EAAE,iBAAiB,CAAC;QAChC,eAAe,EAAE,OAAO,CAAC;QACzB,sBAAsB,EAAE,OAAO,CAAC;QAChC,OAAO,CAAC,EAAE,MAAM,CAAC;KAClB,kBACe,OAAO;;;;;;CAkB1B,CAAC"}
1
+ {"version":3,"file":"assortment-types.d.ts","sourceRoot":"","sources":["../../../../src/resolvers/type/assortment/assortment-types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAC9C,OAAO,EAAE,UAAU,EAAE,MAAM,iCAAiC,CAAC;AAC7D,OAAO,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AAEhE,eAAO,MAAM,eAAe;yBACL,UAAU,gCAA2B,OAAO;;;oBAmB1D,UAAU,uBACM;QAAE,eAAe,EAAE,OAAO,CAAA;KAAE,eACpC,OAAO;gCASR,UAAU,uBACO;QAAE,eAAe,EAAE,OAAO,CAAA;KAAE,wBACnC,OAAO;2BAeF,UAAU,uBAAkB,OAAO;kCAY5B,UAAU,uBAAkB,OAAO;eAOhE,UAAU,UACP;QACN,KAAK,EAAE,MAAM,CAAC;QACd,MAAM,EAAE,MAAM,CAAC;QACf,IAAI,CAAC,EAAE,MAAM,EAAE,CAAC;KACjB,wBACqB,OAAO;4BAcD,UAAU,uBAAkB,OAAO;eAYhD,UAAU,mBAAmB;QAAE,WAAW,CAAC,EAAE,MAAM,CAAA;KAAE,kBAAkB,OAAO;0BASxF,UAAU,SACR;QACL,WAAW,CAAC,EAAE,MAAM,CAAC;QACrB,WAAW,CAAC,EAAE,iBAAiB,CAAC;QAChC,eAAe,EAAE,OAAO,CAAC;QACzB,sBAAsB,EAAE,OAAO,CAAC;QAChC,OAAO,CAAC,EAAE,MAAM,CAAC;KAClB,kBACe,OAAO;;;;;;CAkB1B,CAAC"}
@@ -29,7 +29,7 @@ export const AssortmentTypes = {
29
29
  });
30
30
  },
31
31
  async filterAssignments(obj, _, { modules }) {
32
- // TODO: Loader & move default sort to module
32
+ // TODO: move default sort to module
33
33
  return modules.assortments.filters.findFilters({
34
34
  assortmentId: obj._id,
35
35
  }, {
@@ -51,7 +51,7 @@ export const AssortmentTypes = {
51
51
  return (await loaders.assortmentMediasLoader.load({ assortmentId: obj._id })).slice(params.offset, params.offset + params.limit);
52
52
  },
53
53
  async productAssignments(obj, _, { modules }) {
54
- // TODO: Loader & move default sort to core module
54
+ // TODO: move default sort to core module
55
55
  return modules.assortments.products.findAssortmentProducts({
56
56
  assortmentId: obj._id,
57
57
  }, {
@@ -59,10 +59,10 @@ export const AssortmentTypes = {
59
59
  });
60
60
  },
61
61
  async texts(obj, { forceLocale }, requestContext) {
62
- const { localeContext, loaders } = requestContext;
62
+ const { locale, loaders } = requestContext;
63
63
  return loaders.assortmentTextLoader.load({
64
64
  assortmentId: obj._id,
65
- locale: forceLocale || localeContext.baseName,
65
+ locale: forceLocale ? new Intl.Locale(forceLocale) : locale,
66
66
  });
67
67
  },
68
68
  searchProducts: async (obj, query, requestContext) => {
@@ -75,7 +75,7 @@ export const AssortmentTypes = {
75
75
  assortmentId: obj._id,
76
76
  });
77
77
  return services.filters.searchProducts({ ...query, productIds, filterIds }, {
78
- locale: requestContext.localeContext,
78
+ locale: requestContext.locale,
79
79
  });
80
80
  },
81
81
  };
@@ -1 +1 @@
1
- {"version":3,"file":"assortment-types.js","sourceRoot":"","sources":["../../../../src/resolvers/type/assortment/assortment-types.ts"],"names":[],"mappings":"AAIA,MAAM,CAAC,MAAM,eAAe,GAAG;IAC7B,eAAe,CAAC,GAAe,EAAE,CAAC,EAAE,EAAE,OAAO,EAAE,OAAO,EAAW;QAC/D,OAAO,OAAO,CAAC,WAAW,CAAC,WAAW,CACpC;YACE,YAAY,EAAE,GAAG,CAAC,GAAG;SACtB,EACD;YACE,yBAAyB,EAAE,KAAK,EAAE,SAAS,EAAE,EAAE,CAC7C,OAAO,CAAC,wBAAwB,CAAC,IAAI,CAAC;gBACpC,SAAS;aACV,CAAC;YACJ,sBAAsB,EAAE,KAAK,EAAE,iBAAiB,EAAE,EAAE,CAClD,OAAO,CAAC,qBAAqB,CAAC,IAAI,CAAC;gBACjC,iBAAiB;aAClB,CAAC;SACL,CACF,CAAC;IACJ,CAAC;IAED,QAAQ,EAAE,KAAK,EACb,GAAe,EACf,EAAE,eAAe,EAAgC,EACjD,EAAE,OAAO,EAAW,EACpB,EAAE;QACF,OAAO,OAAO,CAAC,WAAW,CAAC,QAAQ,CAAC;YAClC,YAAY,EAAE,GAAG,CAAC,GAAG;YACrB,eAAe;SAChB,CAAC,CAAC;IACL,CAAC;IAED,aAAa,EAAE,KAAK,EAClB,UAAsB,EACtB,EAAE,eAAe,GAAG,KAAK,EAAgC,EACzD,EAAE,OAAO,EAAE,OAAO,EAAW,EAC7B,EAAE;QACF,MAAM,oBAAoB,GAAG,MAAM,OAAO,CAAC,qBAAqB,CAAC,IAAI,CAAC;YACpE,kBAAkB,EAAE,UAAU,CAAC,GAAG;SACnC,CAAC,CAAC;QAEH,MAAM,aAAa,GAAG,oBAAoB,CAAC,GAAG,CAAC,CAAC,EAAE,iBAAiB,EAAE,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D;QAClD,OAAO,OAAO,CAAC,WAAW,CAAC,QAAQ,CAAC,sBAAsB,CACxD;YACE,YAAY,EAAE,GAAG,CAAC,GAAG;SACtB,EACD;YACE,IAAI,EAAE,EAAE,OAAO,EAAE,CAAC,EAAE;SACrB,CACF,CAAC;IACJ,CAAC;IAED,KAAK,CAAC,KAAK,CAAC,GAAe,EAAE,EAAE,WAAW,EAA4B,EAAE,cAAuB;QAC7F,MAAM,EAAE,aAAa,EAAE,OAAO,EAAE,GAAG,cAAc,CAAC;QAClD,OAAO,OAAO,CAAC,oBAAoB,CAAC,IAAI,CAAC;YACvC,YAAY,EAAE,GAAG,CAAC,GAAG;YACrB,MAAM,EAAE,WAAW,IAAI,aAAa,CAAC,QAAQ;SAC9C,CAAC,CAAC;IACL,CAAC;IAED,cAAc,EAAE,KAAK,EACnB,GAAe,EACf,KAMC,EACD,cAAuB,EACvB,EAAE;QACF,MAAM,EAAE,OAAO,EAAE,QAAQ,EAAE,GAAG,cAAc,CAAC;QAC7C,MAAM,UAAU,GAAG,MAAM,OAAO,CAAC,WAAW,CAAC,cAAc,CAAC;YAC1D,YAAY,EAAE,GAAG,CAAC,GAAG;YACrB,sBAAsB,EAAE,KAAK,CAAC,sBAAsB;SACrD,CAAC,CAAC;QAEH,MAAM,SAAS,GAAG,MAAM,OAAO,CAAC,WAAW,CAAC,OAAO,CAAC,aAAa,CAAC;YAChE,YAAY,EAAE,GAAG,CAAC,GAAG;SACtB,CAAC,CAAC;QACH,OAAO,QAAQ,CAAC,OAAO,CAAC,cAAc,CACpC,EAAE,GAAG,KAAK,EAAE,UAAU,EAAE,SAAS,EAAE,EACnC;YACE,MAAM,EAAE,cAAc,CAAC,aAAa;SACrC,CACF,CAAC;IACJ,CAAC;CACF,CAAC"}
1
+ {"version":3,"file":"assortment-types.js","sourceRoot":"","sources":["../../../../src/resolvers/type/assortment/assortment-types.ts"],"names":[],"mappings":"AAIA,MAAM,CAAC,MAAM,eAAe,GAAG;IAC7B,eAAe,C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AAU,CAAC,CAAC,IAAI,CAAC,QAAQ,EAAE,YAAY,EAAE,CAAC,EAAE,KAAK,EAAE,OAAO,EAAE,OAAO,KAAK,CAAC,CAAC;AAEtF,MAAM,WAAW,mBAAmB;IAClC,OAAO,EAAE,UAAU,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC;IACtC,IAAI,EAAE,UAAU,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC;CACjC;AAED,eAAO,MAAM,QAAQ,EAAE,mBAYtB,CAAC"}
1
+ {"version":3,"file":"bookmark-types.d.ts","sourceRoot":"","sources":["../../../src/resolvers/type/bookmark-types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,IAAI,YAAY,EAAE,MAAM,+BAA+B,CAAC;AACzE,OAAO,EAAE,OAAO,EAAE,MAAM,8BAA8B,CAAC;AACvD,OAAO,EAAE,IAAI,EAAE,MAAM,2BAA2B,CAAC;AAEjD,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAE3C,MAAM,MAAM,UAAU,CAAC,CAAC,IAAI,CAAC,QAAQ,EAAE,YAAY,EAAE,CAAC,EAAE,KAAK,EAAE,OAAO,EAAE,OAAO,KAAK,CAAC,CAAC;AAEtF,MAAM,WAAW,mBAAmB;IAClC,OAAO,EAAE,UAAU,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC;IACtC,IAAI,EAAE,UAAU,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC;CACjC;AAED,eAAO,MAAM,QAAQ,EAAE,mBAWtB,CAAC"}
@@ -5,9 +5,8 @@ export const Bookmark = {
5
5
  });
6
6
  return product;
7
7
  },
8
- user: async (obj, _, { modules }) => {
9
- // TODO: use loader
10
- return modules.users.findUserById(obj.userId);
8
+ user: async (obj, _, { loaders }) => {
9
+ return loaders.userLoader.load({ userId: obj.userId });
11
10
  },
12
11
  };
13
12
  //# sourceMappingURL=bookmark-types.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"bookmark-types.js","sourceRoot":"","sources":["../../../src/resolvers/type/bookmark-types.ts"],"names":[],"mappings":"AAaA,MAAM,CAAC,MAAM,QAAQ,GAAwB;IAC3C,OAAO,EAAE,KAAK,EAAE,GAAG,EAAE,CAAC,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE;QACrC,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,aAAa,CAAC,IAAI,CAAC;YAC/C,SAAS,EAAE,GAAG,CAAC,SAAS;SACzB,CAAC,CAAC;QACH,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,IAAI,EAAE,KAAK,EAAE,GAAG,EAAE,CAAC,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE;QAClC,mBAAmB;QACnB,OAAO,OAAO,CAAC,KAAK,CAAC,YAAY,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IAChD,CAAC;CACF,CAAC"}
1
+ {"version":3,"file":"bookmark-types.js","sourceRoot":"","sources":["../../../src/resolvers/type/bookmark-types.ts"],"names":[],"mappings":"AAaA,MAAM,CAAC,MAAM,QAAQ,GAAwB;IAC3C,OAAO,EAAE,KAAK,EAAE,GAAG,EAAE,CAAC,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE;QACrC,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,aAAa,CAAC,IAAI,CAAC;YAC/C,SAAS,EAAE,GAAG,CAAC,SAAS;SACzB,CAAC,CAAC;QACH,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,IAAI,EAAE,KAAK,EAAE,GAAG,EAAE,CAAC,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE;QAClC,OAAO,OAAO,CAAC,UAAU,CAAC,IAAI,CAAC,EAAE,MAAM,EAAE,GAAG,CAAC,MAAM,EAAE,CAAC,CAAC;IACzD,CAAC;CACF,CAAC"}
@@ -6,7 +6,7 @@ export interface CountryHelperTypes {
6
6
  flagEmoji: HelperType<never, string>;
7
7
  isBase: HelperType<never, boolean>;
8
8
  name: HelperType<{
9
- forceLocale: string;
9
+ forceLocale?: string;
10
10
  }, string>;
11
11
  defaultCurrency: HelperType<never, Promise<Currency>>;
12
12
  }
@@ -1 +1 @@
1
- {"version":3,"file":"country-types.d.ts","sourceRoot":"","sources":["../../../src/resolvers/type/country-types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAC3C,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,+BAA+B,CAAC;AACvE,OAAO,EAAE,QAAQ,EAAE,MAAM,gCAAgC,CAAC;AAE1D,MAAM,MAAM,UAAU,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,OAAO,EAAE,WAAW,EAAE,MAAM,EAAE,CAAC,EAAE,OAAO,EAAE,OAAO,KAAK,CAAC,CAAC;AAExF,MAAM,WAAW,kBAAkB;IACjC,SAAS,EAAE,UAAU,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC;IACrC,MAAM,EAAE,UAAU,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC;IACnC,IAAI,EAAE,UAAU,CAAC;QAAE,WAAW,EAAE,MAAM,CAAA;KAAE,EAAE,MAAM,CAAC,CAAC;IAClD,eAAe,EAAE,UAAU,CAAC,KAAK,EAAE,OAAO,CAAC,QAAQ,CAAC,CAAC,CAAC;CACvD;AAED,eAAO,MAAM,OAAO,EAAE,kBAoBrB,CAAC"}
1
+ {"version":3,"file":"country-types.d.ts","sourceRoot":"","sources":["../../../src/resolvers/type/country-types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAC3C,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,+BAA+B,CAAC;AACvE,OAAO,EAAE,QAAQ,EAAE,MAAM,gCAAgC,CAAC;AAE1D,MAAM,MAAM,UAAU,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,OAAO,EAAE,WAAW,EAAE,MAAM,EAAE,CAAC,EAAE,OAAO,EAAE,OAAO,KAAK,CAAC,CAAC;AAExF,MAAM,WAAW,kBAAkB;IACjC,SAAS,EAAE,UAAU,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC;IACrC,MAAM,EAAE,UAAU,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC;IACnC,IAAI,EAAE,UAAU,CAAC;QAAE,WAAW,CAAC,EAAE,MAAM,CAAA;KAAE,EAAE,MAAM,CAAC,CAAC;IACnD,eAAe,EAAE,UAAU,CAAC,KAAK,EAAE,OAAO,CAAC,QAAQ,CAAC,CAAC,CAAC;CACvD;AAED,eAAO,MAAM,OAAO,EAAE,kBAiBrB,CAAC"}
@@ -1,10 +1,7 @@
1
1
  export const Country = {
2
- defaultCurrency: async (country, _, { modules }) => {
2
+ defaultCurrency: async (country, _, { loaders }) => {
3
3
  if (country.defaultCurrencyCode) {
4
- // TODO: use loader
5
- return modules.currencies.findCurrency({
6
- isoCode: country.defaultCurrencyCode,
7
- });
4
+ return loaders.currencyLoader.load({ isoCode: country.defaultCurrencyCode });
8
5
  }
9
6
  return null;
10
7
  },
@@ -14,8 +11,8 @@ export const Country = {
14
11
  isBase: (country, _, { modules }) => {
15
12
  return modules.countries.isBase(country);
16
13
  },
17
- name: (country, { forceLocale }, { localeContext, modules }) => {
18
- return modules.countries.name(country, forceLocale || localeContext.language);
14
+ name: (country, { forceLocale }, { locale, modules }) => {
15
+ return modules.countries.name(country, forceLocale ? new Intl.Locale(forceLocale) : locale);
19
16
  },
20
17
  };
21
18
  //# sourceMappingURL=country-types.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"country-types.js","sourceRoot":"","sources":["../../../src/resolvers/type/country-types.ts"],"names":[],"mappings":"AAaA,MAAM,CAAC,MAAM,OAAO,GAAuB;IACzC,eAAe,EAAE,KAAK,EAAE,OAAO,EAAE,CAAC,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE;QACjD,IAAI,OAAO,CAAC,mBAAmB,EAAE,CAAC;YAChC,mBAAmB;YACnB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AC9C,CAAC;IACD,MAAM,EAAE,CAAC,OAAO,EAAE,CAAC,EAAE,EAAE,OAAO,EAAW,EAAE,EAAE;QAC3C,OAAO,OAAO,CAAC,SAAS,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;IAC3C,CAAC;IACD,IAAI,EAAE,CAAC,OAAO,EAAE,EAAE,WAAW,EAAE,EAAE,EAAE,MAAM,EAAE,OAAO,EAAE,EAAE,EAAE;QACtD,OAAO,OAAO,CAAC,SAAS,CAAC,IAAI,CAAC,OAAO,EAAE,WAAW,CAAC,CAAC,CAAC,IAAI,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC;IAC9F,CAAC;CACF,CAAC"}
@@ -1,27 +1,24 @@
1
1
  import { Context } from '../../context.js';
2
2
  import { DeliveryProvider as DeliveryProviderType } from '@unchainedshop/core-delivery';
3
- import { DeliveryError } from '@unchainedshop/core';
4
- export type HelperType<P, T> = (provider: DeliveryProviderType, params: P, context: Context) => T;
5
- export interface DeliveryProviderHelperTypes {
6
- interface: HelperType<never, {
3
+ export declare const DeliveryProvider: {
4
+ interface(deliveryProvider: DeliveryProviderType): {
7
5
  _id: string;
8
6
  label: string;
9
7
  version: string;
10
- }>;
11
- isActive: HelperType<void, Promise<boolean>>;
12
- configurationError: HelperType<never, Promise<DeliveryError>>;
13
- simulatedPrice: HelperType<{
14
- currency?: string;
8
+ };
9
+ isActive(deliveryProvider: DeliveryProviderType, _: never, requestContext: Context): Promise<boolean>;
10
+ configurationError(deliveryProvider: DeliveryProviderType, _: never, requestContext: Context): Promise<import("@unchainedshop/core").DeliveryError>;
11
+ simulatedPrice(deliveryProvider: DeliveryProviderType, { currencyCode: forcedCurrencyCode, orderId, useNetPrice, context: providerContext, }: {
12
+ currencyCode?: string;
15
13
  orderId: string;
16
14
  useNetPrice?: boolean;
17
15
  context: any;
18
- }, Promise<{
16
+ }, requestContext: Context): Promise<{
19
17
  amount: number;
20
18
  currencyCode: string;
21
19
  countryCode: string;
22
20
  isTaxable: boolean;
23
21
  isNetPrice: boolean;
24
- }>>;
25
- }
26
- export declare const DeliveryProvider: DeliveryProviderHelperTypes;
22
+ }>;
23
+ };
27
24
  //# sourceMappingURL=delivery-provider-types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"delivery-provider-types.d.ts","sourceRoot":"","sources":["../../../src/resolvers/type/delivery-provider-types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAC3C,OAAO,EAAE,gBAAgB,IAAI,oBAAoB,EAAE,MAAM,8BAA8B,CAAC;AACxF,OAAO,EAAoB,aAAa,EAA2B,MAAM,qBAAqB,CAAC;AAE/F,MAAM,MAAM,UAAU,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,QAAQ,EAAE,oBAAoB,EAAE,MAAM,EAAE,CAAC,EAAE,OAAO,EAAE,OAAO,KAAK,CAAC,CAAC;AAElG,MAAM,WAAW,2BAA2B;IAC1C,SAAS,EAAE,UAAU,CACnB,KAAK,EACL;QACE,GAAG,EAAE,MAAM,CAAC;QACZ,KAAK,EAAE,MAAM,CAAC;QACd,OAAO,EAAE,MAAM,CAAC;KACjB,CACF,CAAC;IACF,QAAQ,EAAE,UAAU,CAAC,IAAI,EAAE,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC;IAC7C,kBAAkB,EAAE,UAAU,CAAC,KAAK,EAAE,OAAO,CAAC,aAAa,CAAC,CAAC,CAAC;IAC9D,cAAc,EAAE,UAAU,CACxB;QACE,QAAQ,CAAC,EAAE,MAAM,CAAC;QAClB,OAAO,EAAE,MAAM,CAAC;QAChB,WAAW,CAAC,EAAE,OAAO,CAAC;QACtB,OAAO,EAAE,GAAG,CAAC;KACd,EACD,OAAO,CAAC;QACN,MAAM,EAAE,MAAM,CAAC;QACf,YAAY,EAAE,MAAM,CAAC;QACrB,WAAW,EAAE,MAAM,CAAC;QACpB,SAAS,EAAE,OAAO,CAAC;QACnB,UAAU,EAAE,OAAO,CAAC;KACrB,CAAC,CACH,CAAC;CACH;AAED,eAAO,MAAM,gBAAgB,EAAE,2BA2D9B,CAAC"}
1
+ {"version":3,"file":"delivery-provider-types.d.ts","sourceRoot":"","sources":["../../../src/resolvers/type/delivery-provider-types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAC3C,OAAO,EAAE,gBAAgB,IAAI,oBAAoB,EAAE,MAAM,8BAA8B,CAAC;AAGxF,eAAO,MAAM,gBAAgB;gCACC,oBAAoB;;;;;+BAUf,oBAAoB,KAAK,KAAK,kBAAkB,OAAO;yCAK7C,oBAAoB,KAAK,KAAK,kBAAkB,OAAO;qCAM9E,oBAAoB,yFAMnC;QACD,YAAY,CAAC,EAAE,MAAM,CAAC;QACtB,OAAO,EAAE,MAAM,CAAC;QAChB,WAAW,CAAC,EAAE,OAAO,CAAC;QACtB,OAAO,EAAE,GAAG,CAAC;KACd,kBACe,OAAO;;;;;;;CAkC1B,CAAC"}