cloudcommerce 0.26.7 → 0.28.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.
- package/.github/workflows/test-apps.yml +2 -2
- package/.gitmodules +0 -3
- package/.vscode/settings.json +3 -1
- package/CHANGELOG.md +51 -0
- package/action.yml +2 -2
- package/ecomplus-stores/barra-doce/functions/many/package.json +3 -3
- package/ecomplus-stores/barra-doce/functions/ssr/content/layout.json +13 -13
- package/ecomplus-stores/barra-doce/functions/ssr/content/pages/home.json +10 -10
- package/ecomplus-stores/barra-doce/functions/ssr/content/pages/products.json +17 -0
- package/ecomplus-stores/barra-doce/functions/ssr/content/settings.json +8 -8
- package/ecomplus-stores/barra-doce/functions/ssr/package.json +6 -6
- package/ecomplus-stores/barra-doce/functions/ssr/src/components/AccountMenu.vue +11 -11
- package/ecomplus-stores/barra-doce/functions/ssr/src/components/ShopFooter.vue +24 -24
- package/ecomplus-stores/barra-doce/functions/ssr/src/layouts/PageFooter.astro +4 -4
- package/ecomplus-stores/barra-doce/functions/with-apps/package.json +3 -3
- package/ecomplus-stores/barra-doce/package.json +2 -2
- package/ecomplus-stores/monocard/functions/many/package.json +3 -3
- package/ecomplus-stores/monocard/functions/ssr/content/layout.json +11 -11
- package/ecomplus-stores/monocard/functions/ssr/content/pages/home.json +16 -16
- package/ecomplus-stores/monocard/functions/ssr/content/pages/products.json +2 -4
- package/ecomplus-stores/monocard/functions/ssr/content/settings.json +11 -11
- package/ecomplus-stores/monocard/functions/ssr/package.json +6 -6
- package/ecomplus-stores/monocard/functions/ssr/src/components/AccountMenu.vue +1 -1
- package/ecomplus-stores/monocard/functions/ssr/src/components/DocDescription.vue +33 -0
- package/ecomplus-stores/monocard/functions/ssr/src/components/FeatureTabs.vue +3 -3
- package/ecomplus-stores/monocard/functions/ssr/src/components/ShopFooter.vue +3 -3
- package/ecomplus-stores/monocard/functions/ssr/src/components/ShopHeader.vue +5 -13
- package/ecomplus-stores/monocard/functions/ssr/src/layouts/PageFooter.astro +2 -2
- package/ecomplus-stores/monocard/functions/ssr/src/main/Home.astro +1 -1
- package/ecomplus-stores/monocard/functions/ssr/src/main/Sections.astro +1 -1
- package/ecomplus-stores/monocard/functions/with-apps/package.json +3 -3
- package/ecomplus-stores/monocard/package.json +2 -2
- package/package.json +6 -6
- package/packages/api/package.json +1 -1
- package/packages/apps/affilate-program/package.json +2 -2
- package/packages/apps/correios/package.json +3 -4
- package/packages/apps/custom-payment/package.json +1 -1
- package/packages/apps/custom-shipping/package.json +1 -1
- package/packages/apps/datafrete/package.json +3 -3
- package/packages/apps/discounts/package.json +1 -1
- package/packages/apps/emails/lib/functios-lib/utils.js +1 -1
- package/packages/apps/emails/lib/functios-lib/utils.js.map +1 -1
- package/packages/apps/emails/package.json +2 -2
- package/packages/apps/emails/src/functios-lib/utils.ts +1 -1
- package/packages/apps/fb-conversions/package.json +3 -3
- package/packages/apps/flash-courier/package.json +2 -2
- package/packages/apps/frenet/package.json +3 -3
- package/packages/apps/galaxpay/package.json +3 -3
- package/packages/apps/google-analytics/package.json +3 -3
- package/packages/apps/jadlog/package.json +2 -2
- package/packages/apps/loyalty-points/lib/functions-lib/cron-add-points.d.ts +2 -0
- package/packages/apps/loyalty-points/lib/functions-lib/cron-add-points.js +98 -0
- package/packages/apps/loyalty-points/lib/functions-lib/cron-add-points.js.map +1 -0
- package/packages/apps/loyalty-points/lib/functions-lib/handle-loyalty-points-event.js +59 -23
- package/packages/apps/loyalty-points/lib/functions-lib/handle-loyalty-points-event.js.map +1 -1
- package/packages/apps/loyalty-points/lib/loyalty-create-transaction.js +9 -4
- package/packages/apps/loyalty-points/lib/loyalty-create-transaction.js.map +1 -1
- package/packages/apps/loyalty-points/lib/loyalty-list-payments.js +7 -2
- package/packages/apps/loyalty-points/lib/loyalty-list-payments.js.map +1 -1
- package/packages/apps/loyalty-points/lib/loyalty-points-events.d.ts +3 -1
- package/packages/apps/loyalty-points/lib/loyalty-points-events.js +9 -0
- package/packages/apps/loyalty-points/lib/loyalty-points-events.js.map +1 -1
- package/packages/apps/loyalty-points/package.json +3 -2
- package/packages/apps/loyalty-points/src/functions-lib/cron-add-points.ts +104 -0
- package/packages/apps/loyalty-points/src/functions-lib/handle-loyalty-points-event.ts +67 -25
- package/packages/apps/loyalty-points/src/loyalty-create-transaction.ts +11 -4
- package/packages/apps/loyalty-points/src/loyalty-list-payments.ts +9 -2
- package/packages/apps/loyalty-points/src/loyalty-points-events.ts +12 -1
- package/packages/apps/melhor-envio/package.json +3 -3
- package/packages/apps/mercadopago/assets/onload-expression.js +5 -1
- package/packages/apps/mercadopago/assets/onload-expression.min.js +1 -1
- package/packages/apps/mercadopago/lib/mp-create-transaction.js +16 -6
- package/packages/apps/mercadopago/lib/mp-create-transaction.js.map +1 -1
- package/packages/apps/mercadopago/package.json +3 -3
- package/packages/apps/mercadopago/src/mp-create-transaction.ts +19 -7
- package/packages/apps/pagarme/package.json +3 -3
- package/packages/apps/paghiper/package.json +3 -3
- package/packages/apps/pix/package.json +3 -3
- package/packages/apps/tiny-erp/lib/integration/export-order-to-tiny.js +22 -0
- package/packages/apps/tiny-erp/lib/integration/export-order-to-tiny.js.map +1 -1
- package/packages/apps/tiny-erp/lib/integration/helpers/format-tiny-date.js +2 -2
- package/packages/apps/tiny-erp/lib/integration/helpers/format-tiny-date.js.map +1 -1
- package/packages/apps/tiny-erp/lib/integration/import-order-from-tiny.js +7 -1
- package/packages/apps/tiny-erp/lib/integration/import-order-from-tiny.js.map +1 -1
- package/packages/apps/tiny-erp/lib/integration/import-product-from-tiny.js +14 -5
- package/packages/apps/tiny-erp/lib/integration/import-product-from-tiny.js.map +1 -1
- package/packages/apps/tiny-erp/lib/integration/parsers/order-from-tiny.js +9 -1
- package/packages/apps/tiny-erp/lib/integration/parsers/order-from-tiny.js.map +1 -1
- package/packages/apps/tiny-erp/lib/integration/parsers/order-to-tiny.js +8 -6
- package/packages/apps/tiny-erp/lib/integration/parsers/order-to-tiny.js.map +1 -1
- package/packages/apps/tiny-erp/lib/integration/parsers/product-from-tiny.js +118 -38
- package/packages/apps/tiny-erp/lib/integration/parsers/product-from-tiny.js.map +1 -1
- package/packages/apps/tiny-erp/lib/integration/parsers/product-to-tiny.js +8 -0
- package/packages/apps/tiny-erp/lib/integration/parsers/product-to-tiny.js.map +1 -1
- package/packages/apps/tiny-erp/package.json +3 -3
- package/packages/apps/tiny-erp/src/integration/export-order-to-tiny.ts +24 -0
- package/packages/apps/tiny-erp/src/integration/helpers/format-tiny-date.ts +2 -2
- package/packages/apps/tiny-erp/src/integration/import-order-from-tiny.ts +8 -1
- package/packages/apps/tiny-erp/src/integration/import-product-from-tiny.ts +17 -5
- package/packages/apps/tiny-erp/src/integration/parsers/order-from-tiny.ts +13 -1
- package/packages/apps/tiny-erp/src/integration/parsers/order-to-tiny.ts +11 -6
- package/packages/apps/tiny-erp/src/integration/parsers/product-from-tiny.ts +144 -41
- package/packages/apps/tiny-erp/src/integration/parsers/product-to-tiny.ts +10 -0
- package/packages/apps/webhooks/package.json +3 -3
- package/packages/cli/package.json +1 -1
- package/packages/config/lib/config.js +2 -2
- package/packages/config/lib/config.js.map +1 -1
- package/packages/config/package.json +1 -1
- package/packages/config/src/config.ts +2 -2
- package/packages/emails/package.json +4 -4
- package/packages/eslint/base.eslintrc.cjs +3 -0
- package/packages/eslint/package.json +5 -4
- package/packages/eslint/storefront.eslintrc.cjs +8 -1
- package/packages/events/package.json +2 -2
- package/packages/feeds/package.json +1 -1
- package/packages/firebase/package.json +2 -2
- package/packages/i18n/package.json +1 -1
- package/packages/modules/package.json +3 -3
- package/packages/passport/package.json +2 -2
- package/packages/ssr/package.json +3 -3
- package/packages/storefront/.auto-imports.d.ts +65 -0
- package/packages/storefront/astro.config.mjs +24 -1
- package/packages/storefront/client.d.ts +1 -0
- package/packages/storefront/config/astro/context-directive.mjs +21 -0
- package/packages/storefront/config/astro/index.d.ts +8 -0
- package/packages/storefront/config/storefront.cms.js +2 -2
- package/packages/storefront/config/storefront.tailwind.cjs +0 -1
- package/packages/storefront/package.json +4 -3
- package/packages/storefront/server.d.ts +1 -1
- package/packages/storefront/src/lib/$storefront.d.ts +8 -8
- package/packages/storefront/src/lib/assets/base.css +5 -0
- package/packages/storefront/src/lib/components/Carousel.vue +93 -72
- package/packages/storefront/src/lib/components/CarouselControl.vue +13 -7
- package/packages/storefront/src/lib/components/ContentClearfix.vue +17 -0
- package/packages/storefront/src/lib/components/Drawer.vue +2 -2
- package/packages/storefront/src/lib/components/PaymentMethodFlag.vue +2 -2
- package/packages/storefront/src/lib/components/QuantitySelector.vue +4 -4
- package/packages/storefront/src/lib/components/QuantitySelectorControl.vue +2 -2
- package/packages/storefront/src/lib/components/ViewTransitions.astro +409 -0
- package/packages/storefront/src/lib/components/globals/AImg.vue +2 -1
- package/packages/storefront/src/lib/composables/use-pitch-bar.ts +2 -2
- package/packages/storefront/src/lib/content.d.ts +5 -5
- package/packages/storefront/src/lib/layouts/Base.astro +4 -4
- package/packages/storefront/src/lib/layouts/BaseBody.astro +0 -2
- package/packages/storefront/src/lib/layouts/BaseHead.astro +32 -14
- package/packages/storefront/src/lib/layouts/use-page-header.ts +9 -4
- package/packages/storefront/src/lib/layouts/use-page-main.ts +13 -33
- package/packages/test-base/package.json +1 -1
- package/packages/types/index.ts +14 -14
- package/packages/types/package.json +1 -1
- package/ecomplus-stores/iluminim/.devcontainer/devcontainer.json +0 -30
- package/ecomplus-stores/iluminim/.editorconfig +0 -13
- package/ecomplus-stores/iluminim/.eslintrc.cjs +0 -3
- package/ecomplus-stores/iluminim/.firebaserc +0 -5
- package/ecomplus-stores/iluminim/.github/renovate.json +0 -5
- package/ecomplus-stores/iluminim/.github/workflows/build-and-deploy.yml +0 -36
- package/ecomplus-stores/iluminim/.github/workflows/calibreapp-image-actions.yml +0 -23
- package/ecomplus-stores/iluminim/.gitpod.yml +0 -12
- package/ecomplus-stores/iluminim/.idx/dev.nix +0 -24
- package/ecomplus-stores/iluminim/.nvmrc +0 -1
- package/ecomplus-stores/iluminim/.vscode/extensions.json +0 -8
- package/ecomplus-stores/iluminim/.vscode/launch.json +0 -11
- package/ecomplus-stores/iluminim/.vscode/settings.json +0 -10
- package/ecomplus-stores/iluminim/README.md +0 -31
- package/ecomplus-stores/iluminim/SETUP.md +0 -117
- package/ecomplus-stores/iluminim/SETUP.pt-BR.md +0 -117
- package/ecomplus-stores/iluminim/functions/config.json +0 -3
- package/ecomplus-stores/iluminim/functions/example.env +0 -10
- package/ecomplus-stores/iluminim/functions/many/index.js +0 -14
- package/ecomplus-stores/iluminim/functions/many/package.json +0 -22
- package/ecomplus-stores/iluminim/functions/ssr/.eslintrc.cjs +0 -6
- package/ecomplus-stores/iluminim/functions/ssr/astro.config.mjs +0 -4
- package/ecomplus-stores/iluminim/functions/ssr/content/blog/.gitkeep +0 -0
- package/ecomplus-stores/iluminim/functions/ssr/content/extra-pages/contato.json +0 -11
- package/ecomplus-stores/iluminim/functions/ssr/content/extra-pages/terms.json +0 -11
- package/ecomplus-stores/iluminim/functions/ssr/content/extra-pages/trocas.json +0 -11
- package/ecomplus-stores/iluminim/functions/ssr/content/layout.json +0 -57
- package/ecomplus-stores/iluminim/functions/ssr/content/pages/home.json +0 -70
- package/ecomplus-stores/iluminim/functions/ssr/content/settings.json +0 -65
- package/ecomplus-stores/iluminim/functions/ssr/index.js +0 -18
- package/ecomplus-stores/iluminim/functions/ssr/package.json +0 -31
- package/ecomplus-stores/iluminim/functions/ssr/public/admin/.gitkeep +0 -2
- package/ecomplus-stores/iluminim/functions/ssr/public/assets/cms-preview.css +0 -274
- package/ecomplus-stores/iluminim/functions/ssr/public/assets/cms.css +0 -114
- package/ecomplus-stores/iluminim/functions/ssr/public/assets/cvv.png +0 -0
- package/ecomplus-stores/iluminim/functions/ssr/public/assets/img-placeholder.png +0 -0
- package/ecomplus-stores/iluminim/functions/ssr/public/assets/payments.png +0 -0
- package/ecomplus-stores/iluminim/functions/ssr/public/assets/ssl-safe.png +0 -0
- package/ecomplus-stores/iluminim/functions/ssr/public/img/icon.png +0 -0
- package/ecomplus-stores/iluminim/functions/ssr/public/img/large-icon.png +0 -0
- package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/banner-chamada-desktop-9x81zmd91q.webp +0 -0
- package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/banner2.webp +0 -0
- package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/chamada-mobile-q1c6om6jx4.webp +0 -0
- package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/ecom-icon.png +0 -0
- package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/headphone.webp +0 -0
- package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/logo.webp +0 -0
- package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/og-image.png +0 -0
- package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/passion.webp +0 -0
- package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/rect8589.png +0 -0
- package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/rect859.png +0 -0
- package/ecomplus-stores/iluminim/functions/ssr/public/img/uploads/rect89.webp +0 -0
- package/ecomplus-stores/iluminim/functions/ssr/public/robots.txt +0 -6
- package/ecomplus-stores/iluminim/functions/ssr/scripts/build.sh +0 -14
- package/ecomplus-stores/iluminim/functions/ssr/src/assets/style.css +0 -65
- package/ecomplus-stores/iluminim/functions/ssr/src/components/AccountMenu.vue +0 -95
- package/ecomplus-stores/iluminim/functions/ssr/src/components/Banner.vue +0 -57
- package/ecomplus-stores/iluminim/functions/ssr/src/components/BannersGrid.astro +0 -25
- package/ecomplus-stores/iluminim/functions/ssr/src/components/CartItem.vue +0 -64
- package/ecomplus-stores/iluminim/functions/ssr/src/components/CartSidebar.vue +0 -66
- package/ecomplus-stores/iluminim/functions/ssr/src/components/Countdown.vue +0 -79
- package/ecomplus-stores/iluminim/functions/ssr/src/components/HeroSlider.vue +0 -52
- package/ecomplus-stores/iluminim/functions/ssr/src/components/PitchBar.vue +0 -56
- package/ecomplus-stores/iluminim/functions/ssr/src/components/Prices.vue +0 -95
- package/ecomplus-stores/iluminim/functions/ssr/src/components/ProductCard.vue +0 -117
- package/ecomplus-stores/iluminim/functions/ssr/src/components/ProductShelf.vue +0 -57
- package/ecomplus-stores/iluminim/functions/ssr/src/components/ProductsCountdown.vue +0 -20
- package/ecomplus-stores/iluminim/functions/ssr/src/components/SearchModal.vue +0 -6
- package/ecomplus-stores/iluminim/functions/ssr/src/components/ShopFooter.vue +0 -149
- package/ecomplus-stores/iluminim/functions/ssr/src/components/ShopHeader.vue +0 -158
- package/ecomplus-stores/iluminim/functions/ssr/src/components/ShopHeaderMenu.vue +0 -58
- package/ecomplus-stores/iluminim/functions/ssr/src/components/ShopHeaderSubmenu.vue +0 -88
- package/ecomplus-stores/iluminim/functions/ssr/src/components/ShopSidenav.vue +0 -61
- package/ecomplus-stores/iluminim/functions/ssr/src/components/ShopSidenavCategory.vue +0 -80
- package/ecomplus-stores/iluminim/functions/ssr/src/env.d.ts +0 -13
- package/ecomplus-stores/iluminim/functions/ssr/src/layouts/Base.astro +0 -16
- package/ecomplus-stores/iluminim/functions/ssr/src/layouts/Checkout.astro +0 -0
- package/ecomplus-stores/iluminim/functions/ssr/src/layouts/PageFooter.astro +0 -68
- package/ecomplus-stores/iluminim/functions/ssr/src/layouts/PageHeader.astro +0 -42
- package/ecomplus-stores/iluminim/functions/ssr/src/main/Fallback.astro +0 -10
- package/ecomplus-stores/iluminim/functions/ssr/src/main/Home.astro +0 -49
- package/ecomplus-stores/iluminim/functions/ssr/src/main/Sections.astro +0 -42
- package/ecomplus-stores/iluminim/functions/ssr/src/main/Wildcard.astro +0 -18
- package/ecomplus-stores/iluminim/functions/ssr/src/pages/[...slug].astro +0 -40
- package/ecomplus-stores/iluminim/functions/ssr/src/pages/_vue.ts +0 -3
- package/ecomplus-stores/iluminim/functions/ssr/src/pages/app/account.astro +0 -0
- package/ecomplus-stores/iluminim/functions/ssr/src/pages/app/index.astro +0 -0
- package/ecomplus-stores/iluminim/functions/ssr/src/pages/index.astro +0 -37
- package/ecomplus-stores/iluminim/functions/ssr/src/pages/~fallback.astro +0 -25
- package/ecomplus-stores/iluminim/functions/ssr/src/scripts/InlineScripts.astro +0 -10
- package/ecomplus-stores/iluminim/functions/ssr/tailwind.config.cjs +0 -13
- package/ecomplus-stores/iluminim/functions/ssr/tsconfig.json +0 -12
- package/ecomplus-stores/iluminim/functions/ssr/uno.config.cjs +0 -5
- package/ecomplus-stores/iluminim/functions/with-apps/index.js +0 -12
- package/ecomplus-stores/iluminim/functions/with-apps/package.json +0 -22
- package/ecomplus-stores/iluminim/package.json +0 -31
- package/ecomplus-stores/iluminim/scripts/install.sh +0 -24
- package/ecomplus-stores/monocard/functions/ssr/src/components/DocDescription.astro +0 -30
- package/packages/storefront/src/lib/components/ContentClearfix.astro +0 -15
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { Products } from '@cloudcommerce/types';
|
|
1
|
+
import type { Products, ProductSet } from '@cloudcommerce/types';
|
|
2
2
|
import logger from 'firebase-functions/logger';
|
|
3
3
|
import axios from 'axios';
|
|
4
4
|
import FormData from 'form-data';
|
|
@@ -12,7 +12,11 @@ const removeAccents = (str: string) => str.replace(/áàãâÁÀÃÂ/g, 'a')
|
|
|
12
12
|
.replace(/úÚ/g, 'u')
|
|
13
13
|
.replace(/çÇ/g, 'c');
|
|
14
14
|
|
|
15
|
-
const tryImageUpload = (
|
|
15
|
+
const tryImageUpload = (
|
|
16
|
+
originImgUrl: string,
|
|
17
|
+
product: Products,
|
|
18
|
+
index?: number,
|
|
19
|
+
) => new Promise((resolve) => {
|
|
16
20
|
const {
|
|
17
21
|
storeId,
|
|
18
22
|
apiAuth: {
|
|
@@ -72,26 +76,55 @@ const tryImageUpload = (originImgUrl: string, product: Products) => new Promise(
|
|
|
72
76
|
});
|
|
73
77
|
}).then((picture) => {
|
|
74
78
|
if (product && product.pictures) {
|
|
75
|
-
|
|
76
|
-
|
|
79
|
+
if (index === 0 || index) {
|
|
80
|
+
// @ts-ignore
|
|
81
|
+
product.pictures[index] = picture;
|
|
82
|
+
} else {
|
|
83
|
+
// @ts-ignore
|
|
84
|
+
product.pictures.push(picture);
|
|
85
|
+
}
|
|
77
86
|
}
|
|
78
87
|
return picture;
|
|
79
88
|
});
|
|
80
89
|
|
|
81
|
-
export default (
|
|
90
|
+
export default (
|
|
91
|
+
tinyProduct,
|
|
92
|
+
tipo?:string,
|
|
93
|
+
isNew = true,
|
|
94
|
+
): Promise<ProductSet> => new Promise((resolve) => {
|
|
82
95
|
const sku = tinyProduct.codigo || String(tinyProduct.id);
|
|
83
96
|
const name = (tinyProduct.nome || sku).trim();
|
|
84
|
-
const
|
|
97
|
+
const isProduct = tipo === 'produto';
|
|
98
|
+
const getCorrectPrice = (price) => {
|
|
99
|
+
return Number(price) > 0 ? Number(price) : null;
|
|
100
|
+
};
|
|
101
|
+
const product: ProductSet = {
|
|
85
102
|
available: tinyProduct.situacao === 'A',
|
|
86
103
|
sku,
|
|
87
104
|
name,
|
|
88
|
-
cost_price: tinyProduct.preco_custo,
|
|
89
|
-
price: tinyProduct.preco_promocional || tinyProduct.preco
|
|
90
|
-
|
|
91
|
-
|
|
105
|
+
cost_price: !isProduct ? Number(tinyProduct.preco_custo) : Number(tinyProduct.precoCusto),
|
|
106
|
+
price: !isProduct ? Number(tinyProduct.preco_promocional || tinyProduct.preco)
|
|
107
|
+
: Number(getCorrectPrice(tinyProduct.precoPromocional) || tinyProduct.preco),
|
|
108
|
+
base_price: Number(tinyProduct.preco),
|
|
109
|
+
body_html: tinyProduct.descricao_complementar || tinyProduct.descricaoComplementar,
|
|
92
110
|
};
|
|
93
111
|
|
|
94
112
|
if (isNew) {
|
|
113
|
+
if (tinyProduct.seo) {
|
|
114
|
+
if (tinyProduct.seo.slug && tinyProduct.seo.slug.length) {
|
|
115
|
+
product.slug = tinyProduct.seo.slug;
|
|
116
|
+
}
|
|
117
|
+
if (tinyProduct.seo.title && tinyProduct.seo.title.length) {
|
|
118
|
+
product.meta_title = tinyProduct.seo.title.slice(0, 254);
|
|
119
|
+
}
|
|
120
|
+
if (tinyProduct.seo.description && tinyProduct.seo.description.length) {
|
|
121
|
+
product.meta_description = tinyProduct.seo.description.slice(0, 999);
|
|
122
|
+
}
|
|
123
|
+
if (tinyProduct.seo.keywords && tinyProduct.seo.keywords.length) {
|
|
124
|
+
product.keywords = tinyProduct.seo.keywords.split(',');
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
|
|
95
128
|
product.slug = removeAccents(name.toLowerCase())
|
|
96
129
|
.replace(/\s+/g, '-')
|
|
97
130
|
.replace(/[^a-z0-9-_./]/g, '');
|
|
@@ -102,8 +135,9 @@ export default (tinyProduct, isNew = true) => new Promise((resolve) => {
|
|
|
102
135
|
if (tinyProduct.garantia) {
|
|
103
136
|
product.warranty = tinyProduct.garantia;
|
|
104
137
|
}
|
|
105
|
-
if (tinyProduct.unidade_por_caixa) {
|
|
106
|
-
product.min_quantity = Number(tinyProduct.unidade_por_caixa)
|
|
138
|
+
if (tinyProduct.unidade_por_caixa || tinyProduct.unidadePorCaixa) {
|
|
139
|
+
product.min_quantity = !isProduct ? Number(tinyProduct.unidade_por_caixa)
|
|
140
|
+
: Number(tinyProduct.unidadePorCaixa);
|
|
107
141
|
}
|
|
108
142
|
if (tinyProduct.ncm) {
|
|
109
143
|
product.mpn = [tinyProduct.ncm];
|
|
@@ -113,12 +147,14 @@ export default (tinyProduct, isNew = true) => new Promise((resolve) => {
|
|
|
113
147
|
};
|
|
114
148
|
if (validateGtin(tinyProduct.gtin)) {
|
|
115
149
|
product.gtin = [tinyProduct.gtin];
|
|
116
|
-
if (validateGtin(tinyProduct.gtin_embalagem)) {
|
|
117
|
-
product.gtin.push(tinyProduct.gtin_embalagem);
|
|
150
|
+
if (validateGtin(tinyProduct.gtin_embalagem || tinyProduct.gtinEmbalagem)) {
|
|
151
|
+
product.gtin.push(tinyProduct.gtin_embalagem || tinyProduct.gtinEmbalagem);
|
|
118
152
|
}
|
|
119
153
|
}
|
|
120
154
|
|
|
121
|
-
const weight = tinyProduct.peso_bruto || tinyProduct.peso_liquido
|
|
155
|
+
const weight = !isProduct ? (tinyProduct.peso_bruto || tinyProduct.peso_liquido)
|
|
156
|
+
: (tinyProduct.pesoBruto || tinyProduct.pesoLiquido);
|
|
157
|
+
|
|
122
158
|
if (weight > 0) {
|
|
123
159
|
product.weight = {
|
|
124
160
|
unit: 'kg',
|
|
@@ -145,38 +181,84 @@ export default (tinyProduct, isNew = true) => new Promise((resolve) => {
|
|
|
145
181
|
if (isNew) {
|
|
146
182
|
if (Array.isArray(tinyProduct.variacoes) && tinyProduct.variacoes.length) {
|
|
147
183
|
product.variations = [];
|
|
148
|
-
tinyProduct.variacoes.forEach(({
|
|
149
|
-
const
|
|
184
|
+
tinyProduct.variacoes.forEach(({ variacaoObj }) => {
|
|
185
|
+
const variacao = !isProduct ? variacaoObj.variacao : variacaoObj;
|
|
186
|
+
const {
|
|
187
|
+
codigo,
|
|
188
|
+
preco,
|
|
189
|
+
grade,
|
|
190
|
+
estoqueAtual,
|
|
191
|
+
anexos,
|
|
192
|
+
} = variacao;
|
|
193
|
+
const gridIdFormat = (text) => {
|
|
194
|
+
return removeAccents(text.toLowerCase())
|
|
195
|
+
.replace(/\s+/g, '_')
|
|
196
|
+
.replace(/[^a-z0-9_]/g, '')
|
|
197
|
+
.substring(0, 30)
|
|
198
|
+
.padStart(2, 'i');
|
|
199
|
+
};
|
|
200
|
+
|
|
201
|
+
const specifications = {};
|
|
202
|
+
const specTexts: string[] = [];
|
|
203
|
+
|
|
150
204
|
if (grade && typeof grade === 'object') {
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
.replace(/\s+/g, '_')
|
|
157
|
-
.replace(/[^a-z0-9_]/g, '')
|
|
158
|
-
.substring(0, 30)
|
|
159
|
-
.padStart(2, 'i');
|
|
160
|
-
const spec: Record<string, string> = {
|
|
161
|
-
text: grade[tipo],
|
|
205
|
+
Object.keys(grade).forEach((tipoGrade) => {
|
|
206
|
+
if (grade[tipoGrade]) {
|
|
207
|
+
const gridId = gridIdFormat(tipoGrade);
|
|
208
|
+
const spec = {
|
|
209
|
+
text: grade[tipoGrade],
|
|
162
210
|
};
|
|
163
211
|
specTexts.push(spec.text);
|
|
164
212
|
if (gridId !== 'colors') {
|
|
165
|
-
|
|
213
|
+
Object.assign(
|
|
214
|
+
spec,
|
|
215
|
+
{
|
|
216
|
+
value: removeAccents(spec.text.toLowerCase()).substring(0, 100),
|
|
217
|
+
},
|
|
218
|
+
);
|
|
166
219
|
}
|
|
167
220
|
specifications[gridId] = [spec];
|
|
168
221
|
}
|
|
169
222
|
});
|
|
223
|
+
} else if (Array.isArray(grade)) {
|
|
224
|
+
grade.forEach((gd) => {
|
|
225
|
+
const gridId = gridIdFormat(gd.chave);
|
|
226
|
+
const spec = {
|
|
227
|
+
text: gd.valor,
|
|
228
|
+
};
|
|
229
|
+
specTexts.push(spec.text);
|
|
230
|
+
if (gridId !== 'colors') {
|
|
231
|
+
Object.assign(
|
|
232
|
+
spec,
|
|
233
|
+
{
|
|
234
|
+
value: removeAccents(spec.text.toLowerCase()).substring(0, 100),
|
|
235
|
+
},
|
|
236
|
+
);
|
|
237
|
+
}
|
|
238
|
+
specifications[gridId] = [spec];
|
|
239
|
+
});
|
|
240
|
+
}
|
|
241
|
+
let pictureId;
|
|
242
|
+
if (Array.isArray(anexos) && anexos.length
|
|
243
|
+
&& Array.isArray(tinyProduct.anexos) && tinyProduct.anexos.length) {
|
|
244
|
+
pictureId = tinyProduct.anexos.length;
|
|
245
|
+
anexos.forEach((anexo) => {
|
|
246
|
+
tinyProduct.anexos.push(anexo);
|
|
247
|
+
});
|
|
248
|
+
} else if (Array.isArray(tinyProduct.anexos) && tinyProduct.anexos.length) {
|
|
249
|
+
pictureId = 0;
|
|
250
|
+
}
|
|
170
251
|
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
252
|
+
if (specTexts.length) {
|
|
253
|
+
product.variations?.push({
|
|
254
|
+
_id: ecomUtils.randomObjectId(),
|
|
255
|
+
name: `${name} / ${specTexts.join(' / ')}`.substring(0, 100),
|
|
256
|
+
sku: codigo,
|
|
257
|
+
specifications,
|
|
258
|
+
price: parseFloat(preco || 0),
|
|
259
|
+
quantity: estoqueAtual || 0,
|
|
260
|
+
picture_id: pictureId,
|
|
261
|
+
});
|
|
180
262
|
}
|
|
181
263
|
});
|
|
182
264
|
}
|
|
@@ -201,12 +283,33 @@ export default (tinyProduct, isNew = true) => new Promise((resolve) => {
|
|
|
201
283
|
product.pictures = [];
|
|
202
284
|
}
|
|
203
285
|
const promises: Promise<any>[] = [];
|
|
204
|
-
tinyProduct.anexos.forEach((
|
|
205
|
-
|
|
286
|
+
tinyProduct.anexos.forEach((anexo) => {
|
|
287
|
+
let url;
|
|
288
|
+
if (anexo && anexo.anexo) {
|
|
289
|
+
url = anexo.anexo;
|
|
290
|
+
} else if (anexo.url) {
|
|
291
|
+
url = anexo.url;
|
|
292
|
+
}
|
|
293
|
+
|
|
294
|
+
if (typeof url === 'string' && url.startsWith('http')) {
|
|
206
295
|
promises.push(tryImageUpload(anexo, product as Products));
|
|
207
296
|
}
|
|
208
297
|
});
|
|
209
|
-
Promise.all(promises).then(() =>
|
|
298
|
+
Promise.all(promises).then((images) => {
|
|
299
|
+
if (Array.isArray(product.variations) && product.variations.length) {
|
|
300
|
+
product.variations.forEach((variation) => {
|
|
301
|
+
if (variation.picture_id) {
|
|
302
|
+
const variationImage = images[variation.picture_id];
|
|
303
|
+
if (variationImage._id) {
|
|
304
|
+
variation.picture_id = variationImage._id;
|
|
305
|
+
} else {
|
|
306
|
+
delete variation.picture_id;
|
|
307
|
+
}
|
|
308
|
+
}
|
|
309
|
+
});
|
|
310
|
+
}
|
|
311
|
+
return resolve(product);
|
|
312
|
+
});
|
|
210
313
|
return;
|
|
211
314
|
}
|
|
212
315
|
}
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import type { Products } from '@cloudcommerce/types';
|
|
2
|
+
import config from '@cloudcommerce/firebase/lib/config';
|
|
2
3
|
import ecomUtils from '@ecomplus/utils';
|
|
3
4
|
|
|
4
5
|
export default async (product: Products, originalTinyProduct, appData) => {
|
|
6
|
+
const { metafields } = config.get();
|
|
5
7
|
const hasVariations = product.variations && product.variations.length;
|
|
6
8
|
let unidade: string = originalTinyProduct?.unidade;
|
|
7
9
|
if (!unidade) {
|
|
@@ -60,10 +62,18 @@ export default async (product: Products, originalTinyProduct, appData) => {
|
|
|
60
62
|
|
|
61
63
|
if (product.weight && product.weight.value) {
|
|
62
64
|
tinyProduct.peso_bruto = product.weight.value;
|
|
65
|
+
tinyProduct.peso_liquido = product.weight.value;
|
|
66
|
+
|
|
67
|
+
if (metafields.tinyErpProductWeigthUnit) {
|
|
68
|
+
product.weight.unit = metafields.tinyErpProductWeigthUnit;
|
|
69
|
+
}
|
|
70
|
+
|
|
63
71
|
if (product.weight.unit === 'mg') {
|
|
64
72
|
tinyProduct.peso_bruto /= 1000000;
|
|
73
|
+
tinyProduct.peso_liquido /= 1000000;
|
|
65
74
|
} else if (product.weight.unit === 'g') {
|
|
66
75
|
tinyProduct.peso_bruto /= 1000;
|
|
76
|
+
tinyProduct.peso_liquido /= 1000;
|
|
67
77
|
}
|
|
68
78
|
}
|
|
69
79
|
const { dimensions } = product;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cloudcommerce/app-webhooks",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.28.0",
|
|
5
5
|
"description": "E-Com Plus Cloud Commerce app for general order webhooks",
|
|
6
6
|
"main": "lib/index.js",
|
|
7
7
|
"repository": {
|
|
@@ -21,8 +21,8 @@
|
|
|
21
21
|
"dependencies": {
|
|
22
22
|
"@cloudcommerce/api": "workspace:*",
|
|
23
23
|
"@cloudcommerce/firebase": "workspace:*",
|
|
24
|
-
"axios": "^1.5.
|
|
25
|
-
"firebase-admin": "^11.
|
|
24
|
+
"axios": "^1.5.1",
|
|
25
|
+
"firebase-admin": "^11.11.0",
|
|
26
26
|
"firebase-functions": "^4.4.1"
|
|
27
27
|
},
|
|
28
28
|
"devDependencies": {
|
|
@@ -31,8 +31,8 @@ export default {
|
|
|
31
31
|
if (settingsContent) {
|
|
32
32
|
config.lang = config.lang || settingsContent.lang;
|
|
33
33
|
config.currency = config.currency || settingsContent.currency;
|
|
34
|
-
config.currencySymbol = config.currencySymbol || settingsContent.
|
|
35
|
-
config.countryCode = config.currencySymbol || settingsContent.
|
|
34
|
+
config.currencySymbol = config.currencySymbol || settingsContent.currencySymbol;
|
|
35
|
+
config.countryCode = config.currencySymbol || settingsContent.countryCode;
|
|
36
36
|
}
|
|
37
37
|
self.config = deepmerge(self.config, config);
|
|
38
38
|
if (config.storeId) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.js","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AACA,OAAO,SAAS,MAAM,oBAAoB,CAAC;AAC3C,OAAO,EACL,YAAY,EACZ,gBAAgB,EAChB,uBAAuB,EACvB,oBAAoB,GACrB,MAAM,YAAY,CAAC;AAWpB,MAAM,IAAI,GAAG,CACX,CAAC,OAAO,OAAO,KAAK,QAAQ,IAAI,OAAO,EAAE,GAAG,CAAC;OAC1C,UAAU,CACS,CAAC;AAEzB,MAAM,SAAS,GAAG,SAAS,EAAE,CAAC;AAE9B,MAAM,IAAI,GAAG,UAAU,CAAC,eAAe,IAAI;IACzC,MAAM,EAAE,EAAE;CACX,CAAC;AACF,UAAU,CAAC,eAAe,GAAG,IAAI,CAAC;AAClC,IAAI,CAAC,SAAS,GAAG,IAAI,CAAC,SAAS,IAAI,YAAY,CAAC;AAChD,IAAI,CAAC,aAAa,GAAG,IAAI,CAAC,aAAa,IAAI,gBAAgB,CAAC;AAC5D,IAAI,CAAC,oBAAoB,GAAG,IAAI,CAAC,oBAAoB,IAAI,uBAAuB,CAAC;AACjF,IAAI,CAAC,iBAAiB,GAAG,IAAI,CAAC,iBAAiB,IAAI,oBAAoB,CAAC;AAExE,eAAe;IACb,GAAG;QACD,OAAO;YACL,IAAI,EAAE,IAAI,CAAC,SAAS;YACpB,QAAQ,EAAE,IAAI,CAAC,aAAa;YAC5B,cAAc,EAAE,IAAI,CAAC,oBAAoB;YACzC,WAAW,EAAE,IAAI,CAAC,iBAAiB;YACnC,OAAO,EAAE,MAAM,CAAC,IAAI,CAAC,aAAa,CAAC;YACnC,GAAG,IAAI,CAAC,MAAM;SACf,CAAC;IACJ,CAAC;IACD,GAAG,CAAC,MAA2B;QAC7B,MAAM,EAAE,eAAe,EAAE,GAAG,MAAM,CAAC;QACnC,IAAI,eAAe,EAAE;YACnB,MAAM,CAAC,IAAI,GAAG,MAAM,CAAC,IAAI,IAAI,eAAe,CAAC,IAAI,CAAC;YAClD,MAAM,CAAC,QAAQ,GAAG,MAAM,CAAC,QAAQ,IAAI,eAAe,CAAC,QAAQ,CAAC;YAC9D,MAAM,CAAC,cAAc,GAAG,MAAM,CAAC,cAAc,IAAI,eAAe,CAAC,
|
|
1
|
+
{"version":3,"file":"config.js","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AACA,OAAO,SAAS,MAAM,oBAAoB,CAAC;AAC3C,OAAO,EACL,YAAY,EACZ,gBAAgB,EAChB,uBAAuB,EACvB,oBAAoB,GACrB,MAAM,YAAY,CAAC;AAWpB,MAAM,IAAI,GAAG,CACX,CAAC,OAAO,OAAO,KAAK,QAAQ,IAAI,OAAO,EAAE,GAAG,CAAC;OAC1C,UAAU,CACS,CAAC;AAEzB,MAAM,SAAS,GAAG,SAAS,EAAE,CAAC;AAE9B,MAAM,IAAI,GAAG,UAAU,CAAC,eAAe,IAAI;IACzC,MAAM,EAAE,EAAE;CACX,CAAC;AACF,UAAU,CAAC,eAAe,GAAG,IAAI,CAAC;AAClC,IAAI,CAAC,SAAS,GAAG,IAAI,CAAC,SAAS,IAAI,YAAY,CAAC;AAChD,IAAI,CAAC,aAAa,GAAG,IAAI,CAAC,aAAa,IAAI,gBAAgB,CAAC;AAC5D,IAAI,CAAC,oBAAoB,GAAG,IAAI,CAAC,oBAAoB,IAAI,uBAAuB,CAAC;AACjF,IAAI,CAAC,iBAAiB,GAAG,IAAI,CAAC,iBAAiB,IAAI,oBAAoB,CAAC;AAExE,eAAe;IACb,GAAG;QACD,OAAO;YACL,IAAI,EAAE,IAAI,CAAC,SAAS;YACpB,QAAQ,EAAE,IAAI,CAAC,aAAa;YAC5B,cAAc,EAAE,IAAI,CAAC,oBAAoB;YACzC,WAAW,EAAE,IAAI,CAAC,iBAAiB;YACnC,OAAO,EAAE,MAAM,CAAC,IAAI,CAAC,aAAa,CAAC;YACnC,GAAG,IAAI,CAAC,MAAM;SACf,CAAC;IACJ,CAAC;IACD,GAAG,CAAC,MAA2B;QAC7B,MAAM,EAAE,eAAe,EAAE,GAAG,MAAM,CAAC;QACnC,IAAI,eAAe,EAAE;YACnB,MAAM,CAAC,IAAI,GAAG,MAAM,CAAC,IAAI,IAAI,eAAe,CAAC,IAAI,CAAC;YAClD,MAAM,CAAC,QAAQ,GAAG,MAAM,CAAC,QAAQ,IAAI,eAAe,CAAC,QAAQ,CAAC;YAC9D,MAAM,CAAC,cAAc,GAAG,MAAM,CAAC,cAAc,IAAI,eAAe,CAAC,cAAc,CAAC;YAChF,MAAM,CAAC,WAAW,GAAG,MAAM,CAAC,cAAc,IAAI,eAAe,CAAC,WAAW,CAAC;SAC3E;QACD,IAAI,CAAC,MAAM,GAAG,SAAS,CAAC,IAAI,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;QAC7C,IAAI,MAAM,CAAC,OAAO,EAAE;YAClB,IAAI,CAAC,aAAa,GAAG,MAAM,CAAC,OAAO,CAAC;SACrC;QACD,IAAI,CAAC,SAAS,GAAG,IAAI,CAAC,SAAS,IAAI,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC;QACpD,IAAI,CAAC,aAAa,GAAG,IAAI,CAAC,aAAa,IAAI,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC;QAChE,IAAI,CAAC,oBAAoB,GAAG,IAAI,CAAC,oBAAoB,IAAI,IAAI,CAAC,MAAM,CAAC,cAAc,CAAC;QACpF,IAAI,CAAC,iBAAiB,GAAG,IAAI,CAAC,iBAAiB,IAAI,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC;IAC7E,CAAC;CACF,CAAC"}
|
|
@@ -48,8 +48,8 @@ export default {
|
|
|
48
48
|
if (settingsContent) {
|
|
49
49
|
config.lang = config.lang || settingsContent.lang;
|
|
50
50
|
config.currency = config.currency || settingsContent.currency;
|
|
51
|
-
config.currencySymbol = config.currencySymbol || settingsContent.
|
|
52
|
-
config.countryCode = config.currencySymbol || settingsContent.
|
|
51
|
+
config.currencySymbol = config.currencySymbol || settingsContent.currencySymbol;
|
|
52
|
+
config.countryCode = config.currencySymbol || settingsContent.countryCode;
|
|
53
53
|
}
|
|
54
54
|
self.config = deepmerge(self.config, config);
|
|
55
55
|
if (config.storeId) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cloudcommerce/emails",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.28.0",
|
|
5
5
|
"description": "E-Com Plus Cloud Commerce email sender",
|
|
6
6
|
"main": "lib/index.js",
|
|
7
7
|
"types": "lib/index.d.ts",
|
|
@@ -23,13 +23,13 @@
|
|
|
23
23
|
},
|
|
24
24
|
"dependencies": {
|
|
25
25
|
"@cloudcommerce/firebase": "workspace:*",
|
|
26
|
-
"axios": "^1.5.
|
|
26
|
+
"axios": "^1.5.1",
|
|
27
27
|
"ejs": "^3.1.9",
|
|
28
28
|
"nodemailer": "^6.9.5"
|
|
29
29
|
},
|
|
30
30
|
"devDependencies": {
|
|
31
31
|
"@cloudcommerce/types": "workspace:*",
|
|
32
|
-
"@types/ejs": "^3.1.
|
|
33
|
-
"@types/nodemailer": "^6.4.
|
|
32
|
+
"@types/ejs": "^3.1.3",
|
|
33
|
+
"@types/nodemailer": "^6.4.11"
|
|
34
34
|
}
|
|
35
35
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cloudcommerce/eslint",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.28.0",
|
|
5
5
|
"description": "E-Com Plus Cloud Commerce ESLint config",
|
|
6
6
|
"main": "lib/index.js",
|
|
7
7
|
"repository": {
|
|
@@ -19,11 +19,12 @@
|
|
|
19
19
|
"build": "echo '@ecomplus/eslint'"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"@typescript-eslint/eslint-plugin": "^6.7.
|
|
23
|
-
"@typescript-eslint/parser": "^6.7.
|
|
24
|
-
"eslint": "^8.
|
|
22
|
+
"@typescript-eslint/eslint-plugin": "^6.7.3",
|
|
23
|
+
"@typescript-eslint/parser": "^6.7.3",
|
|
24
|
+
"eslint": "^8.50.0",
|
|
25
25
|
"eslint-config-airbnb-base": "^15.0.0",
|
|
26
26
|
"eslint-plugin-import": "^2.28.1",
|
|
27
|
+
"eslint-plugin-tailwindcss": "3.13.0",
|
|
27
28
|
"eslint-plugin-vue": "^9.17.0"
|
|
28
29
|
}
|
|
29
30
|
}
|
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
module.exports = {
|
|
2
|
-
extends:
|
|
2
|
+
extends: [
|
|
3
|
+
'./base.eslintrc.cjs',
|
|
4
|
+
'plugin:tailwindcss/recommended',
|
|
5
|
+
],
|
|
3
6
|
rules: {
|
|
4
7
|
'no-console': 'off',
|
|
8
|
+
'max-len': 'warn',
|
|
5
9
|
'semi': 'warn',
|
|
6
10
|
'arrow-parens': 'warn',
|
|
7
11
|
'object-curly-newline': 'warn',
|
|
@@ -23,7 +27,10 @@ module.exports = {
|
|
|
23
27
|
'Prices',
|
|
24
28
|
'Banner',
|
|
25
29
|
'Countdown',
|
|
30
|
+
'Collapse',
|
|
31
|
+
'Accordion',
|
|
26
32
|
],
|
|
27
33
|
}],
|
|
34
|
+
'tailwindcss/no-custom-classname': 'off',
|
|
28
35
|
},
|
|
29
36
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cloudcommerce/events",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.28.0",
|
|
5
5
|
"description": "E-Com Plus Cloud Commerce app events",
|
|
6
6
|
"main": "lib/index.js",
|
|
7
7
|
"exports": {
|
|
@@ -41,7 +41,7 @@
|
|
|
41
41
|
"@cloudcommerce/app-tiny-erp": "workspace:*",
|
|
42
42
|
"@cloudcommerce/app-webhooks": "workspace:*",
|
|
43
43
|
"@cloudcommerce/firebase": "workspace:*",
|
|
44
|
-
"firebase-admin": "^11.
|
|
44
|
+
"firebase-admin": "^11.11.0",
|
|
45
45
|
"firebase-functions": "^4.4.1",
|
|
46
46
|
"source-map-support": "^0.5.21"
|
|
47
47
|
},
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cloudcommerce/firebase",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.28.0",
|
|
5
5
|
"description": "E-Com Plus Cloud Commerce on Firebase",
|
|
6
6
|
"main": "lib/index.js",
|
|
7
7
|
"types": "lib/index.d.ts",
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"@cloudcommerce/api": "workspace:*",
|
|
33
33
|
"@cloudcommerce/config": "workspace:*",
|
|
34
34
|
"@google-cloud/pubsub": "^4.0.6",
|
|
35
|
-
"firebase-admin": "^11.
|
|
35
|
+
"firebase-admin": "^11.11.0",
|
|
36
36
|
"firebase-functions": "^4.4.1",
|
|
37
37
|
"source-map-support": "^0.5.21"
|
|
38
38
|
},
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cloudcommerce/modules",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.28.0",
|
|
5
5
|
"description": "E-Com Plus Cloud Commerce modules API",
|
|
6
6
|
"main": "lib/index.cjs",
|
|
7
7
|
"exports": {
|
|
@@ -45,8 +45,8 @@
|
|
|
45
45
|
"@ecomplus/utils": "1.5.0-rc.5",
|
|
46
46
|
"ajv": "^8.12.0",
|
|
47
47
|
"ajv-formats": "^2.1.1",
|
|
48
|
-
"axios": "^1.5.
|
|
49
|
-
"firebase-admin": "^11.
|
|
48
|
+
"axios": "^1.5.1",
|
|
49
|
+
"firebase-admin": "^11.11.0",
|
|
50
50
|
"firebase-functions": "^4.4.1",
|
|
51
51
|
"source-map-support": "^0.5.21"
|
|
52
52
|
},
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cloudcommerce/passport",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.28.0",
|
|
5
5
|
"description": "E-Com Plus Cloud Commerce customers authentication (passport) API",
|
|
6
6
|
"main": "lib/index.js",
|
|
7
7
|
"exports": {
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"dependencies": {
|
|
26
26
|
"@cloudcommerce/api": "workspace:*",
|
|
27
27
|
"@cloudcommerce/firebase": "workspace:*",
|
|
28
|
-
"firebase-admin": "^11.
|
|
28
|
+
"firebase-admin": "^11.11.0",
|
|
29
29
|
"firebase-functions": "^4.4.1",
|
|
30
30
|
"source-map-support": "^0.5.21"
|
|
31
31
|
},
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cloudcommerce/ssr",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.28.0",
|
|
5
5
|
"description": "E-Com Plus Cloud Commerce storefront SSR",
|
|
6
6
|
"main": "lib/index.js",
|
|
7
7
|
"exports": {
|
|
@@ -33,13 +33,13 @@
|
|
|
33
33
|
"@vueuse/core": "10.4.1",
|
|
34
34
|
"astro": "2.10.15",
|
|
35
35
|
"astro-capo": "^0.0.1",
|
|
36
|
-
"firebase-admin": "^11.
|
|
36
|
+
"firebase-admin": "^11.11.0",
|
|
37
37
|
"firebase-functions": "^4.4.1",
|
|
38
38
|
"vue": "^3.3.4"
|
|
39
39
|
},
|
|
40
40
|
"devDependencies": {
|
|
41
41
|
"@cloudcommerce/types": "workspace:*",
|
|
42
|
-
"@cloudflare/workers-types": "^4.
|
|
42
|
+
"@cloudflare/workers-types": "^4.20230922.0",
|
|
43
43
|
"@firebase/app-types": "^0.9.0"
|
|
44
44
|
}
|
|
45
45
|
}
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
/* prettier-ignore */
|
|
3
|
+
// @ts-nocheck
|
|
4
|
+
// noinspection JSUnusedGlobalSymbols
|
|
5
|
+
// Generated by unplugin-auto-import
|
|
6
|
+
export {}
|
|
7
|
+
declare global {
|
|
8
|
+
const EffectScope: typeof import('vue')['EffectScope']
|
|
9
|
+
const computed: typeof import('vue')['computed']
|
|
10
|
+
const createApp: typeof import('vue')['createApp']
|
|
11
|
+
const customRef: typeof import('vue')['customRef']
|
|
12
|
+
const defineAsyncComponent: typeof import('vue')['defineAsyncComponent']
|
|
13
|
+
const defineComponent: typeof import('vue')['defineComponent']
|
|
14
|
+
const effectScope: typeof import('vue')['effectScope']
|
|
15
|
+
const getCurrentInstance: typeof import('vue')['getCurrentInstance']
|
|
16
|
+
const getCurrentScope: typeof import('vue')['getCurrentScope']
|
|
17
|
+
const h: typeof import('vue')['h']
|
|
18
|
+
const inject: typeof import('vue')['inject']
|
|
19
|
+
const isProxy: typeof import('vue')['isProxy']
|
|
20
|
+
const isReactive: typeof import('vue')['isReactive']
|
|
21
|
+
const isReadonly: typeof import('vue')['isReadonly']
|
|
22
|
+
const isRef: typeof import('vue')['isRef']
|
|
23
|
+
const markRaw: typeof import('vue')['markRaw']
|
|
24
|
+
const nextTick: typeof import('vue')['nextTick']
|
|
25
|
+
const onActivated: typeof import('vue')['onActivated']
|
|
26
|
+
const onBeforeMount: typeof import('vue')['onBeforeMount']
|
|
27
|
+
const onBeforeUnmount: typeof import('vue')['onBeforeUnmount']
|
|
28
|
+
const onBeforeUpdate: typeof import('vue')['onBeforeUpdate']
|
|
29
|
+
const onDeactivated: typeof import('vue')['onDeactivated']
|
|
30
|
+
const onErrorCaptured: typeof import('vue')['onErrorCaptured']
|
|
31
|
+
const onMounted: typeof import('vue')['onMounted']
|
|
32
|
+
const onRenderTracked: typeof import('vue')['onRenderTracked']
|
|
33
|
+
const onRenderTriggered: typeof import('vue')['onRenderTriggered']
|
|
34
|
+
const onScopeDispose: typeof import('vue')['onScopeDispose']
|
|
35
|
+
const onServerPrefetch: typeof import('vue')['onServerPrefetch']
|
|
36
|
+
const onUnmounted: typeof import('vue')['onUnmounted']
|
|
37
|
+
const onUpdated: typeof import('vue')['onUpdated']
|
|
38
|
+
const provide: typeof import('vue')['provide']
|
|
39
|
+
const reactive: typeof import('vue')['reactive']
|
|
40
|
+
const readonly: typeof import('vue')['readonly']
|
|
41
|
+
const ref: typeof import('vue')['ref']
|
|
42
|
+
const resolveComponent: typeof import('vue')['resolveComponent']
|
|
43
|
+
const shallowReactive: typeof import('vue')['shallowReactive']
|
|
44
|
+
const shallowReadonly: typeof import('vue')['shallowReadonly']
|
|
45
|
+
const shallowRef: typeof import('vue')['shallowRef']
|
|
46
|
+
const toRaw: typeof import('vue')['toRaw']
|
|
47
|
+
const toRef: typeof import('vue')['toRef']
|
|
48
|
+
const toRefs: typeof import('vue')['toRefs']
|
|
49
|
+
const toValue: typeof import('vue')['toValue']
|
|
50
|
+
const triggerRef: typeof import('vue')['triggerRef']
|
|
51
|
+
const unref: typeof import('vue')['unref']
|
|
52
|
+
const useAttrs: typeof import('vue')['useAttrs']
|
|
53
|
+
const useCssModule: typeof import('vue')['useCssModule']
|
|
54
|
+
const useCssVars: typeof import('vue')['useCssVars']
|
|
55
|
+
const useSlots: typeof import('vue')['useSlots']
|
|
56
|
+
const watch: typeof import('vue')['watch']
|
|
57
|
+
const watchEffect: typeof import('vue')['watchEffect']
|
|
58
|
+
const watchPostEffect: typeof import('vue')['watchPostEffect']
|
|
59
|
+
const watchSyncEffect: typeof import('vue')['watchSyncEffect']
|
|
60
|
+
}
|
|
61
|
+
// for type re-export
|
|
62
|
+
declare global {
|
|
63
|
+
// @ts-ignore
|
|
64
|
+
export type { Component, ComponentPublicInstance, ComputedRef, InjectionKey, PropType, Ref, VNode, WritableComputedRef } from 'vue'
|
|
65
|
+
}
|