cloudcommerce 0.14.1 → 0.15.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (380) hide show
  1. package/.github/renovate.json +20 -3
  2. package/.github/workflows/{e2e-tests.yml → test-e2e.yml} +28 -19
  3. package/.vscode/settings.json +6 -0
  4. package/CHANGELOG.md +92 -0
  5. package/action.yml +74 -2
  6. package/ecomplus-stores/monocard/README.md +1 -1
  7. package/ecomplus-stores/monocard/README.pt-BR.md +1 -1
  8. package/ecomplus-stores/monocard/functions/ssr/tailwind.config.cjs +2 -3
  9. package/ecomplus-stores/monocard/functions/ssr/uno.config.cjs +3 -3
  10. package/ecomplus-stores/tia-sonia/README.md +1 -1
  11. package/ecomplus-stores/tia-sonia/README.pt-BR.md +1 -1
  12. package/ecomplus-stores/tia-sonia/functions/ssr/tailwind.config.cjs +2 -3
  13. package/ecomplus-stores/tia-sonia/functions/ssr/uno.config.cjs +3 -3
  14. package/package.json +14 -14
  15. package/packages/api/lib/api.d.ts +13 -12
  16. package/packages/api/lib/api.js +51 -29
  17. package/packages/api/lib/api.js.map +1 -1
  18. package/packages/api/package.json +3 -3
  19. package/packages/api/src/api.ts +52 -22
  20. package/packages/api/tests/index.test.ts +18 -3
  21. package/packages/api/{src/types → types}/brands.d.ts +1 -1
  22. package/packages/api/{lib/types → types}/carts.d.ts +5 -5
  23. package/packages/api/{src/types → types}/categories.d.ts +2 -2
  24. package/packages/api/{src/types → types}/collections.d.ts +2 -2
  25. package/packages/api/{src/types → types}/customers.d.ts +1 -1
  26. package/packages/api/{src/types → types}/grids.d.ts +1 -1
  27. package/packages/api/{lib/types → types}/orders.d.ts +13 -13
  28. package/packages/api/{lib/types → types}/products.d.ts +10 -10
  29. package/packages/api/{src/types.ts → types.d.ts} +254 -31
  30. package/packages/api/types.ts +1 -1
  31. package/packages/apps/affilate-program/CHANGELOG.md +1 -0
  32. package/packages/apps/affilate-program/README.md +1 -0
  33. package/packages/apps/affilate-program/lib/affilate-program.js +9 -0
  34. package/packages/apps/affilate-program/lib/affilate-program.js.map +1 -0
  35. package/packages/apps/affilate-program/lib/events-to-affilate-program.js +154 -0
  36. package/packages/apps/affilate-program/lib/events-to-affilate-program.js.map +1 -0
  37. package/packages/apps/affilate-program/lib/index.js +2 -0
  38. package/packages/apps/affilate-program/lib/index.js.map +1 -0
  39. package/packages/apps/affilate-program/package.json +30 -0
  40. package/packages/apps/affilate-program/src/affilate-program.ts +14 -0
  41. package/packages/apps/affilate-program/src/events-to-affilate-program.ts +184 -0
  42. package/packages/apps/affilate-program/src/index.ts +1 -0
  43. package/packages/apps/affilate-program/tsconfig.json +3 -0
  44. package/packages/apps/correios/package.json +2 -2
  45. package/packages/apps/custom-payment/lib/custom-payment-create-transaction.d.ts +4 -0
  46. package/packages/apps/custom-payment/lib/custom-payment.d.ts +4 -0
  47. package/packages/apps/custom-payment/package.json +1 -1
  48. package/packages/apps/custom-shipping/package.json +1 -1
  49. package/packages/apps/datafrete/package.json +4 -4
  50. package/packages/apps/discounts/lib-mjs/apply-discount.mjs +27 -2
  51. package/packages/apps/discounts/lib-mjs/helpers.mjs +4 -2
  52. package/packages/apps/discounts/package.json +2 -2
  53. package/packages/apps/emails/lib/functios-lib/utils.js.map +1 -1
  54. package/packages/apps/emails/package.json +3 -3
  55. package/packages/apps/emails/src/functios-lib/utils.ts +2 -1
  56. package/packages/apps/fb-conversions/lib/fb-conversions-events.js +20 -6
  57. package/packages/apps/fb-conversions/lib/fb-conversions-events.js.map +1 -1
  58. package/packages/apps/fb-conversions/package.json +3 -3
  59. package/packages/apps/fb-conversions/src/fb-conversions-events.ts +21 -6
  60. package/packages/apps/flash-courier/CHANGELOG.md +1 -0
  61. package/packages/apps/flash-courier/README.md +1 -0
  62. package/packages/apps/flash-courier/events.js +1 -0
  63. package/packages/apps/flash-courier/lib/flash-courier-events.d.ts +5 -0
  64. package/packages/apps/flash-courier/lib/flash-courier-events.js +14 -0
  65. package/packages/apps/flash-courier/lib/flash-courier-events.js.map +1 -0
  66. package/packages/apps/flash-courier/lib/flash-courier.d.ts +2 -0
  67. package/packages/apps/flash-courier/lib/flash-courier.js +6 -0
  68. package/packages/apps/flash-courier/lib/flash-courier.js.map +1 -0
  69. package/packages/apps/flash-courier/lib/index.d.ts +1 -0
  70. package/packages/apps/flash-courier/lib/index.js +2 -0
  71. package/packages/apps/flash-courier/lib/index.js.map +1 -0
  72. package/packages/apps/flash-courier/lib-mjs/calculate-flash-courier.mjs +246 -0
  73. package/packages/apps/flash-courier/lib-mjs/update-tracking.mjs +176 -0
  74. package/packages/apps/flash-courier/package.json +34 -0
  75. package/packages/apps/flash-courier/src/flash-courier-events.ts +13 -0
  76. package/packages/apps/flash-courier/src/flash-courier.ts +7 -0
  77. package/packages/apps/flash-courier/src/index.ts +1 -0
  78. package/packages/apps/flash-courier/tsconfig.json +6 -0
  79. package/packages/apps/frenet/lib/functions-lib/database.d.ts +4 -3
  80. package/packages/apps/frenet/lib/functions-lib/database.js.map +1 -1
  81. package/packages/apps/frenet/lib/functions-lib/update-fulfillments.d.ts +3 -2
  82. package/packages/apps/frenet/lib/functions-lib/update-fulfillments.js.map +1 -1
  83. package/packages/apps/frenet/lib-mjs/calculate-frenet.mjs +13 -6
  84. package/packages/apps/frenet/package.json +3 -3
  85. package/packages/apps/frenet/src/functions-lib/database.ts +4 -3
  86. package/packages/apps/frenet/src/functions-lib/update-fulfillments.ts +2 -1
  87. package/packages/apps/galaxpay/lib/functions-lib/all-parses.js +1 -1
  88. package/packages/apps/galaxpay/lib/functions-lib/all-parses.js.map +1 -1
  89. package/packages/apps/galaxpay/lib/functions-lib/ecom/events-to-galaxpay.js +18 -2
  90. package/packages/apps/galaxpay/lib/functions-lib/ecom/events-to-galaxpay.js.map +1 -1
  91. package/packages/apps/galaxpay/lib/functions-lib/galaxpay/auth/create-access.d.ts +2 -2
  92. package/packages/apps/galaxpay/lib/functions-lib/galaxpay/handle-plans.d.ts +1 -1
  93. package/packages/apps/galaxpay/lib/functions-lib/galaxpay/handle-plans.js.map +1 -1
  94. package/packages/apps/galaxpay/lib/functions-lib/galaxpay/update-subscription.js +19 -2
  95. package/packages/apps/galaxpay/lib/functions-lib/galaxpay/update-subscription.js.map +1 -1
  96. package/packages/apps/galaxpay/lib/functions-lib/galaxpay/webhook.js +18 -2
  97. package/packages/apps/galaxpay/lib/functions-lib/galaxpay/webhook.js.map +1 -1
  98. package/packages/apps/galaxpay/lib/functions-lib/utils.js +3 -3
  99. package/packages/apps/galaxpay/lib/functions-lib/utils.js.map +1 -1
  100. package/packages/apps/galaxpay/lib/galaxpay-create-transaction.d.ts +4 -0
  101. package/packages/apps/galaxpay/lib/galaxpay-create-transaction.js +19 -3
  102. package/packages/apps/galaxpay/lib/galaxpay-create-transaction.js.map +1 -1
  103. package/packages/apps/galaxpay/lib/galaxpay-list-payments.js +17 -1
  104. package/packages/apps/galaxpay/lib/galaxpay-list-payments.js.map +1 -1
  105. package/packages/apps/galaxpay/lib/galaxpay.d.ts +4 -0
  106. package/packages/apps/galaxpay/package.json +3 -3
  107. package/packages/apps/galaxpay/src/functions-lib/all-parses.ts +1 -1
  108. package/packages/apps/galaxpay/src/functions-lib/ecom/events-to-galaxpay.ts +21 -2
  109. package/packages/apps/galaxpay/src/functions-lib/galaxpay/auth/create-access.ts +2 -2
  110. package/packages/apps/galaxpay/src/functions-lib/galaxpay/handle-plans.ts +1 -2
  111. package/packages/apps/galaxpay/src/functions-lib/galaxpay/update-subscription.ts +21 -2
  112. package/packages/apps/galaxpay/src/functions-lib/galaxpay/webhook.ts +23 -5
  113. package/packages/apps/galaxpay/src/functions-lib/utils.ts +3 -3
  114. package/packages/apps/galaxpay/src/galaxpay-create-transaction.ts +19 -2
  115. package/packages/apps/galaxpay/src/galaxpay-list-payments.ts +19 -1
  116. package/packages/apps/google-analytics/lib/google-analytics-events.js +20 -4
  117. package/packages/apps/google-analytics/lib/google-analytics-events.js.map +1 -1
  118. package/packages/apps/google-analytics/package.json +3 -3
  119. package/packages/apps/google-analytics/src/google-analytics-events.ts +21 -4
  120. package/packages/apps/infinitepay/lib/functions-lib/add-installments.d.ts +1 -1
  121. package/packages/apps/infinitepay/lib/functions-lib/ip-auth/create-access.d.ts +2 -2
  122. package/packages/apps/infinitepay/lib/functions-lib/ip-auth/create-access.js +12 -8
  123. package/packages/apps/infinitepay/lib/functions-lib/ip-auth/create-access.js.map +1 -1
  124. package/packages/apps/infinitepay/lib/functions-lib/utils.js +3 -3
  125. package/packages/apps/infinitepay/lib/functions-lib/utils.js.map +1 -1
  126. package/packages/apps/infinitepay/lib/infinitepay.d.ts +4 -0
  127. package/packages/apps/infinitepay/lib/ip-create-transaction.d.ts +4 -0
  128. package/packages/apps/infinitepay/lib/ip-create-transaction.js +18 -2
  129. package/packages/apps/infinitepay/lib/ip-create-transaction.js.map +1 -1
  130. package/packages/apps/infinitepay/lib/ip-list-payments.js +19 -3
  131. package/packages/apps/infinitepay/lib/ip-list-payments.js.map +1 -1
  132. package/packages/apps/infinitepay/lib/ip-webhook.js.map +1 -1
  133. package/packages/apps/infinitepay/package.json +3 -3
  134. package/packages/apps/infinitepay/src/functions-lib/add-installments.ts +1 -1
  135. package/packages/apps/infinitepay/src/functions-lib/ip-auth/create-access.ts +14 -10
  136. package/packages/apps/infinitepay/src/functions-lib/utils.ts +3 -3
  137. package/packages/apps/infinitepay/src/ip-create-transaction.ts +20 -2
  138. package/packages/apps/infinitepay/src/ip-list-payments.ts +21 -3
  139. package/packages/apps/infinitepay/src/ip-webhook.ts +4 -5
  140. package/packages/apps/jadlog/lib-mjs/calculate-jadlog.mjs +19 -6
  141. package/packages/apps/jadlog/package.json +1 -1
  142. package/packages/apps/loyalty-points/lib/functions-lib/handle-loyalty-points-event.js.map +1 -1
  143. package/packages/apps/loyalty-points/lib/loyalty-create-transaction.d.ts +4 -0
  144. package/packages/apps/loyalty-points/lib/loyalty-create-transaction.js.map +1 -1
  145. package/packages/apps/loyalty-points/lib/loyalty-points.d.ts +4 -0
  146. package/packages/apps/loyalty-points/package.json +1 -1
  147. package/packages/apps/loyalty-points/src/functions-lib/handle-loyalty-points-event.ts +2 -2
  148. package/packages/apps/loyalty-points/src/loyalty-create-transaction.ts +4 -3
  149. package/packages/apps/melhor-envio/lib/functions-lib/events-to-melhor-envio.js +18 -14
  150. package/packages/apps/melhor-envio/lib/functions-lib/events-to-melhor-envio.js.map +1 -1
  151. package/packages/apps/melhor-envio/lib-mjs/calculate-melhor-envio.mjs +21 -15
  152. package/packages/apps/melhor-envio/package.json +3 -3
  153. package/packages/apps/melhor-envio/src/functions-lib/events-to-melhor-envio.ts +34 -22
  154. package/packages/apps/mercadopago/lib/mercadopago.d.ts +4 -0
  155. package/packages/apps/mercadopago/lib/mp-create-transaction.d.ts +4 -0
  156. package/packages/apps/mercadopago/lib/mp-create-transaction.js +14 -1
  157. package/packages/apps/mercadopago/lib/mp-create-transaction.js.map +1 -1
  158. package/packages/apps/mercadopago/lib/mp-list-payments.js +16 -7
  159. package/packages/apps/mercadopago/lib/mp-list-payments.js.map +1 -1
  160. package/packages/apps/mercadopago/lib/mp-webhook.js +10 -3
  161. package/packages/apps/mercadopago/lib/mp-webhook.js.map +1 -1
  162. package/packages/apps/mercadopago/package.json +3 -3
  163. package/packages/apps/mercadopago/src/mp-create-transaction.ts +15 -1
  164. package/packages/apps/mercadopago/src/mp-list-payments.ts +17 -7
  165. package/packages/apps/mercadopago/src/mp-webhook.ts +11 -3
  166. package/packages/apps/pagarme/assets/onload-expression.js +22 -8
  167. package/packages/apps/pagarme/assets/onload-expression.min.js +1 -1
  168. package/packages/apps/pagarme/lib/functions-lib/add-installments.d.ts +3 -3
  169. package/packages/apps/pagarme/lib/functions-lib/add-installments.js +5 -1
  170. package/packages/apps/pagarme/lib/functions-lib/add-installments.js.map +1 -1
  171. package/packages/apps/pagarme/lib/pagarme-create-transaction.d.ts +4 -0
  172. package/packages/apps/pagarme/lib/pagarme-create-transaction.js +27 -2
  173. package/packages/apps/pagarme/lib/pagarme-create-transaction.js.map +1 -1
  174. package/packages/apps/pagarme/lib/pagarme-list-payments.js +28 -6
  175. package/packages/apps/pagarme/lib/pagarme-list-payments.js.map +1 -1
  176. package/packages/apps/pagarme/lib/pagarme-webhook.js +10 -2
  177. package/packages/apps/pagarme/lib/pagarme-webhook.js.map +1 -1
  178. package/packages/apps/pagarme/lib/pagarme.d.ts +4 -0
  179. package/packages/apps/pagarme/package.json +3 -3
  180. package/packages/apps/pagarme/src/functions-lib/add-installments.ts +8 -2
  181. package/packages/apps/pagarme/src/pagarme-create-transaction.ts +28 -2
  182. package/packages/apps/pagarme/src/pagarme-list-payments.ts +37 -6
  183. package/packages/apps/pagarme/src/pagarme-webhook.ts +11 -2
  184. package/packages/apps/paghiper/lib/functions-lib/handle-webhook.js +11 -3
  185. package/packages/apps/paghiper/lib/functions-lib/handle-webhook.js.map +1 -1
  186. package/packages/apps/paghiper/lib/paghiper-create-transaction.d.ts +4 -0
  187. package/packages/apps/paghiper/lib/paghiper-create-transaction.js +9 -1
  188. package/packages/apps/paghiper/lib/paghiper-create-transaction.js.map +1 -1
  189. package/packages/apps/paghiper/lib/paghiper-list-payments.js +11 -4
  190. package/packages/apps/paghiper/lib/paghiper-list-payments.js.map +1 -1
  191. package/packages/apps/paghiper/lib/paghiper.d.ts +4 -0
  192. package/packages/apps/paghiper/package.json +3 -3
  193. package/packages/apps/paghiper/src/functions-lib/handle-webhook.ts +13 -4
  194. package/packages/apps/paghiper/src/paghiper-create-transaction.ts +9 -1
  195. package/packages/apps/paghiper/src/paghiper-list-payments.ts +15 -8
  196. package/packages/apps/pix/lib/functions-lib/get-certificate.js +3 -3
  197. package/packages/apps/pix/lib/functions-lib/get-certificate.js.map +1 -1
  198. package/packages/apps/pix/lib/pix-create-transaction.d.ts +4 -0
  199. package/packages/apps/pix/lib/pix-create-transaction.js +23 -3
  200. package/packages/apps/pix/lib/pix-create-transaction.js.map +1 -1
  201. package/packages/apps/pix/lib/pix-list-payments.js +23 -1
  202. package/packages/apps/pix/lib/pix-list-payments.js.map +1 -1
  203. package/packages/apps/pix/lib/pix.d.ts +4 -0
  204. package/packages/apps/pix/package.json +3 -3
  205. package/packages/apps/pix/src/functions-lib/get-certificate.ts +3 -3
  206. package/packages/apps/pix/src/pix-create-transaction.ts +26 -3
  207. package/packages/apps/pix/src/pix-list-payments.ts +26 -1
  208. package/packages/apps/tiny-erp/lib/integration/import-order-from-tiny.js +8 -7
  209. package/packages/apps/tiny-erp/lib/integration/import-order-from-tiny.js.map +1 -1
  210. package/packages/apps/tiny-erp/lib/integration/import-product-from-tiny.js +4 -2
  211. package/packages/apps/tiny-erp/lib/integration/import-product-from-tiny.js.map +1 -1
  212. package/packages/apps/tiny-erp/lib/integration/parsers/product-from-tiny.js.map +1 -1
  213. package/packages/apps/tiny-erp/package.json +4 -4
  214. package/packages/apps/tiny-erp/src/integration/import-order-from-tiny.ts +9 -9
  215. package/packages/apps/tiny-erp/src/integration/import-product-from-tiny.ts +4 -2
  216. package/packages/apps/tiny-erp/src/integration/parsers/product-from-tiny.ts +1 -1
  217. package/packages/apps/webhooks/lib/events-to-webhooks-app.js +12 -8
  218. package/packages/apps/webhooks/lib/events-to-webhooks-app.js.map +1 -1
  219. package/packages/apps/webhooks/package.json +3 -3
  220. package/packages/apps/webhooks/src/events-to-webhooks-app.ts +22 -12
  221. package/packages/cli/package.json +1 -1
  222. package/packages/config/lib/config.js +2 -4
  223. package/packages/config/lib/config.js.map +1 -1
  224. package/packages/config/lib/env.js +2 -4
  225. package/packages/config/lib/env.js.map +1 -1
  226. package/packages/config/package.json +1 -1
  227. package/packages/config/src/config.ts +4 -4
  228. package/packages/config/src/env.ts +4 -4
  229. package/packages/emails/package.json +3 -3
  230. package/packages/emails/tests/sendgrid.test.ts +2 -2
  231. package/packages/emails/tests/smtp.test.ts +2 -2
  232. package/packages/events/lib/firebase.js +4 -0
  233. package/packages/events/lib/firebase.js.map +1 -1
  234. package/packages/events/package.json +5 -3
  235. package/packages/events/src/firebase.ts +4 -0
  236. package/packages/feeds/package.json +2 -2
  237. package/packages/firebase/lib/config.d.ts +11 -1
  238. package/packages/firebase/lib/config.js +12 -0
  239. package/packages/firebase/lib/config.js.map +1 -1
  240. package/packages/firebase/lib/helpers/update-app-data.d.ts +1 -1
  241. package/packages/firebase/package.json +4 -4
  242. package/packages/firebase/src/config.ts +14 -1
  243. package/packages/i18n/package.json +1 -1
  244. package/packages/modules/lib/firebase/call-app-module.js +5 -0
  245. package/packages/modules/lib/firebase/call-app-module.js.map +1 -1
  246. package/packages/modules/lib/firebase/checkout.js.map +1 -1
  247. package/packages/modules/lib/firebase/functions-checkout/fix-items.js.map +1 -1
  248. package/packages/modules/lib/firebase/functions-checkout/handle-order-transaction.js.map +1 -1
  249. package/packages/modules/lib/firebase/functions-checkout/new-order.js.map +1 -1
  250. package/packages/modules/lib/firebase/functions-checkout/request-to-module.js +1 -1
  251. package/packages/modules/lib/firebase/functions-checkout/request-to-module.js.map +1 -1
  252. package/packages/modules/lib/firebase/functions-checkout/utils.js +1 -1
  253. package/packages/modules/lib/firebase/functions-checkout/utils.js.map +1 -1
  254. package/packages/modules/package.json +6 -5
  255. package/packages/modules/schemas/@checkout.cjs +5 -0
  256. package/packages/modules/schemas/apply_discount.cjs +6 -0
  257. package/packages/modules/schemas/create_transaction.cjs +22 -0
  258. package/packages/modules/src/firebase/call-app-module.ts +5 -0
  259. package/packages/modules/src/firebase/checkout.ts +9 -9
  260. package/packages/modules/src/firebase/functions-checkout/fix-items.ts +3 -3
  261. package/packages/modules/src/firebase/functions-checkout/handle-order-transaction.ts +8 -8
  262. package/packages/modules/src/firebase/functions-checkout/new-order.ts +6 -7
  263. package/packages/modules/src/firebase/functions-checkout/request-to-module.ts +2 -4
  264. package/packages/modules/src/firebase/functions-checkout/utils.ts +23 -23
  265. package/packages/modules/src/types/index.d.ts +4 -8
  266. package/packages/modules/tests/modules.test.mjs +1 -1
  267. package/packages/passport/package.json +3 -3
  268. package/packages/ssr/lib/firebase/serve-storefront.js +2 -2
  269. package/packages/ssr/lib/firebase/serve-storefront.js.map +1 -1
  270. package/packages/ssr/package.json +10 -10
  271. package/packages/ssr/src/firebase/serve-storefront.ts +2 -2
  272. package/packages/storefront/.base.eslintrc.cjs +4 -0
  273. package/packages/storefront/.eslintrc.cjs +4 -1
  274. package/packages/storefront/astro.config.mjs +6 -2
  275. package/packages/storefront/config/{storefront.cms.cjs → storefront.cms.js} +6 -5
  276. package/packages/storefront/{storefront.config.mjs → config/storefront.config.mjs} +5 -5
  277. package/packages/storefront/config/storefront.tailwind.cjs +266 -0
  278. package/packages/storefront/config/storefront.unocss.cjs +139 -0
  279. package/packages/storefront/dist/client/_astro/Carousel.93c2309b.js +1 -0
  280. package/packages/storefront/dist/client/_astro/HeroSlider.c5b673b3.js +1 -0
  281. package/packages/storefront/dist/client/_astro/{PitchBar.94f525f9.js → PitchBar.d0e3362e.js} +1 -1
  282. package/packages/storefront/dist/client/_astro/Prices.51598206.js +1 -0
  283. package/packages/storefront/dist/client/_astro/Prices.5186c09f.js +1 -0
  284. package/packages/storefront/dist/client/_astro/ProductShelf.d90bfc6e.js +1 -0
  285. package/packages/storefront/dist/client/_astro/ShopHeader.06c4c46e.js +4 -0
  286. package/packages/storefront/dist/client/_astro/_...slug_.ab554647.css +1 -0
  287. package/packages/storefront/dist/client/_astro/_plugin-vue_export-helper.8870d8dc.js +1 -0
  288. package/packages/storefront/dist/client/_astro/api.7f62c1ff.js +1 -0
  289. package/packages/storefront/dist/client/_astro/client.06720904.js +1 -0
  290. package/packages/storefront/dist/client/_astro/{firebase-app.d513d4b8.js → firebase-app.4381f424.js} +17 -4
  291. package/packages/storefront/dist/client/_astro/{format-money.1a95a3b5.js → format-money.3868f219.js} +1 -1
  292. package/packages/storefront/dist/client/_astro/{hoisted.be7b77c7.js → hoisted.6aebc438.js} +1 -1
  293. package/packages/storefront/dist/client/_astro/img.2ae78c70.js +1 -0
  294. package/packages/storefront/dist/client/_astro/index.3de006ba.js +1 -0
  295. package/packages/storefront/dist/client/_astro/{modules-info.bc2146d9.js → modules-info.c65d970c.js} +1 -1
  296. package/packages/storefront/dist/client/_astro/{runtime-dom.esm-bundler.e2053595.js → runtime-dom.esm-bundler.7a95af90.js} +1 -1
  297. package/packages/storefront/dist/client/_astro/{workbox-window.prod.es5.dc90f814.js → workbox-window.prod.es5.a7b12eab.js} +2 -2
  298. package/packages/storefront/dist/client/sw.js +1 -1
  299. package/packages/storefront/dist/client/{workbox-e0d788d4.js → workbox-5e0bf4e4.js} +1 -1
  300. package/packages/storefront/dist/server/_empty-middleware.mjs +3 -0
  301. package/packages/storefront/dist/server/chunks/_...51f243e0.mjs +35 -0
  302. package/packages/storefront/dist/server/chunks/account@_@astro.70d0a2b6.mjs +35 -0
  303. package/packages/storefront/dist/server/chunks/{astro.7ac24846.mjs → astro.c449fda8.mjs} +1479 -1217
  304. package/packages/storefront/dist/server/chunks/endpoint@_@js.58e19bda.mjs +35 -0
  305. package/packages/storefront/dist/server/chunks/fallback@_@astro.6c6e2bf9.mjs +35 -0
  306. package/packages/storefront/dist/server/chunks/index@_@astro.09a10813.mjs +35 -0
  307. package/packages/storefront/dist/server/chunks/index@_@astro.81422b02.mjs +35 -0
  308. package/packages/storefront/dist/server/chunks/pages/{all.a42f9fc6.mjs → _...slug_.astro.5667273a.mjs} +215 -1017
  309. package/packages/storefront/dist/server/chunks/pages/account.astro.72dc24f9.mjs +23 -0
  310. package/packages/storefront/dist/server/chunks/pages/endpoint.js.5d128d9d.mjs +119 -0
  311. package/packages/storefront/dist/server/chunks/pages/fallback.astro.72b8d520.mjs +64 -0
  312. package/packages/storefront/dist/server/chunks/pages/index.astro.e80eea52.mjs +1098 -0
  313. package/packages/storefront/dist/server/entry.mjs +57 -313
  314. package/packages/storefront/dist/server/renderers.mjs +333 -0
  315. package/packages/storefront/package.json +18 -21
  316. package/packages/storefront/scripts/prepare-monorepo.sh +0 -1
  317. package/packages/storefront/server.d.ts +8 -1
  318. package/packages/storefront/src/env.d.ts +0 -1
  319. package/packages/storefront/src/helpers/afetch.ts +2 -2
  320. package/packages/storefront/src/lib/assets/components.css +28 -0
  321. package/packages/storefront/src/lib/components/Carousel.vue +9 -23
  322. package/packages/storefront/src/lib/components/CarouselControl.vue +2 -2
  323. package/packages/storefront/src/lib/components/globals/AImg.vue +4 -7
  324. package/packages/storefront/src/lib/components/globals/ALink.vue +1 -1
  325. package/packages/storefront/src/lib/components/globals/Fade.vue +5 -30
  326. package/packages/storefront/src/lib/composables/use-hero-slider.ts +2 -0
  327. package/packages/storefront/src/lib/composables/use-prices.ts +4 -1
  328. package/packages/storefront/src/lib/composables/use-product-card.ts +104 -0
  329. package/packages/storefront/src/lib/composables/use-product-shelf.ts +91 -0
  330. package/packages/storefront/src/lib/composables/use-shop-header-submenu.ts +2 -0
  331. package/packages/storefront/src/lib/composables/use-sticky-header.ts +2 -0
  332. package/packages/storefront/src/lib/content.d.ts +3 -4
  333. package/packages/storefront/src/lib/layouts/Base.astro +5 -7
  334. package/packages/storefront/src/lib/layouts/BaseBody.astro +4 -8
  335. package/packages/storefront/src/lib/layouts/BaseHead.astro +1 -7
  336. package/packages/storefront/src/lib/layouts/BaseStateJson.astro +11 -18
  337. package/packages/storefront/src/lib/layouts/{sections/use-hero-section.ts → main/use-page-hero.ts} +7 -8
  338. package/packages/storefront/src/lib/layouts/main/use-page-sections.ts +98 -0
  339. package/packages/storefront/src/lib/layouts/use-page-layout.ts +4 -4
  340. package/packages/storefront/src/lib/ssr-context.ts +26 -19
  341. package/packages/storefront/src/lib/state/customer-session.ts +1 -1
  342. package/packages/storefront/tailwind.config.cjs +2 -225
  343. package/packages/storefront/uno.config.cjs +2 -141
  344. package/packages/types/index.ts +5 -1
  345. package/packages/types/modules/@checkout:params.d.ts +4 -0
  346. package/packages/types/modules/apply_discount:params.d.ts +4 -0
  347. package/packages/types/modules/create_transaction:response.d.ts +15 -0
  348. package/packages/types/package.json +1 -1
  349. package/packages/api/lib/types/brands.d.ts +0 -157
  350. package/packages/api/lib/types/categories.d.ts +0 -199
  351. package/packages/api/lib/types/collections.d.ts +0 -159
  352. package/packages/api/lib/types/customers.d.ts +0 -523
  353. package/packages/api/lib/types/grids.d.ts +0 -157
  354. package/packages/api/lib/types.d.ts +0 -132
  355. package/packages/api/lib/types.js +0 -2
  356. package/packages/api/lib/types.js.map +0 -1
  357. package/packages/api/src/types/applications.d.ts +0 -165
  358. package/packages/api/src/types/authentications.d.ts +0 -107
  359. package/packages/api/src/types/carts.d.ts +0 -360
  360. package/packages/api/src/types/orders.d.ts +0 -1720
  361. package/packages/api/src/types/products.d.ts +0 -1424
  362. package/packages/api/src/types/stores.d.ts +0 -123
  363. package/packages/storefront/.astro/types.d.ts +0 -117
  364. package/packages/storefront/config/storefront.cms.mjs +0 -72
  365. package/packages/storefront/dist/client/_astro/Carousel.e137cab2.js +0 -1
  366. package/packages/storefront/dist/client/_astro/HeroSlider.d677b64a.js +0 -1
  367. package/packages/storefront/dist/client/_astro/Prices.b8d4b8e4.js +0 -1
  368. package/packages/storefront/dist/client/_astro/ShopHeader.f12e72f6.js +0 -4
  369. package/packages/storefront/dist/client/_astro/_...slug_.48ea2ee1.css +0 -1
  370. package/packages/storefront/dist/client/_astro/_plugin-vue_export-helper.116fec5b.js +0 -1
  371. package/packages/storefront/dist/client/_astro/client.c2102734.js +0 -1
  372. package/packages/storefront/dist/client/_astro/index.1190ddf5.js +0 -1
  373. package/packages/storefront/dist/client/_astro/index.1eaf97c3.css +0 -1
  374. package/packages/storefront/dist/client/_astro/index.e56fc6b3.css +0 -1
  375. package/packages/storefront/dist/client/_astro/server.1dabec03.css +0 -1
  376. package/packages/storefront/src/lib/layouts/use-home-main.ts +0 -16
  377. /package/packages/api/{lib/types → types}/applications.d.ts +0 -0
  378. /package/packages/api/{lib/types → types}/authentications.d.ts +0 -0
  379. /package/packages/api/{lib/types → types}/stores.d.ts +0 -0
  380. /package/packages/storefront/src/lib/assets/{preflight.css → reset.css} +0 -0
@@ -10,7 +10,8 @@
10
10
  "dependencyDashboard": false,
11
11
  "ignoreDeps": [
12
12
  "node",
13
- "pnpm"
13
+ "pnpm",
14
+ "turbo"
14
15
  ],
15
16
  "packageRules": [
16
17
  {
@@ -20,7 +21,8 @@
20
21
  "*"
21
22
  ],
22
23
  "excludePackageNames": [
23
- "astro"
24
+ "astro",
25
+ "typescript"
24
26
  ],
25
27
  "excludePackagePrefixes": [
26
28
  "@astrojs/"
@@ -28,7 +30,22 @@
28
30
  "matchUpdateTypes": [
29
31
  "minor",
30
32
  "patch"
31
- ]
33
+ ],
34
+ "matchCurrentVersion": "!/^0/"
35
+ },
36
+ {
37
+ "groupName": "Non-major dependencies",
38
+ "groupSlug": "many-minor-patch",
39
+ "matchPackagePatterns": [
40
+ "*"
41
+ ],
42
+ "excludePackagePrefixes": [
43
+ "@astrojs/"
44
+ ],
45
+ "matchUpdateTypes": [
46
+ "patch"
47
+ ],
48
+ "matchCurrentVersion": "/^0/"
32
49
  },
33
50
  {
34
51
  "groupName": "Astro",
@@ -1,34 +1,37 @@
1
- name: E2E tests
1
+ name: Run E2E tests
2
2
 
3
3
  on:
4
4
  pull_request:
5
5
  paths:
6
6
  - "packages/**"
7
- - "!packages/storefront"
8
- - "!packages/ssr"
9
- - "!packages/feeds"
10
- - "!packages/passort"
11
- - "!packages/!18n"
12
- - "!packages/__skeleton"
7
+ - "!**/package.json"
8
+ - "!packages/storefront/**"
9
+ - "!packages/ssr/**"
10
+ - "!packages/feeds/**"
11
+ - "!packages/passort/**"
12
+ - "!packages/i18n/**"
13
+ - "!packages/__skeleton/**"
13
14
  push:
14
15
  branches:
15
16
  - main
16
17
  paths:
17
- - ".github/workflows/e2e-tests.yml"
18
+ - ".github/workflows/test-e2e.yml"
18
19
  - "packages/**"
19
- - "!packages/storefront"
20
- - "!packages/ssr"
21
- - "!packages/feeds"
22
- - "!packages/passort"
23
- - "!packages/!18n"
24
- - "!packages/__skeleton"
20
+ - "pnpm-lock.yaml"
21
+ - "!**/package.json"
22
+ - "!packages/storefront/**"
23
+ - "!packages/ssr/**"
24
+ - "!packages/feeds/**"
25
+ - "!packages/passort/**"
26
+ - "!packages/i18n/**"
27
+ - "!packages/__skeleton/**"
25
28
 
26
29
  jobs:
27
- setup:
28
- name: Test apps
30
+ test:
29
31
  runs-on: ubuntu-latest
30
32
  if: |
31
- !contains(github.event.head_commit.message, '[skip ci]')
33
+ !contains(github.event.head_commit.message, '[skip ci]') &&
34
+ !contains(github.event.head_commit.author.name, '[bot]')
32
35
 
33
36
  steps:
34
37
  - uses: actions/checkout@v3
@@ -80,6 +83,12 @@ jobs:
80
83
  ECOM_STORE_ID: ${{ secrets.ECOM_STORE_ID }}
81
84
  ECOM_AUTHENTICATION_ID: ${{ secrets.ECOM_AUTHENTICATION_ID }}
82
85
  ECOM_API_KEY: ${{ secrets.ECOM_API_KEY }}
86
+ MERCADOPAGO_TOKEN: ${{ secrets.MERCADOPAGO_TOKEN }}
87
+ FRENET_TOKEN: ${{ secrets.FRENET_TOKEN }}
88
+ GALAXPAY_ID: ${{ secrets.GALAXPAY_ID }}
89
+ GALAXPAY_HASH: ${{ secrets.GALAXPAY_HASH }}
90
+ INFINITEPAY_ID: ${{ secrets.INFINITEPAY_ID }}
91
+ INFINITEPAY_SECRET: ${{ secrets.INFINITEPAY_SECRET }}
83
92
  run: pnpm build
84
93
 
85
94
  - name: Get npm global directories
@@ -97,11 +106,11 @@ jobs:
97
106
  ${{ steps.npm-paths.outputs.LIB_PATH }}
98
107
  ${{ steps.npm-paths.outputs.BIN_PATH }}
99
108
  ~/.npm-global/bin
100
- key: ${{ runner.os }}-npm-globals-firebase-tools-12.0.1
109
+ key: ${{ runner.os }}-npm-globals-firebase-tools-12.3.1
101
110
 
102
111
  - if: steps.npm-g-cache.outputs.cache-hit != 'true'
103
112
  shell: bash
104
- run: npm install -g firebase-tools@12.0.1
113
+ run: npm install -g firebase-tools@12.3.1
105
114
 
106
115
  - name: Initialize Firebase emulators
107
116
  shell: bash
@@ -9,5 +9,11 @@
9
9
  "yaml.schemas": {
10
10
  "https://json.schemastore.org/github-workflow": "/.github/workflows/**/*.yml",
11
11
  "https://json.schemastore.org/github-action": "/action.yml"
12
+ },
13
+ "tailwindCSS.experimental.configFile": {
14
+ "packages/storefront/tailwind.config.cjs": "packages/**",
15
+ "store/functions/ssr/tailwind.config.cjs": "store/**",
16
+ "ecomplus-stores/monocard/functions/ssr/tailwind.config.cjs": "ecomplus-stores/monocard/**",
17
+ "ecomplus-stores/tia-sonia/functions/ssr/tailwind.config.cjs": "ecomplus-stores/tia-sonia/**"
12
18
  }
13
19
  }
package/CHANGELOG.md CHANGED
@@ -2,6 +2,98 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ## [0.15.0](https://github.com/ecomplus/cloud-commerce/compare/v0.14.1...v0.15.0) (2023-07-07)
6
+
7
+
8
+ ### ⚠ BREAKING CHANGES
9
+
10
+ * **storefront:** `useHeroSection` renamed (moved) to `usePageHero`, `useSections` renamed to `usePageSections`
11
+ * **storefront:** `useHomeMain` removed as it may not be used at all, `Sections.astro` file should import `useSections` directly
12
+ * **storefront:** `import 'uno.css';` must be mannualy imported now for every page
13
+ * **storefront:** New config/storefront.{tailwind|unocss}.cjs files in place of root ones to prevent duplicated (more or less complex) config generations
14
+ * **storefront:** Old (bad named) `preflight.css` file removed
15
+
16
+ May look to https://unocss.dev/guide/style-reset\#tailwind-compat in a future
17
+ * **storefront:** Removing no more needed `routeContext` prop on many nested Astro components, getting from `Astro.locals` instead
18
+ * **storefront:** Renamed exports `loadPageContext` and type `PageConext` to `loadRouteContext` and `RouteContext` instead
19
+ * **storefront:** Expecing content/pages/home.json instead of content/home.json , `HomeContent` removed from contend.d.ts exports
20
+
21
+ ### Features
22
+
23
+ * **affilate-program:** Setup app to handle simple affiliate program ([#167](https://github.com/ecomplus/cloud-commerce/issues/167)) ([7a29529](https://github.com/ecomplus/cloud-commerce/commit/7a29529f326f3e04646d29e9e6a8b3d54e1a170d))
24
+ * **api:** Add `SearchItems` and `SearchResult` types ([4326f7c](https://github.com/ecomplus/cloud-commerce/commit/4326f7c0ff0ccfa23937336c623bf48d4859946b))
25
+ * **api:** Add optional `config.fields` option ([af47797](https://github.com/ecomplus/cloud-commerce/commit/af47797d9f45f2741244b85cd0bb4a1e8f7826f0))
26
+ * **api:** Add optional config common params for list ([97c4e17](https://github.com/ecomplus/cloud-commerce/commit/97c4e179c1501e1a30053bc26ea19f42f0d263f2))
27
+ * **api:** Add optional global `$apiMergeConfig` for all in-context requests (may be overwritten) ([ef88575](https://github.com/ecomplus/cloud-commerce/commit/ef88575b3028ad86ca7b0a14971e10e3c14b880d))
28
+ * **apps:** Many optional env vars for apps credentials ([#179](https://github.com/ecomplus/cloud-commerce/issues/179)) ([881530a](https://github.com/ecomplus/cloud-commerce/commit/881530ae2383bd9ff37d794525f133cdd88d455c))
29
+ * **discounts:** Updating with original app v1.15.1 ([29f97ab](https://github.com/ecomplus/cloud-commerce/commit/29f97ab8aea801422ab2b4afea87aaad44e0b63f))
30
+ * **firebase:** Update config object with new `metafields: Record<string, any>` ([636e7e8](https://github.com/ecomplus/cloud-commerce/commit/636e7e82c82175042c7819f40828f92cb5dc1d19)), closes [#discussion_r1221705606](https://github.com/ecomplus/cloud-commerce/issues/discussion_r1221705606)
31
+ * **flash-courier:** Add app to integrate Flash Courier ([#166](https://github.com/ecomplus/cloud-commerce/issues/166)) ([a157a1c](https://github.com/ecomplus/cloud-commerce/commit/a157a1c5d38e5f77caeee33f4054d33faa76462a))
32
+ * **modules:** Updating schemas with https://github.com/ecomplus/modules-api/releases/tag/v0.12.58 ([e2a803d](https://github.com/ecomplus/cloud-commerce/commit/e2a803d9be83ddd91ff61b137f4c6fe18f7461af))
33
+ * **storefront:** Additional computed within `useProductCard` ([9f20334](https://github.com/ecomplus/cloud-commerce/commit/9f203344423bc011921bd13c79b3470790d1c30c))
34
+ * **storefront:** Additional computed within `useProductCard` ([bf19fa3](https://github.com/ecomplus/cloud-commerce/commit/bf19fa33730eb18be95d56d54424a8ceb521938c))
35
+ * **storefront:** Consistent named exports for all Vue composables ([603e8ec](https://github.com/ecomplus/cloud-commerce/commit/603e8ecbbc8969da268e539a333343721952451f))
36
+ * **storefront:** New `useSections` layout Astro composable ([ae709cd](https://github.com/ecomplus/cloud-commerce/commit/ae709cda9920a3ca008c292ac57f659163eb5190))
37
+ * **storefront:** Set `Astro.locals.routeContext` globally available on Astro components ([79b1111](https://github.com/ecomplus/cloud-commerce/commit/79b1111330d0464c9d8eeeb19b03a9ec2fccf43c))
38
+ * **storefront:** Setup `useProductCard` with fetch if product undefined and minor title i18n parse ([20d8f78](https://github.com/ecomplus/cloud-commerce/commit/20d8f78119158faf3cb4a5b6a8cdacb8acc5b6ea))
39
+ * **storefront:** Setup new `useProductShelf` Vue composable ([507e968](https://github.com/ecomplus/cloud-commerce/commit/507e968dd86e61996e412efd0e4c26f897d3b7a3))
40
+ * **storefront:** Update Astro to v2.6.0 ([35b7ac1](https://github.com/ecomplus/cloud-commerce/commit/35b7ac1fa2cd9d5b0c42e2f43562061b531beec7))
41
+
42
+
43
+ ### Bug Fixes
44
+
45
+ * **affiliate-program:** Fix handling orders/customers events ([#173](https://github.com/ecomplus/cloud-commerce/issues/173)) ([07ffc61](https://github.com/ecomplus/cloud-commerce/commit/07ffc61fd13754c117c598f721448a5ebb1ec43b))
46
+ * **api:** Fix `SearchItems` pictures to match partial `Products` picture ([abb0fd9](https://github.com/ecomplus/cloud-commerce/commit/abb0fd918346d757c2228f5af693a6cd6847491e))
47
+ * **api:** Fix `SearchItems` pictures type def ([c98edf6](https://github.com/ecomplus/cloud-commerce/commit/c98edf62a5f6b26a0ca574fa05780c44ea01dc42))
48
+ * **api:** Update `Endpoint` type def to accept doc find by field ([5ca53e7](https://github.com/ecomplus/cloud-commerce/commit/5ca53e7ec316e3bb4d400d8cf2302deecb42745b))
49
+ * **api:** Update `SearchItems` type with `item._score` number ([97b517e](https://github.com/ecomplus/cloud-commerce/commit/97b517e8aff75efa37483bffd8c183e11468ffde))
50
+ * **config:** Stop using `import.meta.env` for global config ([4100f74](https://github.com/ecomplus/cloud-commerce/commit/4100f745416860fb2ea16101749f1063955b9e33))
51
+ * **deps:** Update `@ecomplus/utils` to v1.5.0-rc.4 ([754f3ea](https://github.com/ecomplus/cloud-commerce/commit/754f3ea10ede64370cc0fce9b6fbd83047b4f8e0))
52
+ * **deps:** Update `@ecomplus/utils` to v1.5.0-rc.5 ([8794ca6](https://github.com/ecomplus/cloud-commerce/commit/8794ca65e51b8417a439bc01ab09c64398622fbb))
53
+ * **deps:** Update Astro to v2.5.5 ([3b6037c](https://github.com/ecomplus/cloud-commerce/commit/3b6037ca41df1cbb7cd28dc9548e005ce2466a65)), closes [#issuecomment-1568864726](https://github.com/ecomplus/cloud-commerce/issues/issuecomment-1568864726)
54
+ * **deps:** Update Astro to v2.5.6 with `@astrojs/vue` v2.2.1 ([38c906e](https://github.com/ecomplus/cloud-commerce/commit/38c906eaa93077d736bff733a289fd7f7afc4615))
55
+ * **deps:** Update dependency astro to v2.5.7 ([#169](https://github.com/ecomplus/cloud-commerce/issues/169)) ([b381ebe](https://github.com/ecomplus/cloud-commerce/commit/b381ebe9efbef136f50223dccc2d57a62b67855e))
56
+ * **deps:** Update non-major dependencies ([#162](https://github.com/ecomplus/cloud-commerce/issues/162)) ([76952eb](https://github.com/ecomplus/cloud-commerce/commit/76952eb62884cd11158827eb7269f141556ea998))
57
+ * **deps:** Update non-major dependencies ([#163](https://github.com/ecomplus/cloud-commerce/issues/163)) ([d2ec64f](https://github.com/ecomplus/cloud-commerce/commit/d2ec64f33a35a4722d6f608343e566555ddfbad2))
58
+ * **deps:** Update non-major dependencies ([#168](https://github.com/ecomplus/cloud-commerce/issues/168)) ([7363e85](https://github.com/ecomplus/cloud-commerce/commit/7363e8511fb62b7b601df67efe7363b8f8bb4ef4))
59
+ * **deps:** Update non-major dependencies ([#171](https://github.com/ecomplus/cloud-commerce/issues/171)) ([79c5240](https://github.com/ecomplus/cloud-commerce/commit/79c52409f142dac2f5901da502ae9e55b9e4447d))
60
+ * **deps:** Update non-major dependencies ([#176](https://github.com/ecomplus/cloud-commerce/issues/176)) ([495f0fa](https://github.com/ecomplus/cloud-commerce/commit/495f0fa77a934e42e74f99217686feb3f9587245))
61
+ * **flash-courier:** Fix functions namespace and package exports filename ([11628d6](https://github.com/ecomplus/cloud-commerce/commit/11628d66dfac67a970e75774dd8eb8249a185c7b))
62
+ * **flash-courier:** Update app event function ([#174](https://github.com/ecomplus/cloud-commerce/issues/174)) ([74e5120](https://github.com/ecomplus/cloud-commerce/commit/74e5120a6bb2fa74e1d3aedbb6598a02685e72cd))
63
+ * **flash-courier:** Updating tracking status parses ([d7914ce](https://github.com/ecomplus/cloud-commerce/commit/d7914ce3d82d0425f73035dd24968660751b0e66))
64
+ * **flash-courier:** Updating with legacy v1.3.0 ([b4bffd3](https://github.com/ecomplus/cloud-commerce/commit/b4bffd361e6c9d36bb4a4b685a28e8be365f653b))
65
+ * Many apps type def fixes ([#177](https://github.com/ecomplus/cloud-commerce/issues/177)) [skip ci] ([9194b1e](https://github.com/ecomplus/cloud-commerce/commit/9194b1e577c377eda8d28e2eff29edf367a755ea))
66
+ * **mercadopago:** Fix path for oload expression script on list payments ([#180](https://github.com/ecomplus/cloud-commerce/issues/180)) ([ebd6d5d](https://github.com/ecomplus/cloud-commerce/commit/ebd6d5d62aacd34b86de0e1e97b204018ec3bebf))
67
+ * **modules:** Type fixes with nested IDs and minor syntax updates ([06fb211](https://github.com/ecomplus/cloud-commerce/commit/06fb211c01ad67628f0d5665416e094ad31cec4c))
68
+ * **pagarme:** Update with legacy v1.5.0 ([df2e61d](https://github.com/ecomplus/cloud-commerce/commit/df2e61de9157805d1e5be8eae5a03f91e903afa5))
69
+ * Replacing wrong (out of date) imports from `@cloudcommerce/api/lib/types` ([7e6971c](https://github.com/ecomplus/cloud-commerce/commit/7e6971c5c46a2e14480d37123fc30d663ebe5b76))
70
+ * **storefront:** Caching only root CMS content (not collections) ([ef77ae8](https://github.com/ecomplus/cloud-commerce/commit/ef77ae860f86831828535bcd806f2faab80fe5c3))
71
+ * **storefront:** Fix `useProductCard` composable returned type ([c07a525](https://github.com/ecomplus/cloud-commerce/commit/c07a52555d5ebdce54f5ba29eb2159a5243efe50))
72
+ * **storefront:** Fix global <AImg> prop `picture` typedef ([39ac9e5](https://github.com/ecomplus/cloud-commerce/commit/39ac9e51d309a7b7ffc16f0a59c737c6412878e7))
73
+ * **storefront:** Properly handling product shelf options ([650fc6e](https://github.com/ecomplus/cloud-commerce/commit/650fc6e0179330d3cc0e4a19ddf1d7e63f0a8c91))
74
+ * **storefront:** Removing `uno.css` import to be imported after custom UI classes ([b66f847](https://github.com/ecomplus/cloud-commerce/commit/b66f8479ad4511a5f5f3d535a728ac866a489092))
75
+ * **storefront:** Strict `routeContext.cmsContent` type with page content object ([aaa7355](https://github.com/ecomplus/cloud-commerce/commit/aaa73557bde2757b56993bc71af9633804d62fff))
76
+ * **storefront:** Update `useProductShelf` for easier use on Astro (SSR) composables ([e6e562b](https://github.com/ecomplus/cloud-commerce/commit/e6e562b9aaeb52ab5397cd2474c0732631f40957))
77
+ * **storefront:** Update astro ([#189](https://github.com/ecomplus/cloud-commerce/issues/189)) ([4634f88](https://github.com/ecomplus/cloud-commerce/commit/4634f8833343ed85d8850c238763d681bde65a15))
78
+ * **storefront:** Update astro to v2.7.0 ([#182](https://github.com/ecomplus/cloud-commerce/issues/182)) ([6588688](https://github.com/ecomplus/cloud-commerce/commit/65886887ad3c9fd1e6c41281618b08c048a39165))
79
+ * **storefront:** Update dependency astro to v2.6.3 ([#170](https://github.com/ecomplus/cloud-commerce/issues/170)) ([ce8379d](https://github.com/ecomplus/cloud-commerce/commit/ce8379dd30d4699660331652a18b7d2aa31c3a82))
80
+ * **storefront:** Update global `<ALink>` to keep same window on relative href ([ca15480](https://github.com/ecomplus/cloud-commerce/commit/ca154806666d747b5eef33f6ae521be0ccc8e75d))
81
+ * **tiny-erp:** Type fixes with nested resource IDs and resource find ([165400c](https://github.com/ecomplus/cloud-commerce/commit/165400cdf2d8e314c3b71addfd3b8eec293de228))
82
+ * **types:** Fix Carts interface items nested IDs [skip ci] ([c7c1fa2](https://github.com/ecomplus/cloud-commerce/commit/c7c1fa230f10d7c5936e46ee36590aa356aefd89))
83
+ * **types:** Properly defining nested Object IDs on many resources interfaces ([8a20504](https://github.com/ecomplus/cloud-commerce/commit/8a20504082f33d31645a8eabb0ab3d681c1ae401))
84
+ * **types:** Update CMS settings metafields accept any value ([2fd0597](https://github.com/ecomplus/cloud-commerce/commit/2fd0597d00b4e5149c7b650b0c2e069ff4d22f28))
85
+
86
+
87
+ ### build
88
+
89
+ * **storefront:** Read custom `.ui-*` classes from src/assets/style.css for Tailwind IntelliSense ([244a9e7](https://github.com/ecomplus/cloud-commerce/commit/244a9e7023c4643ddb766ff7a6ef4f58baa248bb))
90
+
91
+
92
+ * **storefront:** Renaming (SSR) `pageContext` to `routeContext` ([ceffb44](https://github.com/ecomplus/cloud-commerce/commit/ceffb44fd4e43fbdf51fa790019aa4fef4ad4e2a))
93
+ * **storefront:** Renaming `assets/preflight.css` to `assets/reset.css` ([cd01bd9](https://github.com/ecomplus/cloud-commerce/commit/cd01bd93b662f196ffeecb905fc1dd485a387e00))
94
+ * **storefront:** Renaming Astro sections composables ([5cf529c](https://github.com/ecomplus/cloud-commerce/commit/5cf529c2284ebace2e13670ba4dfb38dee79db4b))
95
+ * **storefront:** Using generic `PageContent` typedef instead of previous `HomeContent` ([4f566c9](https://github.com/ecomplus/cloud-commerce/commit/4f566c9fabe39ce7e32cf3bb4d315182da1d08e7))
96
+
5
97
  ### [0.14.1](https://github.com/ecomplus/cloud-commerce/compare/v0.14.0...v0.14.1) (2023-05-17)
6
98
 
7
99
 
package/action.yml CHANGED
@@ -42,6 +42,42 @@ inputs:
42
42
  description: 'App: Optional Galax Pay partner hash'
43
43
  datafrete-operator-token:
44
44
  description: 'App: Random token (https://randomkeygen.com/) to validate Datafrete webhooks'
45
+ mercadopago-token:
46
+ description: 'App: Mercadopago API access token'
47
+ frenet-token:
48
+ description: 'App: Frenet API token'
49
+ galaxpay-id:
50
+ description: 'App: Galax Pay ID'
51
+ galaxpay-hash:
52
+ description: 'App: Galax Pay hash'
53
+ ga-measurement-id:
54
+ description: 'App: Google Analytics API measurement id'
55
+ ga-api-token:
56
+ description: 'App: Google Analytics API secret'
57
+ infinitepay-id:
58
+ description: 'App: InifinitePay client ID'
59
+ infinitepay-secret:
60
+ description: 'App: InifinitePay client secret'
61
+ fb-pixel-id:
62
+ description: 'App: Facebook pixel ID'
63
+ fb-graph-token:
64
+ description: 'App: Facebook Graph token'
65
+ jadlog-contract-token:
66
+ description: 'App: Jadlog contract token'
67
+ pagarme-encrypt-key:
68
+ description: 'App: Pagar.me encryption Key'
69
+ pagarme-token:
70
+ description: 'App: Pagar.me API token'
71
+ pagarme-partner-id:
72
+ description: 'App: Pagar.me partner ID'
73
+ paghiper-token:
74
+ description: 'App: PagHiper API token'
75
+ pix-credentials:
76
+ description: 'App: Pix credentials'
77
+ flashcourier-contract:
78
+ description: 'App: Flash Courier contract'
79
+ webhooks-token:
80
+ description: 'App: Webhooks token'
45
81
 
46
82
  outputs: {}
47
83
 
@@ -80,11 +116,11 @@ runs:
80
116
  ${{ steps.npm-paths.outputs.LIB_PATH }}
81
117
  ${{ steps.npm-paths.outputs.BIN_PATH }}
82
118
  ~/.npm-global/bin
83
- key: ${{ runner.os }}-npm-g-firebase-tools-12.0.1
119
+ key: ${{ runner.os }}-npm-g-firebase-tools-12.3.1
84
120
 
85
121
  - if: ${{ github.event_name == 'push' && steps.npm-g-cache.outputs.cache-hit != 'true' }}
86
122
  shell: bash
87
- run: npm i --location=global firebase-tools@12.0.1
123
+ run: npm i --location=global firebase-tools@12.3.1
88
124
 
89
125
  - if: steps.npm-cache.outputs.cache-hit != 'true'
90
126
  name: Install functions dependencies
@@ -163,6 +199,24 @@ runs:
163
199
  GALAXPAY_PARTNER_ID: ${{ inputs.galaxpay-partner-id }}
164
200
  GALAXPAY_PARTNER_HASH: ${{ inputs.galaxpay-partner-hash }}
165
201
  DATAFRETE_OPERATOR_TOKEN: ${{ inputs.datafrete-operator-token }}
202
+ MERCADOPAGO_TOKEN: ${{ inputs.mercadopago-token }}
203
+ FRENET_TOKEN: ${{ inputs.frenet-token }}
204
+ GALAXPAY_ID: ${{ inputs.galaxpay-id }}
205
+ GALAXPAY_HASH: ${{ inputs.galaxpay-hash }}
206
+ GA_MEASUREMENT_ID: ${{ inputs.ga-measurement-id }}
207
+ GA_API_TOKEN: ${{ inputs.ga-api-token }}
208
+ INFINITEPAY_ID: ${{ inputs.infinitepay-id }}
209
+ INFINITEPAY_SECRET: ${{ inputs.infinitepay-secret }}
210
+ FB_PIXEL_ID: ${{ inputs.fb-pixel-id }}
211
+ FB_GRAPH_TOKEN: ${{ inputs.fb-graph-token }}
212
+ JADLOG_CONTRACT_TOKEN: ${{ inputs.jadlog-contract-token }}
213
+ PAGARME_ENCRYPT_KEY: ${{ inputs.pagarme-encrypt-key }}
214
+ PAGARME_TOKEN: ${{ inputs.pagarme-token }}
215
+ PAGARME_PARTNER_ID: ${{ inputs.pagarme-partner-id }}
216
+ PAGHIPER_TOKEN: ${{ inputs.paghiper-token }}
217
+ PIX_CREDENTIALS: ${{ inputs.pix-credentials }}
218
+ FLASHCOURIER_CONTRACT: ${{ inputs.flashcourier-contract }}
219
+ WEBHOOKS_TOKEN: ${{ inputs.webhooks-token }}
166
220
  run: |
167
221
  export GAC_FILENAME=".gac-$RANDOM.json"
168
222
  echo $FIREBASE_SERVICE_ACCOUNT > $GAC_FILENAME
@@ -185,6 +239,24 @@ runs:
185
239
  GALAXPAY_PARTNER_ID=$GALAXPAY_PARTNER_ID
186
240
  GALAXPAY_PARTNER_HASH=$GALAXPAY_PARTNER_HASH
187
241
  DATAFRETE_OPERATOR_TOKEN=$DATAFRETE_OPERATOR_TOKEN
242
+ MERCADOPAGO_TOKEN=$MERCADOPAGO_TOKEN
243
+ FRENET_TOKEN:$FRENET_TOKEN
244
+ GALAXPAY_ID=$GALAXPAY_ID
245
+ GALAXPAY_HASH=$GALAXPAY_HASH
246
+ GA_MEASUREMENT_ID=$GA_MEASUREMENT_ID
247
+ GA_API_TOKEN=$GA_API_TOKEN
248
+ INFINITEPAY_ID=$INFINITEPAY_ID
249
+ INFINITEPAY_SECRET=$INFINITEPAY_SECRET
250
+ FB_PIXEL_ID=$FB_PIXEL_ID
251
+ FB_GRAPH_TOKEN=$FB_GRAPH_TOKEN
252
+ JADLOG_CONTRACT_TOKEN=$JADLOG_CONTRACT_TOKEN
253
+ PAGARME_ENCRYPT_KEY=$PAGARME_ENCRYP_KEY
254
+ PAGARME_TOKEN=$PAGARME_TOKEN
255
+ PAGARME_PARTNER_ID=$PAGARME_PARTNER_ID
256
+ PAGHIPER_TOKEN=$PAGHIPER_TOKEN
257
+ PIX_CREDENTIALS=$PIX_CREDENTIALS
258
+ FLASHCOURIER_CONTRACT=$FLASHCOURIER_CONTRACT
259
+ WEBHOOKS_TOKEN=$WEBHOOKS_TOKEN
188
260
  " > functions/.env
189
261
  if [ -z "$DEPLOY_CODEBASE" ]; then
190
262
  GOOGLE_APPLICATION_CREDENTIALS=$GAC_FILENAME npm run deploy
@@ -10,7 +10,7 @@
10
10
 
11
11
  2. Go to _Creation > Firestore Database_ page (on sidebar) and _create database_:
12
12
  - Just bypass with default production mode and rules;
13
- - Select region `southamerica-east1` (recommended, or multi-region `nam5 (us-central)`);
13
+ - Select region `us-east4` (recommended, or multi-region `nam5 (us-central)`);
14
14
 
15
15
  3. Firebase free plan doesn't support sending external HTTP requests, so you'll need to upgrade to _Blaze_ (on demand) plan;
16
16
 
@@ -10,7 +10,7 @@
10
10
 
11
11
  2. Vá para a página _Criação > Firestore Database_ (menu lateral) e clique em _criar banco de dados_:
12
12
  - Pule com o modo e as regras de produção padrão;
13
- - Selecione a região `southamerica-east1` (recomendado);
13
+ - Selecione a região `us-east4` ([recomendado](https://github.com/ecomplus/cloud-commerce/issues/164));
14
14
 
15
15
  3. O plano gratuito do Firebase não é compatível com o envio de solicitações HTTP externas, portanto você precisará fazer upgrade para o plano _Blaze_ (sob demanda);
16
16
 
@@ -1,7 +1,7 @@
1
1
  process.env.STOREFRONT_BASE_DIR = __dirname;
2
2
 
3
3
  // eslint-disable-next-line import/no-extraneous-dependencies
4
- const defaultConfig = require('@cloudcommerce/storefront/tailwind.config.cjs');
4
+ const { genTailwindConfig } = require('@cloudcommerce/storefront/config/storefront.tailwind.cjs');
5
5
 
6
6
  const themeOptions = {
7
7
  baseColor: 'gray',
@@ -22,9 +22,8 @@ const themeOptions = {
22
22
  'arrow-left': 'arrow-left-line',
23
23
  },
24
24
  };
25
- const genTailwindConfig = () => defaultConfig.genTailwindConfig(themeOptions);
26
25
 
27
26
  module.exports = {
28
- ...genTailwindConfig(),
27
+ ...genTailwindConfig(themeOptions),
29
28
  themeOptions,
30
29
  };
@@ -1,5 +1,5 @@
1
1
  // eslint-disable-next-line import/no-extraneous-dependencies
2
- const { genUnoCSSConfig } = require('@cloudcommerce/storefront/uno.config');
3
- const { themeOptions } = require('./tailwind.config.cjs');
2
+ const { genUnoCSSConfig } = require('@cloudcommerce/storefront/config/storefront.unocss.cjs');
3
+ const tailwindConfig = require('./tailwind.config.cjs');
4
4
 
5
- export default genUnoCSSConfig(themeOptions);
5
+ export default genUnoCSSConfig(tailwindConfig);
@@ -10,7 +10,7 @@
10
10
 
11
11
  2. Go to _Creation > Firestore Database_ page (on sidebar) and _create database_:
12
12
  - Just bypass with default production mode and rules;
13
- - Select region `southamerica-east1` (recommended, or multi-region `nam5 (us-central)`);
13
+ - Select region `us-east4` (recommended, or multi-region `nam5 (us-central)`);
14
14
 
15
15
  3. Firebase free plan doesn't support sending external HTTP requests, so you'll need to upgrade to _Blaze_ (on demand) plan;
16
16
 
@@ -10,7 +10,7 @@
10
10
 
11
11
  2. Vá para a página _Criação > Firestore Database_ (menu lateral) e clique em _criar banco de dados_:
12
12
  - Pule com o modo e as regras de produção padrão;
13
- - Selecione a região `southamerica-east1` (recomendado);
13
+ - Selecione a região `us-east4` (recomendado);
14
14
 
15
15
  3. O plano gratuito do Firebase não é compatível com o envio de solicitações HTTP externas, portanto você precisará fazer upgrade para o plano _Blaze_ (sob demanda);
16
16
 
@@ -1,16 +1,15 @@
1
1
  process.env.STOREFRONT_BASE_DIR = __dirname;
2
2
 
3
3
  // eslint-disable-next-line import/no-extraneous-dependencies
4
- const defaultConfig = require('@cloudcommerce/storefront/tailwind.config.cjs');
4
+ const { genTailwindConfig } = require('@cloudcommerce/storefront/config/storefront.tailwind.cjs');
5
5
 
6
6
  const themeOptions = {
7
7
  generalIcons: 'tabler',
8
8
  shoppingCartIcon: 'paper-bag',
9
9
  cashbackIcon: 'arrow-back-up',
10
10
  };
11
- const genTailwindConfig = () => defaultConfig.genTailwindConfig(themeOptions);
12
11
 
13
12
  module.exports = {
14
- ...genTailwindConfig(),
13
+ ...genTailwindConfig(themeOptions),
15
14
  themeOptions,
16
15
  };
@@ -1,5 +1,5 @@
1
1
  // eslint-disable-next-line import/no-extraneous-dependencies
2
- const { genUnoCSSConfig } = require('@cloudcommerce/storefront/uno.config');
3
- const { themeOptions } = require('./tailwind.config.cjs');
2
+ const { genUnoCSSConfig } = require('@cloudcommerce/storefront/config/storefront.unocss.cjs');
3
+ const tailwindConfig = require('./tailwind.config.cjs');
4
4
 
5
- export default genUnoCSSConfig(themeOptions);
5
+ export default genUnoCSSConfig(tailwindConfig);
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "cloudcommerce",
3
3
  "type": "module",
4
- "version": "0.14.1",
4
+ "version": "0.15.0",
5
5
  "description": "Open fair-code headless commerce platform: API-first, microservices based, event driven and cloud native",
6
6
  "main": "packages/api/lib/index.js",
7
7
  "author": "E-Com Club Softwares para E-commerce <ti@e-com.club>",
@@ -16,25 +16,24 @@
16
16
  }
17
17
  },
18
18
  "devDependencies": {
19
- "@commitlint/cli": "^17.6.3",
20
- "@commitlint/config-conventional": "^17.6.3",
21
- "@commitlint/rules": "^17.6.1",
22
- "@types/node": "^18.16.9",
23
- "@typescript-eslint/eslint-plugin": "^5.59.6",
24
- "@typescript-eslint/parser": "^5.59.6",
25
- "esbuild": "^0.17.19",
26
- "eslint": "^8.40.0",
19
+ "@commitlint/cli": "^17.6.6",
20
+ "@commitlint/config-conventional": "^17.6.6",
21
+ "@commitlint/rules": "^17.6.5",
22
+ "@types/node": "^18.16.19",
23
+ "@typescript-eslint/eslint-plugin": "^5.60.1",
24
+ "@typescript-eslint/parser": "^5.60.1",
25
+ "eslint": "^8.44.0",
27
26
  "eslint-config-airbnb-base": "^15.0.0",
28
27
  "eslint-plugin-import": "^2.27.5",
29
- "eslint-plugin-vue": "^9.12.0",
28
+ "eslint-plugin-vue": "^9.15.1",
30
29
  "husky": "^8.0.3",
31
30
  "standard-version": "^9.5.0",
32
31
  "ts-node": "^10.9.1",
33
- "turbo": "^1.9.5",
34
- "typescript": "^5.0.4",
32
+ "turbo": "1.10.6",
33
+ "typescript": "~5.0.4",
35
34
  "uglify-js": "^3.17.4",
36
- "vite": "^4.3.6",
37
- "vitest": "^0.31.0",
35
+ "vite": "^4.3.9",
36
+ "vitest": "^0.32.4",
38
37
  "zx": "^7.2.2"
39
38
  },
40
39
  "scripts": {
@@ -43,6 +42,7 @@
43
42
  "new-pkg": "bash scripts/new-package.sh",
44
43
  "build": "turbo run build --filter='!./ecomplus-stores/**'",
45
44
  "test": "turbo run test --filter='!./ecomplus-stores/**'",
45
+ "test:apps": "turbo run test --filter='./packages/{apps/**,modules}'",
46
46
  "test:e2e": "turbo run test:e2e --filter='./packages/**'",
47
47
  "release": "bash scripts/version-and-release.sh",
48
48
  "store:run": "pnpm build && npm --prefix \"store\" run",
@@ -1,5 +1,6 @@
1
- import type { Endpoint, Config, ResponseBody, RequestBody, ErrorBody } from './types';
1
+ import type { Endpoint, Config, ResponseBody, RequestBody, ErrorBody } from '../types.d';
2
2
  declare global {
3
+ var $apiMergeConfig: Partial<Config> | undefined;
3
4
  var __apiCache: Record<string, {
4
5
  timestamp: number;
5
6
  res: Response & {
@@ -19,25 +20,25 @@ declare class ApiError extends Error {
19
20
  }
20
21
  declare const def: {
21
22
  middleware(config: Config): {
22
- url: string;
23
+ url: any;
23
24
  headers: Headers | Record<string, string>;
24
25
  };
25
26
  };
26
27
  declare const setMiddleware: (middleware: (config: Config) => {
27
- url: string;
28
+ url: any;
28
29
  headers: Headers | Record<string, string>;
29
30
  }) => void;
30
31
  declare const api: {
31
32
  <T extends Config & {
32
33
  body?: any;
33
34
  data?: any;
34
- }>(config: T, retries?: number): Promise<Response & {
35
+ }>(requestConfig: T, _retries?: number): Promise<Response & {
35
36
  config: Config;
36
37
  data: ResponseBody<T>;
37
38
  }>;
38
39
  get: <E extends Endpoint, C extends AbstractedConfig>(endpoint: E, config?: C | undefined) => Promise<Response & {
39
40
  config: Config;
40
- data: ResponseBody<{
41
+ data: ResponseBody<C & {
41
42
  endpoint: E;
42
43
  }>;
43
44
  }>;
@@ -47,7 +48,7 @@ declare const api: {
47
48
  }>, config?: (E extends "login" | "authenticate" ? AbstractedConfig : C) | undefined) => Promise<Response & {
48
49
  config: Config;
49
50
  data: E extends "login" ? {
50
- _id: import("./types").ResourceId;
51
+ _id: import("../types.d").ResourceId;
51
52
  store_ids: number[];
52
53
  api_key: string;
53
54
  } : E extends "authenticate" ? {
@@ -55,10 +56,10 @@ declare const api: {
55
56
  access_token: string;
56
57
  expires: string;
57
58
  } : {
58
- _id: import("./types").ResourceId;
59
+ _id: import("../types.d").ResourceId;
59
60
  };
60
61
  }>;
61
- put: <E_1 extends `products/${string}` | `categories/${string}` | `brands/${string}` | `collections/${string}` | `grids/${string}` | `carts/${string}` | `orders/${string}` | `customers/${string}` | `stores/${string}` | `applications/${string}` | `authentications/${string}` | ("events/products" | "events/categories" | "events/brands" | "events/collections" | "events/grids" | "events/carts" | "events/orders" | "events/customers" | "events/stores" | "events/applications" | "events/authentications" | `events/products/${string}` | `events/categories/${string}` | `events/brands/${string}` | `events/collections/${string}` | `events/grids/${string}` | `events/carts/${string}` | `events/orders/${string}` | `events/customers/${string}` | `events/stores/${string}` | `events/applications/${string}` | `events/authentications/${string}` | "events/me") | `products/${string}/${string}` | `categories/${string}/${string}` | `brands/${string}/${string}` | `collections/${string}/${string}` | `grids/${string}/${string}` | `carts/${string}/${string}` | `orders/${string}/${string}` | `customers/${string}/${string}` | `stores/${string}/${string}` | `applications/${string}/${string}` | `authentications/${string}/${string}` | `slugs/${string}` | "$aggregate/products" | "$aggregate/categories" | "$aggregate/brands" | "$aggregate/collections" | "$aggregate/grids" | "$aggregate/carts" | "$aggregate/orders" | "$aggregate/customers" | "schemas/products" | "schemas/categories" | "schemas/brands" | "schemas/collections" | "schemas/grids" | "schemas/carts" | "schemas/orders" | "schemas/customers" | "schemas/stores" | "schemas/applications" | "schemas/authentications" | "search/v1" | "login" | "authenticate" | "ask-auth-callback" | "check-username", C_1 extends AbstractedConfig>(endpoint: E_1, body: RequestBody<{
62
+ put: <E_1 extends import("../types.d").ResourceAndFind | `products/${string}/${string}` | `categories/${string}/${string}` | `brands/${string}/${string}` | `collections/${string}/${string}` | `grids/${string}/${string}` | `carts/${string}/${string}` | `orders/${string}/${string}` | `customers/${string}/${string}` | `stores/${string}/${string}` | `applications/${string}/${string}` | `authentications/${string}/${string}` | `products/${string}:${string}/${string}` | `categories/${string}:${string}/${string}` | `brands/${string}:${string}/${string}` | `collections/${string}:${string}/${string}` | `grids/${string}:${string}/${string}` | `carts/${string}:${string}/${string}` | `orders/${string}:${string}/${string}` | `customers/${string}:${string}/${string}` | `stores/${string}:${string}/${string}` | `applications/${string}:${string}/${string}` | `authentications/${string}:${string}/${string}` | `slugs/${string}` | ("search/v1" | `search/v1?${string}` | "search/_els" | `search/_els?${string}`) | ("events/products" | "events/categories" | "events/brands" | "events/collections" | "events/grids" | "events/carts" | "events/orders" | "events/customers" | "events/stores" | "events/applications" | "events/authentications" | `events/products/${string}` | `events/categories/${string}` | `events/brands/${string}` | `events/collections/${string}` | `events/grids/${string}` | `events/carts/${string}` | `events/orders/${string}` | `events/customers/${string}` | `events/stores/${string}` | `events/applications/${string}` | `events/authentications/${string}` | "events/me") | "login" | "authenticate" | "ask-auth-callback" | "check-username" | "$aggregate/products" | "$aggregate/categories" | "$aggregate/brands" | "$aggregate/collections" | "$aggregate/grids" | "$aggregate/carts" | "$aggregate/orders" | "$aggregate/customers" | "schemas/products" | "schemas/categories" | "schemas/brands" | "schemas/collections" | "schemas/grids" | "schemas/carts" | "schemas/orders" | "schemas/customers" | "schemas/stores" | "schemas/applications" | "schemas/authentications", C_1 extends AbstractedConfig>(endpoint: E_1, body: RequestBody<{
62
63
  endpoint: E_1;
63
64
  method: 'put';
64
65
  }>, config?: C_1 | undefined) => Promise<Response & {
@@ -81,7 +82,7 @@ declare const api: {
81
82
  type AbstractedConfig = Omit<Config, 'endpoint' | 'method'>;
82
83
  declare const get: <E extends Endpoint, C extends AbstractedConfig>(endpoint: E, config?: C | undefined) => Promise<Response & {
83
84
  config: Config;
84
- data: ResponseBody<{
85
+ data: ResponseBody<C & {
85
86
  endpoint: E;
86
87
  }>;
87
88
  }>;
@@ -91,7 +92,7 @@ declare const post: <E extends Endpoint, C extends AbstractedConfig>(endpoint: E
91
92
  }>, config?: (E extends "login" | "authenticate" ? AbstractedConfig : C) | undefined) => Promise<Response & {
92
93
  config: Config;
93
94
  data: E extends "login" ? {
94
- _id: import("./types").ResourceId;
95
+ _id: import("../types.d").ResourceId;
95
96
  store_ids: number[];
96
97
  api_key: string;
97
98
  } : E extends "authenticate" ? {
@@ -99,10 +100,10 @@ declare const post: <E extends Endpoint, C extends AbstractedConfig>(endpoint: E
99
100
  access_token: string;
100
101
  expires: string;
101
102
  } : {
102
- _id: import("./types").ResourceId;
103
+ _id: import("../types.d").ResourceId;
103
104
  };
104
105
  }>;
105
- declare const put: <E extends `products/${string}` | `categories/${string}` | `brands/${string}` | `collections/${string}` | `grids/${string}` | `carts/${string}` | `orders/${string}` | `customers/${string}` | `stores/${string}` | `applications/${string}` | `authentications/${string}` | ("events/products" | "events/categories" | "events/brands" | "events/collections" | "events/grids" | "events/carts" | "events/orders" | "events/customers" | "events/stores" | "events/applications" | "events/authentications" | `events/products/${string}` | `events/categories/${string}` | `events/brands/${string}` | `events/collections/${string}` | `events/grids/${string}` | `events/carts/${string}` | `events/orders/${string}` | `events/customers/${string}` | `events/stores/${string}` | `events/applications/${string}` | `events/authentications/${string}` | "events/me") | `products/${string}/${string}` | `categories/${string}/${string}` | `brands/${string}/${string}` | `collections/${string}/${string}` | `grids/${string}/${string}` | `carts/${string}/${string}` | `orders/${string}/${string}` | `customers/${string}/${string}` | `stores/${string}/${string}` | `applications/${string}/${string}` | `authentications/${string}/${string}` | `slugs/${string}` | "$aggregate/products" | "$aggregate/categories" | "$aggregate/brands" | "$aggregate/collections" | "$aggregate/grids" | "$aggregate/carts" | "$aggregate/orders" | "$aggregate/customers" | "schemas/products" | "schemas/categories" | "schemas/brands" | "schemas/collections" | "schemas/grids" | "schemas/carts" | "schemas/orders" | "schemas/customers" | "schemas/stores" | "schemas/applications" | "schemas/authentications" | "search/v1" | "login" | "authenticate" | "ask-auth-callback" | "check-username", C extends AbstractedConfig>(endpoint: E, body: RequestBody<{
106
+ declare const put: <E extends import("../types.d").ResourceAndFind | `products/${string}/${string}` | `categories/${string}/${string}` | `brands/${string}/${string}` | `collections/${string}/${string}` | `grids/${string}/${string}` | `carts/${string}/${string}` | `orders/${string}/${string}` | `customers/${string}/${string}` | `stores/${string}/${string}` | `applications/${string}/${string}` | `authentications/${string}/${string}` | `products/${string}:${string}/${string}` | `categories/${string}:${string}/${string}` | `brands/${string}:${string}/${string}` | `collections/${string}:${string}/${string}` | `grids/${string}:${string}/${string}` | `carts/${string}:${string}/${string}` | `orders/${string}:${string}/${string}` | `customers/${string}:${string}/${string}` | `stores/${string}:${string}/${string}` | `applications/${string}:${string}/${string}` | `authentications/${string}:${string}/${string}` | `slugs/${string}` | ("search/v1" | `search/v1?${string}` | "search/_els" | `search/_els?${string}`) | ("events/products" | "events/categories" | "events/brands" | "events/collections" | "events/grids" | "events/carts" | "events/orders" | "events/customers" | "events/stores" | "events/applications" | "events/authentications" | `events/products/${string}` | `events/categories/${string}` | `events/brands/${string}` | `events/collections/${string}` | `events/grids/${string}` | `events/carts/${string}` | `events/orders/${string}` | `events/customers/${string}` | `events/stores/${string}` | `events/applications/${string}` | `events/authentications/${string}` | "events/me") | "login" | "authenticate" | "ask-auth-callback" | "check-username" | "$aggregate/products" | "$aggregate/categories" | "$aggregate/brands" | "$aggregate/collections" | "$aggregate/grids" | "$aggregate/carts" | "$aggregate/orders" | "$aggregate/customers" | "schemas/products" | "schemas/categories" | "schemas/brands" | "schemas/collections" | "schemas/grids" | "schemas/carts" | "schemas/orders" | "schemas/customers" | "schemas/stores" | "schemas/applications" | "schemas/authentications", C extends AbstractedConfig>(endpoint: E, body: RequestBody<{
106
107
  endpoint: E;
107
108
  method: 'put';
108
109
  }>, config?: C | undefined) => Promise<Response & {