ng-easycommerce-v18 0.0.6 → 0.0.8
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/assets/ec-i18n/es.json +4 -0
- package/esm2022/lib/constants/core.constants.service.mjs +2 -2
- package/esm2022/lib/ec-components/auth-ec/register-form-ec/register-form-ec.component.mjs +20 -21
- package/esm2022/lib/ec-components/blocks-ec/block-banner-box-ec/block-banner-box-ec.component.mjs +5 -4
- package/esm2022/lib/ec-components/blocks-ec/block-products-ec/block-products-ec.component.mjs +4 -4
- package/esm2022/lib/ec-components/filters-ec/filters-ec.component.mjs +2 -2
- package/esm2022/lib/ec-components/product-detail-ec/product-detail-ec.component.mjs +8 -2
- package/esm2022/lib/ec-components/product-ec/product-ec.component.mjs +3 -3
- package/esm2022/lib/ec-components/sidebar-ec/sidebar-ec.component.mjs +3 -3
- package/esm2022/lib/ec-components/variants-ec/variants-ec.component.mjs +3 -3
- package/esm2022/lib/ec-services/options.service.mjs +19 -12
- package/fesm2022/ng-easycommerce-v18.mjs +58 -45
- package/fesm2022/ng-easycommerce-v18.mjs.map +1 -1
- package/lib/ec-components/auth-ec/register-form-ec/register-form-ec.component.d.ts +1 -2
- package/lib/ec-components/blocks-ec/block-banner-box-ec/block-banner-box-ec.component.d.ts +1 -0
- package/lib/ec-components/product-detail-ec/product-detail-ec.component.d.ts +3 -1
- package/lib/ec-services/options.service.d.ts +6 -7
- package/package.json +1 -1
|
@@ -223,7 +223,7 @@ class CoreConstantsService {
|
|
|
223
223
|
* @param postMedia
|
|
224
224
|
* @returns
|
|
225
225
|
*/
|
|
226
|
-
mediaImageUrl = (postMedia) => this.ASSETS_URL + (this.ASSETS_URL == this.apiConstants.API_URL ? 'media/image' : '') + (postMedia ? postMedia : "image/");
|
|
226
|
+
mediaImageUrl = (postMedia) => this.ASSETS_URL + (this.ASSETS_URL == this.apiConstants.API_URL ? 'media/image/' : '') + (postMedia ? postMedia : "image/");
|
|
227
227
|
/**
|
|
228
228
|
* Retorna la url del sitio.
|
|
229
229
|
* @param postMedia
|
|
@@ -488,12 +488,16 @@ class OptionsService {
|
|
|
488
488
|
return this.attributes$;
|
|
489
489
|
}
|
|
490
490
|
// HELPERS
|
|
491
|
-
slugify
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
491
|
+
slugify(value) {
|
|
492
|
+
if (!value || typeof value !== 'string') {
|
|
493
|
+
return ''; // o devolver un slug por defecto si preferís
|
|
494
|
+
}
|
|
495
|
+
return value.toLowerCase().replace(/\s+/g, '-').replace(/[^\w\-]+/g, '');
|
|
496
|
+
} /**
|
|
497
|
+
* Elimina los acentos
|
|
498
|
+
* @param str
|
|
499
|
+
* @returns
|
|
500
|
+
*/
|
|
497
501
|
removeAccents(str) {
|
|
498
502
|
return str.normalize("NFD").replace(/[\u0300-\u036f]/g, "");
|
|
499
503
|
}
|
|
@@ -505,18 +509,21 @@ class OptionsService {
|
|
|
505
509
|
* @returns
|
|
506
510
|
*/
|
|
507
511
|
appendPaths(isCategory, response) {
|
|
508
|
-
const
|
|
512
|
+
const normalizedResponse = Array.isArray(response) ? response : [response];
|
|
513
|
+
const result = normalizedResponse.map((subelement) => {
|
|
509
514
|
if (!subelement.children || subelement.children.length == 0) {
|
|
510
515
|
subelement.children = [];
|
|
511
|
-
subelement.path = isCategory
|
|
512
|
-
|
|
516
|
+
subelement.path = isCategory
|
|
517
|
+
? this.constants.PRODUCT_LIST_ROUTE + 'categories/' + this.slugify(subelement.slug ?? subelement.name)
|
|
518
|
+
: this.constants.PRODUCT_LIST_ROUTE + 'attributes/' + this.slugify(subelement.slug ?? subelement.name);
|
|
513
519
|
}
|
|
514
520
|
else if (subelement.children) {
|
|
515
521
|
subelement.slug = subelement.slug || this.slugify(subelement.name);
|
|
516
522
|
subelement.children = this.appendPaths(isCategory, subelement.children);
|
|
517
523
|
}
|
|
518
|
-
|
|
519
|
-
|
|
524
|
+
subelement.path = isCategory
|
|
525
|
+
? this.constants.PRODUCT_LIST_ROUTE + 'categories/' + this.slugify(subelement.slug ?? subelement.name)
|
|
526
|
+
: this.constants.PRODUCT_LIST_ROUTE + 'attributes/' + this.slugify(subelement.slug ?? subelement.name);
|
|
520
527
|
return subelement;
|
|
521
528
|
});
|
|
522
529
|
return result;
|
|
@@ -5792,7 +5799,7 @@ class BlockBannerBoxEcComponent extends BlockEcComponent {
|
|
|
5792
5799
|
swiperOptions() {
|
|
5793
5800
|
return {
|
|
5794
5801
|
slidesPerView: 1,
|
|
5795
|
-
autoplay:
|
|
5802
|
+
autoplay: false,
|
|
5796
5803
|
loop: true,
|
|
5797
5804
|
speed: 1050,
|
|
5798
5805
|
pagination: false,
|
|
@@ -5827,12 +5834,13 @@ class BlockBannerBoxEcComponent extends BlockEcComponent {
|
|
|
5827
5834
|
redirectRoute(url) {
|
|
5828
5835
|
// this.router.navigate(['/collection/categories'])
|
|
5829
5836
|
}
|
|
5837
|
+
boxesInlcudesCode = (box) => this.meta.code.toUpperCase().includes(box.toUpperCase());
|
|
5830
5838
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: BlockBannerBoxEcComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
5831
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.0", type: BlockBannerBoxEcComponent, isStandalone: true, selector: "app-block-banner-box-ec", inputs: { banners: "banners", meta: "meta" }, usesInheritance: true, ngImport: i0, template: "@if(banners.length){\r\n <section [ngClass]=\"trimClassBlock(meta.code) + ' container
|
|
5839
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.0", type: BlockBannerBoxEcComponent, isStandalone: true, selector: "app-block-banner-box-ec", inputs: { banners: "banners", meta: "meta" }, usesInheritance: true, ngImport: i0, template: "@if(banners.length){\r\n <section [ngClass]=\"trimClassBlock(meta.code) + ' container'\" \r\n [style.background-color]=\"meta.styles?.backgroundColor\"\r\n [style.background-image]=\"meta.styles?.backgroundImage ? 'url(' + mediaUrl + meta.styles?.backgroundImage +')' : 'inherit'\">\r\n\r\n <div class=\"block-boxes\">\r\n @if(meta.name){\r\n <div class=\"row\">\r\n a\r\n <div class=\"col-12 mt-4\">\r\n <h2 class=\"font-weight-normal font-gd\">\r\n <span>{{meta.name}}</span>\r\n </h2>\r\n </div>\r\n </div> \r\n }\r\n \r\n @if(meta.styles && meta.styles.carrousel == false){\r\n <!-- Si es formato fijo -->\r\n <div class=\"banner-content\">\r\n <div class=\"row g-0\">\r\n @for (banner of banners; track $index) {\r\n <div [ngClass]=\"'item '+'col-md-6 '+'col-lg-'+(12/banners.length) \" [id]=\"$index\">\r\n <img class=\"img-fluid\" [src]=\" mediaBannerUrl+getImage(banner)\" alt=\"\" />\r\n <div class=\"position-absolute w-100 top-0 start-0 h-100\">\r\n <h2 [ngClass]=\"'item-title px-2 item-position-vertical-'+ (banner.styles?.description?.position)\"\r\n [style.color]=\"(banner.styles?.description?.color) ? banner.styles?.description?.color : '#000'\">\r\n {{banner.title}}\r\n </h2>\r\n @if(banner.subtitle){\r\n <p [style.color]=\"(banner.styles?.description?.color) ? banner.styles?.description?.color : '#000' \"\r\n [class]=\"'px-4 item-subtitle item-position-vertical-' + (banner.styles?.description?.position)\">\r\n {{banner.subtitle}}\r\n </p>\r\n }\r\n </div>\r\n <div [class]=\"'item-position-vertical-' + (banner.styles?.button?.position)\">\r\n @if(banner.styles?.button?.text){\r\n <a href=\"{{banner.url}}\" [class]=\"'item-button btn btn-light'\">\r\n {{banner.styles.button.text}}\r\n </a>\r\n }\r\n </div>\r\n </div>\r\n }\r\n </div>\r\n </div>\r\n }@else {\r\n <!-- Si es Carrousel -->\r\n <swiper-container init=\"false\" [id]=\"meta?.code\">\r\n @for (banner of banners; track $index) {\r\n <!-- Si es de Categorias -->\r\n @if (banner.taxons[0]) {\r\n <swiper-slide>\r\n\r\n <a class=\"banner-content carrousel item\" (click)='redirectRoute(banner.taxons[0].slug)' [routerLink]=\"['/collection/categories/', banner.taxons[0].slug]\" routerLinkActive=\"router-link-active\" style=\"text-decoration: none; cursor: pointer; background-color: white;\">\r\n <div class=\"image-container\">\r\n <img [src]=\"mediaBannerUrl+getImage(banner)\" alt=\"Banner Image\" class=\"banner-image\">\r\n </div>\r\n @if(banner.title){\r\n <h2 [class]=\"'box-text item-title-full px-2 item-position-vertical-'+ (banner.styles?.description?.position)\"\r\n style=\"color:#fff\">\r\n {{banner.title}}\r\n </h2>\r\n }\r\n @if(banner.taxons && banner.taxons.length){\r\n <h5 class=\"item-subtitle-full item-position-vertical-center text-center box-text\">\r\n {{banner.translations.es_AR.title}}\r\n </h5>\r\n }\r\n @if(banner.subtitle){\r\n <p [style.color]=\"(banner.styles?.description?.color) ? banner.styles?.description?.color : '#000' \"\r\n [class]=\"'box-text px-4 item-subtitle-full item-position-vertical-' + (banner.styles?.description?.position)\">\r\n {{banner.subtitle}}\r\n </p>\r\n }\r\n </a>\r\n </swiper-slide>\r\n } @else {\r\n <swiper-slide>\r\n\r\n <a class=\"banner-content carrousel item\" style=\"cursor: pointer;\">\r\n <div class=\"image-container\">\r\n <img [src]=\"mediaBannerUrl+getImage(banner)\" alt=\"Banner Image\" class=\"banner-image\">\r\n </div>\r\n @if(banner.title){\r\n <h2 [class]=\"'box-text item-title-full px-2 item-position-vertical-'+ (banner.styles?.description?.position)\"\r\n style=\"color:#fff\">\r\n {{banner.title}}\r\n </h2>\r\n }\r\n @if(banner.taxons && banner.taxons.length){\r\n <h5 class=\"item-subtitle-full item-position-vertical-center text-center box-text\">\r\n {{banner.translations.es_AR.title}}\r\n </h5>\r\n }\r\n @if(banner.subtitle){\r\n <p [style.color]=\"(banner.styles?.description?.color) ? banner.styles?.description?.color : '#000' \"\r\n [class]=\"'box-text px-4 item-subtitle-full item-position-vertical-' + (banner.styles?.description?.position)\">\r\n {{banner.subtitle}}\r\n </p>\r\n }\r\n </a>\r\n </swiper-slide>\r\n }\r\n \r\n }\r\n </swiper-container> \r\n }\r\n </div>\r\n\r\n </section>\r\n}", styles: ["@charset \"UTF-8\";.banner-container{text-align:center}.banner-image{display:block;margin:0 auto}.item-subtitle-full{margin-top:10px}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "ngmodule", type: RouterModule }, { kind: "directive", type: i2.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "directive", type: i2.RouterLinkActive, selector: "[routerLinkActive]", inputs: ["routerLinkActiveOptions", "ariaCurrentWhenActive", "routerLinkActive"], outputs: ["isActiveChange"], exportAs: ["routerLinkActive"] }] });
|
|
5832
5840
|
}
|
|
5833
5841
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: BlockBannerBoxEcComponent, decorators: [{
|
|
5834
5842
|
type: Component,
|
|
5835
|
-
args: [{ selector: 'app-block-banner-box-ec', standalone: true, imports: [CommonModule, RouterModule], schemas: [CUSTOM_ELEMENTS_SCHEMA], template: "@if(banners.length){\r\n <section [ngClass]=\"trimClassBlock(meta.code) + ' container
|
|
5843
|
+
args: [{ selector: 'app-block-banner-box-ec', standalone: true, imports: [CommonModule, RouterModule], schemas: [CUSTOM_ELEMENTS_SCHEMA], template: "@if(banners.length){\r\n <section [ngClass]=\"trimClassBlock(meta.code) + ' container'\" \r\n [style.background-color]=\"meta.styles?.backgroundColor\"\r\n [style.background-image]=\"meta.styles?.backgroundImage ? 'url(' + mediaUrl + meta.styles?.backgroundImage +')' : 'inherit'\">\r\n\r\n <div class=\"block-boxes\">\r\n @if(meta.name){\r\n <div class=\"row\">\r\n a\r\n <div class=\"col-12 mt-4\">\r\n <h2 class=\"font-weight-normal font-gd\">\r\n <span>{{meta.name}}</span>\r\n </h2>\r\n </div>\r\n </div> \r\n }\r\n \r\n @if(meta.styles && meta.styles.carrousel == false){\r\n <!-- Si es formato fijo -->\r\n <div class=\"banner-content\">\r\n <div class=\"row g-0\">\r\n @for (banner of banners; track $index) {\r\n <div [ngClass]=\"'item '+'col-md-6 '+'col-lg-'+(12/banners.length) \" [id]=\"$index\">\r\n <img class=\"img-fluid\" [src]=\" mediaBannerUrl+getImage(banner)\" alt=\"\" />\r\n <div class=\"position-absolute w-100 top-0 start-0 h-100\">\r\n <h2 [ngClass]=\"'item-title px-2 item-position-vertical-'+ (banner.styles?.description?.position)\"\r\n [style.color]=\"(banner.styles?.description?.color) ? banner.styles?.description?.color : '#000'\">\r\n {{banner.title}}\r\n </h2>\r\n @if(banner.subtitle){\r\n <p [style.color]=\"(banner.styles?.description?.color) ? banner.styles?.description?.color : '#000' \"\r\n [class]=\"'px-4 item-subtitle item-position-vertical-' + (banner.styles?.description?.position)\">\r\n {{banner.subtitle}}\r\n </p>\r\n }\r\n </div>\r\n <div [class]=\"'item-position-vertical-' + (banner.styles?.button?.position)\">\r\n @if(banner.styles?.button?.text){\r\n <a href=\"{{banner.url}}\" [class]=\"'item-button btn btn-light'\">\r\n {{banner.styles.button.text}}\r\n </a>\r\n }\r\n </div>\r\n </div>\r\n }\r\n </div>\r\n </div>\r\n }@else {\r\n <!-- Si es Carrousel -->\r\n <swiper-container init=\"false\" [id]=\"meta?.code\">\r\n @for (banner of banners; track $index) {\r\n <!-- Si es de Categorias -->\r\n @if (banner.taxons[0]) {\r\n <swiper-slide>\r\n\r\n <a class=\"banner-content carrousel item\" (click)='redirectRoute(banner.taxons[0].slug)' [routerLink]=\"['/collection/categories/', banner.taxons[0].slug]\" routerLinkActive=\"router-link-active\" style=\"text-decoration: none; cursor: pointer; background-color: white;\">\r\n <div class=\"image-container\">\r\n <img [src]=\"mediaBannerUrl+getImage(banner)\" alt=\"Banner Image\" class=\"banner-image\">\r\n </div>\r\n @if(banner.title){\r\n <h2 [class]=\"'box-text item-title-full px-2 item-position-vertical-'+ (banner.styles?.description?.position)\"\r\n style=\"color:#fff\">\r\n {{banner.title}}\r\n </h2>\r\n }\r\n @if(banner.taxons && banner.taxons.length){\r\n <h5 class=\"item-subtitle-full item-position-vertical-center text-center box-text\">\r\n {{banner.translations.es_AR.title}}\r\n </h5>\r\n }\r\n @if(banner.subtitle){\r\n <p [style.color]=\"(banner.styles?.description?.color) ? banner.styles?.description?.color : '#000' \"\r\n [class]=\"'box-text px-4 item-subtitle-full item-position-vertical-' + (banner.styles?.description?.position)\">\r\n {{banner.subtitle}}\r\n </p>\r\n }\r\n </a>\r\n </swiper-slide>\r\n } @else {\r\n <swiper-slide>\r\n\r\n <a class=\"banner-content carrousel item\" style=\"cursor: pointer;\">\r\n <div class=\"image-container\">\r\n <img [src]=\"mediaBannerUrl+getImage(banner)\" alt=\"Banner Image\" class=\"banner-image\">\r\n </div>\r\n @if(banner.title){\r\n <h2 [class]=\"'box-text item-title-full px-2 item-position-vertical-'+ (banner.styles?.description?.position)\"\r\n style=\"color:#fff\">\r\n {{banner.title}}\r\n </h2>\r\n }\r\n @if(banner.taxons && banner.taxons.length){\r\n <h5 class=\"item-subtitle-full item-position-vertical-center text-center box-text\">\r\n {{banner.translations.es_AR.title}}\r\n </h5>\r\n }\r\n @if(banner.subtitle){\r\n <p [style.color]=\"(banner.styles?.description?.color) ? banner.styles?.description?.color : '#000' \"\r\n [class]=\"'box-text px-4 item-subtitle-full item-position-vertical-' + (banner.styles?.description?.position)\">\r\n {{banner.subtitle}}\r\n </p>\r\n }\r\n </a>\r\n </swiper-slide>\r\n }\r\n \r\n }\r\n </swiper-container> \r\n }\r\n </div>\r\n\r\n </section>\r\n}", styles: ["@charset \"UTF-8\";.banner-container{text-align:center}.banner-image{display:block;margin:0 auto}.item-subtitle-full{margin-top:10px}\n"] }]
|
|
5836
5844
|
}], ctorParameters: () => [], propDecorators: { banners: [{
|
|
5837
5845
|
type: Input,
|
|
5838
5846
|
args: [{
|
|
@@ -6040,11 +6048,11 @@ class ProductEcComponent {
|
|
|
6040
6048
|
return this.product.saleprice && this.product.saleprice !== this.product.price;
|
|
6041
6049
|
}
|
|
6042
6050
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: ProductEcComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
6043
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.0", type: ProductEcComponent, isStandalone: true, selector: "app-product-ec", inputs: { product: "product", isProductBox: "isProductBox", isCollection: "isCollection" }, outputs: { loaded: "loaded" }, ngImport: i0, template: "<a [routerLink]=\"['/product', product.id]\" class=\"text-decoration-none\">\r\n <!-- Marca especial y descuento -->\r\n <!-- <div *ngIf=\"product.saleprice || (product.special_mark && product.special_mark !== null && product.special_mark !== undefined && product.special_mark.length >0)\"\r\n class=\"marcas\">\r\n <div *ecProductStock=\"product\" [ecProductMini]=\"product.special_mark\"></div>\r\n <ng-container *ngIf=\"shouldShowPrice\">\r\n <div *ecProductStock=\"product\" [ngClass]=\"{'tag-dsc float-right': product.saleprice}\"\r\n [ecProductOff]=\"product\">\r\n </div>\r\n </ng-container>\r\n </div> -->\r\n\r\n <!-- Imagen del producto -->\r\n <div class=\"foto\">\r\n @if(product.picturesdefault){\r\n @if (product.picturesdefault && product.picturesdefault.length > 1 ) {\r\n <img [src]=\"mediaUrl + product.picturesdefault[0]\" alt=\"Imagen principal\" class=\"w-100 pic01\" />\r\n <img [src]=\"mediaUrl + product.picturesdefault[1]\" alt=\"Imagen secundaria\" class=\"w-100 pic02\" />\r\n } @else {\r\n <img [src]=\"mediaUrl + product.picturesdefault[0]\" alt=\"Imagen principal\" class=\"w-100 pic01\" />\r\n }\r\n }\r\n </div>\r\n <!-- Precio -->\r\n \r\n\r\n <!-- Nombre del producto -->\r\n <h6 class=\"title\">{{ product.name | titlecase }}</h6>\r\n\r\n <div class=\"sku\" [innerHTML]=\"product.shortdetails\"></div>\r\n \r\n @if (shouldShowPrice) {\r\n <app-price-ec [price]=\"product.price\" [saleprice]=\"product.saleprice\" class=\"\" />\r\n }@else {\r\n <p class=\"noPrice\"></p>\r\n }\r\n\r\n <div class=\"fixBottom\">\r\n\r\n <!-- Bot\u00F3n de acciones -->\r\n <!-- <ng-container *ecProductStock=\"product; else noStock\"> -->\r\n <!-- Cuando no tiene marca especial o es de tipo 'standard' -->\r\n @if (!product.special_mark || product.special_mark.length === 0 || product.special_mark[0]?.type ===\r\n 'standard') {\r\n <button class=\"btn\" [ngClass]=\"isCollection ? 'px-2 w-100 d-sm-block' : 'py-2 px-4'\">\r\n <ng-container *ngIf=\"isCollection; else normalText\">\r\n <span> {{(\"buy\" | translate) | uppercase}} </span>\r\n </ng-container>\r\n <ng-template #normalText>\r\n {{(\"buy\" | translate) | uppercase}}\r\n </ng-template>\r\n </button>\r\n }\r\n <!-- Cuando tiene marca especial y el tipo no es 'standard' -->\r\n @if(product.special_mark?.[0]?.type !== 'standard'){\r\n @for (item of product.special_mark; track $index) {\r\n <!-- Caso 1: Agotado o Disponible muy pronto -->\r\n @if (item.type === 'out_of_stock' || item.type === 'coming_soon') {\r\n <button class=\"btn\" [ngClass]=\"isCollection ? 'px-2 w-100 d-sm-block' : 'py-2 px-4'\">\r\n @if(isCollection){\r\n <span>{{ item.name | uppercase }} </span>\r\n }@else {\r\n {{ item.name | uppercase }}\r\n }\r\n </button>}\r\n <!-- Caso 2: Contacto por WhatsApp -->\r\n @if (item.type === 'whatsapp_contact') {\r\n <button class=\"btn\" [ngClass]=\"isCollection ? 'px-2 w-100 d-sm-block' : 'py-2 px-4'\"\r\n (click)=\"openWhatsApp(item.whatsappContact)\">\r\n @if(isCollection){\r\n <span>{{ item.name | uppercase }}</span>\r\n }@else {\r\n {{ item.name | uppercase }}\r\n }\r\n\r\n </button>\r\n }\r\n <!-- Caso 3: Solicitar m\u00E1s informaci\u00F3n -->\r\n @if (item.type === 'more_info') {\r\n <button *ngIf=\"\" class=\"btn\" [ngClass]=\"isCollection ? 'px-2 w-100 d-sm-block' : 'py-2 px-4'\">\r\n @if(isCollection){\r\n <span>{{ item.name | uppercase }}</span>\r\n }@else {\r\n {{ item.name | uppercase }}\r\n }\r\n </button>\r\n }\r\n\r\n }\r\n }\r\n\r\n <!-- </ng-container>\r\n <ng-template #noStock>\r\n <button class=\"btn\" [ngClass]=\"isCollection ? 'px-2 w-100 d-sm-block' : 'py-2 px-4'\">\r\n <ng-container *ngIf=\"isCollection; else normalText\">\r\n <span>{{(\"out-of-stock-short\" | translate) | uppercase}}</span>\r\n </ng-container>\r\n <ng-template #normalText>\r\n {{(\"out-of-stock-short\" | translate) | uppercase}}\r\n </ng-template>\r\n </button>\r\n </ng-template> -->\r\n </div>\r\n</a>", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i1.UpperCasePipe, name: "uppercase" }, { kind: "pipe", type: i1.TitleCasePipe, name: "titlecase" }, { kind: "component", type: PriceEcComponent, selector: "app-price-ec", inputs: ["price", "saleprice"] }, { kind: "directive", type: RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }] });
|
|
6051
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.0", type: ProductEcComponent, isStandalone: true, selector: "app-product-ec", inputs: { product: "product", isProductBox: "isProductBox", isCollection: "isCollection" }, outputs: { loaded: "loaded" }, ngImport: i0, template: "<a [routerLink]=\"['/product', product.id]\" class=\"text-decoration-none producto\">\r\n <!-- Marca especial y descuento -->\r\n <!-- <div *ngIf=\"product.saleprice || (product.special_mark && product.special_mark !== null && product.special_mark !== undefined && product.special_mark.length >0)\"\r\n class=\"marcas\">\r\n <div *ecProductStock=\"product\" [ecProductMini]=\"product.special_mark\"></div>\r\n <ng-container *ngIf=\"shouldShowPrice\">\r\n <div *ecProductStock=\"product\" [ngClass]=\"{'tag-dsc float-right': product.saleprice}\"\r\n [ecProductOff]=\"product\">\r\n </div>\r\n </ng-container>\r\n </div> -->\r\n\r\n <!-- Imagen del producto -->\r\n <div class=\"foto\">\r\n @if(product.picturesdefault){\r\n @if (product.picturesdefault && product.picturesdefault.length > 1 ) {\r\n <img [src]=\"mediaUrl + product.picturesdefault[0]\" alt=\"Imagen principal\" class=\"w-100 pic01\" />\r\n <img [src]=\"mediaUrl + product.picturesdefault[1]\" alt=\"Imagen secundaria\" class=\"w-100 pic02\" />\r\n } @else {\r\n <img [src]=\"mediaUrl + product.picturesdefault[0]\" alt=\"Imagen principal\" class=\"w-100 pic01\" />\r\n }\r\n }\r\n </div>\r\n <!-- Precio -->\r\n \r\n\r\n <!-- Nombre del producto -->\r\n <h6 class=\"title\">{{ product.name | titlecase }}</h6>\r\n\r\n <div class=\"sku\" [innerHTML]=\"product.shortdetails\"></div>\r\n \r\n @if (shouldShowPrice) {\r\n <app-price-ec [price]=\"product.price\" [saleprice]=\"product.saleprice\" class=\"\" />\r\n }@else {\r\n <p class=\"noPrice\"></p>\r\n }\r\n\r\n <div class=\"fixBottom\">\r\n\r\n <!-- Bot\u00F3n de acciones -->\r\n <!-- <ng-container *ecProductStock=\"product; else noStock\"> -->\r\n <!-- Cuando no tiene marca especial o es de tipo 'standard' -->\r\n @if (!product.special_mark || product.special_mark.length === 0 || product.special_mark[0]?.type ===\r\n 'standard') {\r\n <button class=\"btn\" [ngClass]=\"isCollection ? 'px-2 w-100 d-sm-block' : 'py-2 px-4'\">\r\n <ng-container *ngIf=\"isCollection; else normalText\">\r\n <span> {{(\"buy\" | translate) | uppercase}} </span>\r\n </ng-container>\r\n <ng-template #normalText>\r\n {{(\"buy\" | translate) | uppercase}}\r\n </ng-template>\r\n </button>\r\n }\r\n <!-- Cuando tiene marca especial y el tipo no es 'standard' -->\r\n @if(product.special_mark?.[0]?.type !== 'standard'){\r\n @for (item of product.special_mark; track $index) {\r\n <!-- Caso 1: Agotado o Disponible muy pronto -->\r\n @if (item.type === 'out_of_stock' || item.type === 'coming_soon') {\r\n <button class=\"btn\" [ngClass]=\"isCollection ? 'px-2 w-100 d-sm-block' : 'py-2 px-4'\">\r\n @if(isCollection){\r\n <span>{{ item.name | uppercase }} </span>\r\n }@else {\r\n {{ item.name | uppercase }}\r\n }\r\n </button>}\r\n <!-- Caso 2: Contacto por WhatsApp -->\r\n @if (item.type === 'whatsapp_contact') {\r\n <button class=\"btn\" [ngClass]=\"isCollection ? 'px-2 w-100 d-sm-block' : 'py-2 px-4'\"\r\n (click)=\"openWhatsApp(item.whatsappContact)\">\r\n @if(isCollection){\r\n <span>{{ item.name | uppercase }}</span>\r\n }@else {\r\n {{ item.name | uppercase }}\r\n }\r\n\r\n </button>\r\n }\r\n <!-- Caso 3: Solicitar m\u00E1s informaci\u00F3n -->\r\n @if (item.type === 'more_info') {\r\n <button *ngIf=\"\" class=\"btn\" [ngClass]=\"isCollection ? 'px-2 w-100 d-sm-block' : 'py-2 px-4'\">\r\n @if(isCollection){\r\n <span>{{ item.name | uppercase }}</span>\r\n }@else {\r\n {{ item.name | uppercase }}\r\n }\r\n </button>\r\n }\r\n\r\n }\r\n }\r\n\r\n <!-- </ng-container>\r\n <ng-template #noStock>\r\n <button class=\"btn\" [ngClass]=\"isCollection ? 'px-2 w-100 d-sm-block' : 'py-2 px-4'\">\r\n <ng-container *ngIf=\"isCollection; else normalText\">\r\n <span>{{(\"out-of-stock-short\" | translate) | uppercase}}</span>\r\n </ng-container>\r\n <ng-template #normalText>\r\n {{(\"out-of-stock-short\" | translate) | uppercase}}\r\n </ng-template>\r\n </button>\r\n </ng-template> -->\r\n </div>\r\n</a>", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i1.UpperCasePipe, name: "uppercase" }, { kind: "pipe", type: i1.TitleCasePipe, name: "titlecase" }, { kind: "component", type: PriceEcComponent, selector: "app-price-ec", inputs: ["price", "saleprice"] }, { kind: "directive", type: RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }] });
|
|
6044
6052
|
}
|
|
6045
6053
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: ProductEcComponent, decorators: [{
|
|
6046
6054
|
type: Component,
|
|
6047
|
-
args: [{ selector: 'app-product-ec', standalone: true, imports: [CommonModule, PriceEcComponent, RouterLink, TranslateModule], template: "<a [routerLink]=\"['/product', product.id]\" class=\"text-decoration-none\">\r\n <!-- Marca especial y descuento -->\r\n <!-- <div *ngIf=\"product.saleprice || (product.special_mark && product.special_mark !== null && product.special_mark !== undefined && product.special_mark.length >0)\"\r\n class=\"marcas\">\r\n <div *ecProductStock=\"product\" [ecProductMini]=\"product.special_mark\"></div>\r\n <ng-container *ngIf=\"shouldShowPrice\">\r\n <div *ecProductStock=\"product\" [ngClass]=\"{'tag-dsc float-right': product.saleprice}\"\r\n [ecProductOff]=\"product\">\r\n </div>\r\n </ng-container>\r\n </div> -->\r\n\r\n <!-- Imagen del producto -->\r\n <div class=\"foto\">\r\n @if(product.picturesdefault){\r\n @if (product.picturesdefault && product.picturesdefault.length > 1 ) {\r\n <img [src]=\"mediaUrl + product.picturesdefault[0]\" alt=\"Imagen principal\" class=\"w-100 pic01\" />\r\n <img [src]=\"mediaUrl + product.picturesdefault[1]\" alt=\"Imagen secundaria\" class=\"w-100 pic02\" />\r\n } @else {\r\n <img [src]=\"mediaUrl + product.picturesdefault[0]\" alt=\"Imagen principal\" class=\"w-100 pic01\" />\r\n }\r\n }\r\n </div>\r\n <!-- Precio -->\r\n \r\n\r\n <!-- Nombre del producto -->\r\n <h6 class=\"title\">{{ product.name | titlecase }}</h6>\r\n\r\n <div class=\"sku\" [innerHTML]=\"product.shortdetails\"></div>\r\n \r\n @if (shouldShowPrice) {\r\n <app-price-ec [price]=\"product.price\" [saleprice]=\"product.saleprice\" class=\"\" />\r\n }@else {\r\n <p class=\"noPrice\"></p>\r\n }\r\n\r\n <div class=\"fixBottom\">\r\n\r\n <!-- Bot\u00F3n de acciones -->\r\n <!-- <ng-container *ecProductStock=\"product; else noStock\"> -->\r\n <!-- Cuando no tiene marca especial o es de tipo 'standard' -->\r\n @if (!product.special_mark || product.special_mark.length === 0 || product.special_mark[0]?.type ===\r\n 'standard') {\r\n <button class=\"btn\" [ngClass]=\"isCollection ? 'px-2 w-100 d-sm-block' : 'py-2 px-4'\">\r\n <ng-container *ngIf=\"isCollection; else normalText\">\r\n <span> {{(\"buy\" | translate) | uppercase}} </span>\r\n </ng-container>\r\n <ng-template #normalText>\r\n {{(\"buy\" | translate) | uppercase}}\r\n </ng-template>\r\n </button>\r\n }\r\n <!-- Cuando tiene marca especial y el tipo no es 'standard' -->\r\n @if(product.special_mark?.[0]?.type !== 'standard'){\r\n @for (item of product.special_mark; track $index) {\r\n <!-- Caso 1: Agotado o Disponible muy pronto -->\r\n @if (item.type === 'out_of_stock' || item.type === 'coming_soon') {\r\n <button class=\"btn\" [ngClass]=\"isCollection ? 'px-2 w-100 d-sm-block' : 'py-2 px-4'\">\r\n @if(isCollection){\r\n <span>{{ item.name | uppercase }} </span>\r\n }@else {\r\n {{ item.name | uppercase }}\r\n }\r\n </button>}\r\n <!-- Caso 2: Contacto por WhatsApp -->\r\n @if (item.type === 'whatsapp_contact') {\r\n <button class=\"btn\" [ngClass]=\"isCollection ? 'px-2 w-100 d-sm-block' : 'py-2 px-4'\"\r\n (click)=\"openWhatsApp(item.whatsappContact)\">\r\n @if(isCollection){\r\n <span>{{ item.name | uppercase }}</span>\r\n }@else {\r\n {{ item.name | uppercase }}\r\n }\r\n\r\n </button>\r\n }\r\n <!-- Caso 3: Solicitar m\u00E1s informaci\u00F3n -->\r\n @if (item.type === 'more_info') {\r\n <button *ngIf=\"\" class=\"btn\" [ngClass]=\"isCollection ? 'px-2 w-100 d-sm-block' : 'py-2 px-4'\">\r\n @if(isCollection){\r\n <span>{{ item.name | uppercase }}</span>\r\n }@else {\r\n {{ item.name | uppercase }}\r\n }\r\n </button>\r\n }\r\n\r\n }\r\n }\r\n\r\n <!-- </ng-container>\r\n <ng-template #noStock>\r\n <button class=\"btn\" [ngClass]=\"isCollection ? 'px-2 w-100 d-sm-block' : 'py-2 px-4'\">\r\n <ng-container *ngIf=\"isCollection; else normalText\">\r\n <span>{{(\"out-of-stock-short\" | translate) | uppercase}}</span>\r\n </ng-container>\r\n <ng-template #normalText>\r\n {{(\"out-of-stock-short\" | translate) | uppercase}}\r\n </ng-template>\r\n </button>\r\n </ng-template> -->\r\n </div>\r\n</a>" }]
|
|
6055
|
+
args: [{ selector: 'app-product-ec', standalone: true, imports: [CommonModule, PriceEcComponent, RouterLink, TranslateModule], template: "<a [routerLink]=\"['/product', product.id]\" class=\"text-decoration-none producto\">\r\n <!-- Marca especial y descuento -->\r\n <!-- <div *ngIf=\"product.saleprice || (product.special_mark && product.special_mark !== null && product.special_mark !== undefined && product.special_mark.length >0)\"\r\n class=\"marcas\">\r\n <div *ecProductStock=\"product\" [ecProductMini]=\"product.special_mark\"></div>\r\n <ng-container *ngIf=\"shouldShowPrice\">\r\n <div *ecProductStock=\"product\" [ngClass]=\"{'tag-dsc float-right': product.saleprice}\"\r\n [ecProductOff]=\"product\">\r\n </div>\r\n </ng-container>\r\n </div> -->\r\n\r\n <!-- Imagen del producto -->\r\n <div class=\"foto\">\r\n @if(product.picturesdefault){\r\n @if (product.picturesdefault && product.picturesdefault.length > 1 ) {\r\n <img [src]=\"mediaUrl + product.picturesdefault[0]\" alt=\"Imagen principal\" class=\"w-100 pic01\" />\r\n <img [src]=\"mediaUrl + product.picturesdefault[1]\" alt=\"Imagen secundaria\" class=\"w-100 pic02\" />\r\n } @else {\r\n <img [src]=\"mediaUrl + product.picturesdefault[0]\" alt=\"Imagen principal\" class=\"w-100 pic01\" />\r\n }\r\n }\r\n </div>\r\n <!-- Precio -->\r\n \r\n\r\n <!-- Nombre del producto -->\r\n <h6 class=\"title\">{{ product.name | titlecase }}</h6>\r\n\r\n <div class=\"sku\" [innerHTML]=\"product.shortdetails\"></div>\r\n \r\n @if (shouldShowPrice) {\r\n <app-price-ec [price]=\"product.price\" [saleprice]=\"product.saleprice\" class=\"\" />\r\n }@else {\r\n <p class=\"noPrice\"></p>\r\n }\r\n\r\n <div class=\"fixBottom\">\r\n\r\n <!-- Bot\u00F3n de acciones -->\r\n <!-- <ng-container *ecProductStock=\"product; else noStock\"> -->\r\n <!-- Cuando no tiene marca especial o es de tipo 'standard' -->\r\n @if (!product.special_mark || product.special_mark.length === 0 || product.special_mark[0]?.type ===\r\n 'standard') {\r\n <button class=\"btn\" [ngClass]=\"isCollection ? 'px-2 w-100 d-sm-block' : 'py-2 px-4'\">\r\n <ng-container *ngIf=\"isCollection; else normalText\">\r\n <span> {{(\"buy\" | translate) | uppercase}} </span>\r\n </ng-container>\r\n <ng-template #normalText>\r\n {{(\"buy\" | translate) | uppercase}}\r\n </ng-template>\r\n </button>\r\n }\r\n <!-- Cuando tiene marca especial y el tipo no es 'standard' -->\r\n @if(product.special_mark?.[0]?.type !== 'standard'){\r\n @for (item of product.special_mark; track $index) {\r\n <!-- Caso 1: Agotado o Disponible muy pronto -->\r\n @if (item.type === 'out_of_stock' || item.type === 'coming_soon') {\r\n <button class=\"btn\" [ngClass]=\"isCollection ? 'px-2 w-100 d-sm-block' : 'py-2 px-4'\">\r\n @if(isCollection){\r\n <span>{{ item.name | uppercase }} </span>\r\n }@else {\r\n {{ item.name | uppercase }}\r\n }\r\n </button>}\r\n <!-- Caso 2: Contacto por WhatsApp -->\r\n @if (item.type === 'whatsapp_contact') {\r\n <button class=\"btn\" [ngClass]=\"isCollection ? 'px-2 w-100 d-sm-block' : 'py-2 px-4'\"\r\n (click)=\"openWhatsApp(item.whatsappContact)\">\r\n @if(isCollection){\r\n <span>{{ item.name | uppercase }}</span>\r\n }@else {\r\n {{ item.name | uppercase }}\r\n }\r\n\r\n </button>\r\n }\r\n <!-- Caso 3: Solicitar m\u00E1s informaci\u00F3n -->\r\n @if (item.type === 'more_info') {\r\n <button *ngIf=\"\" class=\"btn\" [ngClass]=\"isCollection ? 'px-2 w-100 d-sm-block' : 'py-2 px-4'\">\r\n @if(isCollection){\r\n <span>{{ item.name | uppercase }}</span>\r\n }@else {\r\n {{ item.name | uppercase }}\r\n }\r\n </button>\r\n }\r\n\r\n }\r\n }\r\n\r\n <!-- </ng-container>\r\n <ng-template #noStock>\r\n <button class=\"btn\" [ngClass]=\"isCollection ? 'px-2 w-100 d-sm-block' : 'py-2 px-4'\">\r\n <ng-container *ngIf=\"isCollection; else normalText\">\r\n <span>{{(\"out-of-stock-short\" | translate) | uppercase}}</span>\r\n </ng-container>\r\n <ng-template #normalText>\r\n {{(\"out-of-stock-short\" | translate) | uppercase}}\r\n </ng-template>\r\n </button>\r\n </ng-template> -->\r\n </div>\r\n</a>" }]
|
|
6048
6056
|
}], propDecorators: { product: [{
|
|
6049
6057
|
type: Input,
|
|
6050
6058
|
args: [{
|
|
@@ -6099,7 +6107,7 @@ class BlockProductsEcComponent extends BlockEcComponent {
|
|
|
6099
6107
|
slidesPerView: 2
|
|
6100
6108
|
},
|
|
6101
6109
|
768: {
|
|
6102
|
-
slidesPerView:
|
|
6110
|
+
slidesPerView: 3,
|
|
6103
6111
|
},
|
|
6104
6112
|
992: {
|
|
6105
6113
|
slidesPerView: 4,
|
|
@@ -6139,11 +6147,11 @@ class BlockProductsEcComponent extends BlockEcComponent {
|
|
|
6139
6147
|
this.analyticsService.callEvent('select_promotion', item);
|
|
6140
6148
|
}
|
|
6141
6149
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: BlockProductsEcComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
6142
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.0", type: BlockProductsEcComponent, isStandalone: true, selector: "app-block-products-ec", inputs: { appProduct: "appProduct", products: "products", meta: "meta" }, usesInheritance: true, ngImport: i0, template: "<section [ngClass]=\"trimClassBlock(meta.code) + ' container-fluid'\">\r\n\r\n <div class=\"blockProduct block-product\">\r\n @if(meta.name){\r\n
|
|
6150
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.0", type: BlockProductsEcComponent, isStandalone: true, selector: "app-block-products-ec", inputs: { appProduct: "appProduct", products: "products", meta: "meta" }, usesInheritance: true, ngImport: i0, template: "<section [ngClass]=\"trimClassBlock(meta.code) + ' container-fluid'\">\r\n\r\n <div class=\"blockProduct block-product\">\r\n @if(meta.name){\r\n <div class=\"row\">\r\n <div class=\"col-12 mt-4\">\r\n <h2 class=\"font-weight-normal font-gd\">\r\n <span>{{meta.name}}</span>\r\n </h2>\r\n </div>\r\n </div>\r\n }\r\n\r\n\r\n @if(meta.styles && meta.styles.carrousel == false){\r\n <div class=\"row \">\r\n @for (product of products; track $index) {\r\n <div [class]=\"'item '+ ' col-'+ (meta.styles.items?.sm) + ' col-md-' + (meta.styles.items?.md) + ' col-lg-' + (meta.styles.items?.lg) + ' px-2'\" [id]=\"$index\">\r\n <!-- verifica que si vienen un template para un custom appProduct llamado \"appProduct\" con un objeto \"product\"- sino usa por defecto el del core -->\r\n <ng-container *ngTemplateOutlet=\"appProduct ? appProduct : defaultAppProduct; context: {product:product}\"></ng-container>\r\n </div>\r\n }\r\n </div>\r\n } @else {\r\n <div class=\"container\">\r\n <swiper-container init=\"false\" [id]=\"meta?.code\">\r\n @for (product of products; track $index) {\r\n <swiper-slide id=\"swiper-slide\">\r\n <ng-container\r\n *ngTemplateOutlet=\"appProduct ? appProduct : defaultAppProduct; context: {product:product}\"></ng-container>\r\n </swiper-slide>\r\n }\r\n </swiper-container>\r\n </div>\r\n }\r\n </div>\r\n</section>\r\n\r\n\r\n<!-- componente por defecto (tomara como producto el contexto pasado como \"product\") -->\r\n<ng-template #defaultAppProduct let-product=\"product\">\r\n <app-product-ec [product]=\"product\"></app-product-ec>\r\n</ng-template>", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: ProductEcComponent, selector: "app-product-ec", inputs: ["product", "isProductBox", "isCollection"], outputs: ["loaded"] }] });
|
|
6143
6151
|
}
|
|
6144
6152
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: BlockProductsEcComponent, decorators: [{
|
|
6145
6153
|
type: Component,
|
|
6146
|
-
args: [{ selector: 'app-block-products-ec', standalone: true, imports: [CommonModule, ProductEcComponent], schemas: [CUSTOM_ELEMENTS_SCHEMA], template: "<section [ngClass]=\"trimClassBlock(meta.code) + ' container-fluid'\">\r\n\r\n <div class=\"blockProduct block-product\">\r\n @if(meta.name){\r\n
|
|
6154
|
+
args: [{ selector: 'app-block-products-ec', standalone: true, imports: [CommonModule, ProductEcComponent], schemas: [CUSTOM_ELEMENTS_SCHEMA], template: "<section [ngClass]=\"trimClassBlock(meta.code) + ' container-fluid'\">\r\n\r\n <div class=\"blockProduct block-product\">\r\n @if(meta.name){\r\n <div class=\"row\">\r\n <div class=\"col-12 mt-4\">\r\n <h2 class=\"font-weight-normal font-gd\">\r\n <span>{{meta.name}}</span>\r\n </h2>\r\n </div>\r\n </div>\r\n }\r\n\r\n\r\n @if(meta.styles && meta.styles.carrousel == false){\r\n <div class=\"row \">\r\n @for (product of products; track $index) {\r\n <div [class]=\"'item '+ ' col-'+ (meta.styles.items?.sm) + ' col-md-' + (meta.styles.items?.md) + ' col-lg-' + (meta.styles.items?.lg) + ' px-2'\" [id]=\"$index\">\r\n <!-- verifica que si vienen un template para un custom appProduct llamado \"appProduct\" con un objeto \"product\"- sino usa por defecto el del core -->\r\n <ng-container *ngTemplateOutlet=\"appProduct ? appProduct : defaultAppProduct; context: {product:product}\"></ng-container>\r\n </div>\r\n }\r\n </div>\r\n } @else {\r\n <div class=\"container\">\r\n <swiper-container init=\"false\" [id]=\"meta?.code\">\r\n @for (product of products; track $index) {\r\n <swiper-slide id=\"swiper-slide\">\r\n <ng-container\r\n *ngTemplateOutlet=\"appProduct ? appProduct : defaultAppProduct; context: {product:product}\"></ng-container>\r\n </swiper-slide>\r\n }\r\n </swiper-container>\r\n </div>\r\n }\r\n </div>\r\n</section>\r\n\r\n\r\n<!-- componente por defecto (tomara como producto el contexto pasado como \"product\") -->\r\n<ng-template #defaultAppProduct let-product=\"product\">\r\n <app-product-ec [product]=\"product\"></app-product-ec>\r\n</ng-template>" }]
|
|
6147
6155
|
}], ctorParameters: () => [], propDecorators: { appProduct: [{
|
|
6148
6156
|
type: Input
|
|
6149
6157
|
}], products: [{
|
|
@@ -6947,7 +6955,15 @@ class RegisterFormEcComponent {
|
|
|
6947
6955
|
/**
|
|
6948
6956
|
* Contiene el formulario de registro.
|
|
6949
6957
|
*/
|
|
6950
|
-
|
|
6958
|
+
registerForm = signal(this._formBuilder.group({
|
|
6959
|
+
firstName: ['', Validators.required],
|
|
6960
|
+
lastName: ['', Validators.required],
|
|
6961
|
+
email: ['', [Validators.required, Validators.email]],
|
|
6962
|
+
plainPassword: ['', Validators.required],
|
|
6963
|
+
plainPassword2: ['', Validators.required],
|
|
6964
|
+
newsletter: [false],
|
|
6965
|
+
terms: ['', Validators.required],
|
|
6966
|
+
}));
|
|
6951
6967
|
/**
|
|
6952
6968
|
* Para indicar que se esta procesando la solicitud de registro.
|
|
6953
6969
|
*/
|
|
@@ -6957,15 +6973,6 @@ class RegisterFormEcComponent {
|
|
|
6957
6973
|
*/
|
|
6958
6974
|
success = false;
|
|
6959
6975
|
constructor() {
|
|
6960
|
-
this.form = this._formBuilder.group({
|
|
6961
|
-
firstName: ['', Validators.required],
|
|
6962
|
-
lastName: ['', Validators.required],
|
|
6963
|
-
email: ['', [Validators.required, Validators.email]],
|
|
6964
|
-
plainPassword: ['', Validators.required],
|
|
6965
|
-
plainPassword2: ['', Validators.required],
|
|
6966
|
-
newsletter: [false],
|
|
6967
|
-
terms: ['', Validators.required],
|
|
6968
|
-
});
|
|
6969
6976
|
}
|
|
6970
6977
|
/**
|
|
6971
6978
|
* Registra un usuario.
|
|
@@ -6975,25 +6982,25 @@ class RegisterFormEcComponent {
|
|
|
6975
6982
|
register(event) {
|
|
6976
6983
|
event.preventDefault();
|
|
6977
6984
|
this.loading = true;
|
|
6978
|
-
if (!this.
|
|
6985
|
+
if (!this.registerForm.valid) {
|
|
6979
6986
|
this._toastService.show('fields-incomplete');
|
|
6980
6987
|
this.loading = false;
|
|
6981
6988
|
return;
|
|
6982
6989
|
}
|
|
6983
6990
|
;
|
|
6984
|
-
if (this.
|
|
6991
|
+
if (this.registerForm.value.plainPassword != this.registerForm.value.plainPassword2) {
|
|
6985
6992
|
this._toastService.show('mismatched-password');
|
|
6986
6993
|
this.loading = false;
|
|
6987
6994
|
return;
|
|
6988
6995
|
}
|
|
6989
|
-
if (this.
|
|
6990
|
-
firstValueFrom(this._authService.singUp(this.
|
|
6996
|
+
if (this.registerForm.valid) {
|
|
6997
|
+
firstValueFrom(this._authService.singUp(this.registerForm.value)).then(res => {
|
|
6991
6998
|
this.loading = false;
|
|
6992
6999
|
this._toastService.success('register-ok');
|
|
6993
7000
|
this._analyticsService.callEvent('sign_up', {
|
|
6994
|
-
firstName: this.
|
|
6995
|
-
lastName: this.
|
|
6996
|
-
email: this.
|
|
7001
|
+
firstName: this.registerForm.value.firstName,
|
|
7002
|
+
lastName: this.registerForm.value.lastName,
|
|
7003
|
+
email: this.registerForm.value.email
|
|
6997
7004
|
});
|
|
6998
7005
|
this.success = true;
|
|
6999
7006
|
this.ready.emit(true);
|
|
@@ -7016,11 +7023,11 @@ class RegisterFormEcComponent {
|
|
|
7016
7023
|
}
|
|
7017
7024
|
}
|
|
7018
7025
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: RegisterFormEcComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
7019
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.0", type: RegisterFormEcComponent, isStandalone: true, selector: "app-register-form-ec", inputs: { redirect: "redirect" }, outputs: { ready: "ready" }, ngImport: i0, template: "<div class=\"w-100 pl-md-5 position-relative\" id=\"register\">\r\n <div class=\"py-2\">\r\n <h5>CREAR CUENTA</h5>\r\n </div>\r\n <form id=\"registro\" [formGroup]=\"
|
|
7026
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.0", type: RegisterFormEcComponent, isStandalone: true, selector: "app-register-form-ec", inputs: { redirect: "redirect" }, outputs: { ready: "ready" }, ngImport: i0, template: "<div class=\"w-100 pl-md-5 position-relative\" id=\"register\">\r\n <div class=\"py-2\">\r\n <h5>CREAR CUENTA</h5>\r\n </div>\r\n <form id=\"registro\" [formGroup]=\"registerForm\" (submit)=\"register($event)\">\r\n <div class=\"form-group\">\r\n <label for=\"\" class=\"form-label\">NOMBRE</label>\r\n <input formControlName=\"firstName\" class=\"form-control rounded-0\" type=\"text\" placeholder=\"Nombre\">\r\n </div>\r\n <div class=\"form-group\">\r\n <label for=\"\" class=\"form-label\">APELLIDO</label>\r\n <input formControlName=\"lastName\" class=\"form-control rounded-0\" type=\"text\" placeholder=\"Apellido\">\r\n </div>\r\n <div class=\"form-group\">\r\n <label for=\"\" class=\"\">CORREO ELECTRONICO</label>\r\n <input formControlName=\"email\" email required class=\"form-control rounded-0\" type=\"email\"\r\n placeholder=\"Correo electr\u00F3nico\">\r\n </div>\r\n <div class=\"form-group\">\r\n <label for=\"\" class=\"form-label\">CONTRASE\u00D1A</label>\r\n <input formControlName=\"plainPassword\" required class=\"form-control rounded-0\" type=\"password\"\r\n placeholder=\"Contrase\u00F1a\">\r\n </div>\r\n <div class=\"form-group\">\r\n <label for=\"\" class=\"form-label\">REPETIR CONTRASE\u00D1A</label>\r\n <input formControlName=\"plainPassword2\" required class=\"form-control rounded-0\" type=\"password\"\r\n placeholder=\"Repetir contrase\u00F1a\">\r\n </div>\r\n\r\n <div class=\"custom-control d-flex flex-row form-check custom-checkbox mr-sm-2 mt-4 mb-2\">\r\n <input type=\"checkbox\" formControlName=\"terms\" required class=\"custom-control-input form-check-input\" name=\"Color2\"\r\n id=\"Color2\">\r\n <label class=\"custom-control-label ff-ubuntu-light font-sm form-check-label\" for=\"Color2\"> He\r\n le\u00EDdo y acepto las pol\u00EDticas de privacidad y los t\u00E9rminos y\r\n condiciones</label>\r\n </div>\r\n\r\n <div class=\"custom-control d-flex flex-row form-check custom-checkbox mr-sm-2 mb-4\">\r\n <input type=\"checkbox\" formControlName=\"newsletter\" class=\"custom-control-input form-check-input\" name=\"Color3\" id=\"Color3\">\r\n <label class=\"custom-control-label form-check-label ff-ubuntu-light font-sm\" for=\"Color3\">\r\n Suscripci\u00F3n al Newsletter</label>\r\n </div>\r\n\r\n <div class=\"row\">\r\n <div class=\"col-12\">\r\n <button [disabled]=\"registerForm.invalid\" type=\"submit\"\r\n class=\"btn btn-primary px-5 py-2 h-fit\">CREAR</button>\r\n </div>\r\n </div>\r\n </form>\r\n @if(loading){\r\n <app-loading-section-ec />\r\n }\r\n \r\n</div>\r\n", styles: [""], dependencies: [{ kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1$3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$3.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i1$3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$3.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i1$3.CheckboxRequiredValidator, selector: "input[type=checkbox][required][formControlName],input[type=checkbox][required][formControl],input[type=checkbox][required][ngModel]" }, { kind: "directive", type: i1$3.EmailValidator, selector: "[email][formControlName],[email][formControl],[email][ngModel]", inputs: ["email"] }, { kind: "directive", type: i1$3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$3.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: LoadingSectionEcComponent, selector: "app-loading-section-ec" }] });
|
|
7020
7027
|
}
|
|
7021
7028
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: RegisterFormEcComponent, decorators: [{
|
|
7022
7029
|
type: Component,
|
|
7023
|
-
args: [{ selector: 'app-register-form-ec', standalone: true, imports: [ReactiveFormsModule, LoadingSectionEcComponent], template: "<div class=\"w-100 pl-md-5 position-relative\" id=\"register\">\r\n <div class=\"py-2\">\r\n <h5>CREAR CUENTA</h5>\r\n </div>\r\n <form id=\"registro\" [formGroup]=\"
|
|
7030
|
+
args: [{ selector: 'app-register-form-ec', standalone: true, imports: [ReactiveFormsModule, LoadingSectionEcComponent], template: "<div class=\"w-100 pl-md-5 position-relative\" id=\"register\">\r\n <div class=\"py-2\">\r\n <h5>CREAR CUENTA</h5>\r\n </div>\r\n <form id=\"registro\" [formGroup]=\"registerForm\" (submit)=\"register($event)\">\r\n <div class=\"form-group\">\r\n <label for=\"\" class=\"form-label\">NOMBRE</label>\r\n <input formControlName=\"firstName\" class=\"form-control rounded-0\" type=\"text\" placeholder=\"Nombre\">\r\n </div>\r\n <div class=\"form-group\">\r\n <label for=\"\" class=\"form-label\">APELLIDO</label>\r\n <input formControlName=\"lastName\" class=\"form-control rounded-0\" type=\"text\" placeholder=\"Apellido\">\r\n </div>\r\n <div class=\"form-group\">\r\n <label for=\"\" class=\"\">CORREO ELECTRONICO</label>\r\n <input formControlName=\"email\" email required class=\"form-control rounded-0\" type=\"email\"\r\n placeholder=\"Correo electr\u00F3nico\">\r\n </div>\r\n <div class=\"form-group\">\r\n <label for=\"\" class=\"form-label\">CONTRASE\u00D1A</label>\r\n <input formControlName=\"plainPassword\" required class=\"form-control rounded-0\" type=\"password\"\r\n placeholder=\"Contrase\u00F1a\">\r\n </div>\r\n <div class=\"form-group\">\r\n <label for=\"\" class=\"form-label\">REPETIR CONTRASE\u00D1A</label>\r\n <input formControlName=\"plainPassword2\" required class=\"form-control rounded-0\" type=\"password\"\r\n placeholder=\"Repetir contrase\u00F1a\">\r\n </div>\r\n\r\n <div class=\"custom-control d-flex flex-row form-check custom-checkbox mr-sm-2 mt-4 mb-2\">\r\n <input type=\"checkbox\" formControlName=\"terms\" required class=\"custom-control-input form-check-input\" name=\"Color2\"\r\n id=\"Color2\">\r\n <label class=\"custom-control-label ff-ubuntu-light font-sm form-check-label\" for=\"Color2\"> He\r\n le\u00EDdo y acepto las pol\u00EDticas de privacidad y los t\u00E9rminos y\r\n condiciones</label>\r\n </div>\r\n\r\n <div class=\"custom-control d-flex flex-row form-check custom-checkbox mr-sm-2 mb-4\">\r\n <input type=\"checkbox\" formControlName=\"newsletter\" class=\"custom-control-input form-check-input\" name=\"Color3\" id=\"Color3\">\r\n <label class=\"custom-control-label form-check-label ff-ubuntu-light font-sm\" for=\"Color3\">\r\n Suscripci\u00F3n al Newsletter</label>\r\n </div>\r\n\r\n <div class=\"row\">\r\n <div class=\"col-12\">\r\n <button [disabled]=\"registerForm.invalid\" type=\"submit\"\r\n class=\"btn btn-primary px-5 py-2 h-fit\">CREAR</button>\r\n </div>\r\n </div>\r\n </form>\r\n @if(loading){\r\n <app-loading-section-ec />\r\n }\r\n \r\n</div>\r\n" }]
|
|
7024
7031
|
}], ctorParameters: () => [], propDecorators: { redirect: [{
|
|
7025
7032
|
type: Input
|
|
7026
7033
|
}], ready: [{
|
|
@@ -7179,7 +7186,7 @@ class FiltersEcComponent {
|
|
|
7179
7186
|
priceGapPercentage = 0.1;
|
|
7180
7187
|
constructor() {
|
|
7181
7188
|
this.filter$.subscribe(res => {
|
|
7182
|
-
|
|
7189
|
+
console.log("filters", res);
|
|
7183
7190
|
});
|
|
7184
7191
|
}
|
|
7185
7192
|
getSpecificFilter(type) {
|
|
@@ -7362,8 +7369,14 @@ class ProductDetailEcComponent {
|
|
|
7362
7369
|
this._meta.updateTag({ property: 'og:url', content: currentUrl });
|
|
7363
7370
|
this._meta.updateTag({ property: 'og:type', content: 'product' });
|
|
7364
7371
|
}
|
|
7372
|
+
decodeHtml(html) {
|
|
7373
|
+
const txt = document.createElement('textarea');
|
|
7374
|
+
txt.innerHTML = html;
|
|
7375
|
+
return txt.value;
|
|
7376
|
+
}
|
|
7365
7377
|
sanitizedHtml(html) {
|
|
7366
|
-
|
|
7378
|
+
const decodedHtml = this.decodeHtml(html);
|
|
7379
|
+
return this._domSanitizer.bypassSecurityTrustHtml(decodedHtml);
|
|
7367
7380
|
}
|
|
7368
7381
|
addToCart() {
|
|
7369
7382
|
this.quantity() > 0 && this._productDetailService.addToCart(this.quantity());
|
|
@@ -7422,11 +7435,11 @@ class VariantsEcComponent {
|
|
|
7422
7435
|
this._productDetailsService.setOption(optionCode, optionValue);
|
|
7423
7436
|
}
|
|
7424
7437
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: VariantsEcComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
7425
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.0", type: VariantsEcComponent, isStandalone: true, selector: "app-variants-ec", ngImport: i0, template: "@if(options$ | async; as options){\r\n@if(options && options.length){\r\n@for(option of options; track $index){\r\n@switch (option.type) {\r\n@case ('color') {\r\n<h5>Colores disponibles</h5>\r\n<div class=\"row w-100 mx-auto pb-3 mb-3\">\r\n @for(value of option.values; track $index; let x = $index){\r\n <a role=\"button\" [title]=\"value.description\" (click)=\"setOption(option.code, value.name)\"\r\n [class]=\"'item m-1 circle ' + (value.selected ? 'shadow' : '')\" [id]=\"x + value.name\"\r\n [style.background]=\"'#' + value.name\" [style.box-shadow]=\"(value.selected ? '0px 0px 0px 2px #000' : 'none')\">\r\n </a>\r\n }\r\n</div>\r\n}\r\n@case ('size') {\r\n<h5>Talles displonibles</h5>\r\n<div class=\"row w-100 mx-auto pb-3\">\r\n @for(value of option.values; track $index; let x = $index){\r\n <a role=\"buttom\" (click)=\"setOption(option.code, value.name)\" [id]=\"x + value.name\"\r\n [class]=\"'btn item m-1 ' + (value.selected ? 'selected-size' : 'unselected-size')\">\r\n {{ value.name }}\r\n </a>\r\n }\r\n\r\n</div>\r\n}\r\n@default {\r\n\r\n}\r\n}\r\n}\r\n}\r\n}
|
|
7438
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.0", type: VariantsEcComponent, isStandalone: true, selector: "app-variants-ec", ngImport: i0, template: "@if(options$ | async; as options){\r\n@if(options && options.length ){\r\n@for(option of options; track $index){\r\n@switch (option.type) {\r\n@case ('color') {\r\n@if(option.values && option.values.length > 1) {\r\n<h5>Colores disponibles</h5>\r\n<div class=\"row w-100 mx-auto pb-3 mb-3\">\r\n @for(value of option.values; track $index; let x = $index){\r\n <a role=\"button\" [title]=\"value.description\" (click)=\"setOption(option.code, value.name)\"\r\n [class]=\"'item m-1 circle ' + (value.selected ? 'shadow' : '')\" [id]=\"x + value.name\"\r\n [style.background]=\"'#' + value.name\" [style.box-shadow]=\"(value.selected ? '0px 0px 0px 2px #000' : 'none')\">\r\n </a>\r\n }\r\n</div>\r\n}\r\n}\r\n@case ('size') {\r\n@if(option.values && option.values.length > 1) {\r\n<h5>Talles displonibles</h5>\r\n<div class=\"row w-100 mx-auto pb-3\">\r\n @for(value of option.values; track $index; let x = $index){\r\n <a role=\"buttom\" (click)=\"setOption(option.code, value.name)\" [id]=\"x + value.name\"\r\n [class]=\"'btn item m-1 ' + (value.selected ? 'selected-size' : 'unselected-size')\">\r\n {{ value.name }}\r\n </a>\r\n }\r\n\r\n</div>\r\n}\r\n}\r\n@default {\r\n\r\n}\r\n}\r\n}\r\n}\r\n}", styles: [".circle{width:32px;height:32px;border-radius:50%}.shadow{border:1px solid #000}\n"], dependencies: [{ kind: "pipe", type: AsyncPipe, name: "async" }] });
|
|
7426
7439
|
}
|
|
7427
7440
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: VariantsEcComponent, decorators: [{
|
|
7428
7441
|
type: Component,
|
|
7429
|
-
args: [{ selector: 'app-variants-ec', standalone: true, imports: [AsyncPipe], template: "@if(options$ | async; as options){\r\n@if(options && options.length){\r\n@for(option of options; track $index){\r\n@switch (option.type) {\r\n@case ('color') {\r\n<h5>Colores disponibles</h5>\r\n<div class=\"row w-100 mx-auto pb-3 mb-3\">\r\n @for(value of option.values; track $index; let x = $index){\r\n <a role=\"button\" [title]=\"value.description\" (click)=\"setOption(option.code, value.name)\"\r\n [class]=\"'item m-1 circle ' + (value.selected ? 'shadow' : '')\" [id]=\"x + value.name\"\r\n [style.background]=\"'#' + value.name\" [style.box-shadow]=\"(value.selected ? '0px 0px 0px 2px #000' : 'none')\">\r\n </a>\r\n }\r\n</div>\r\n}\r\n@case ('size') {\r\n<h5>Talles displonibles</h5>\r\n<div class=\"row w-100 mx-auto pb-3\">\r\n @for(value of option.values; track $index; let x = $index){\r\n <a role=\"buttom\" (click)=\"setOption(option.code, value.name)\" [id]=\"x + value.name\"\r\n [class]=\"'btn item m-1 ' + (value.selected ? 'selected-size' : 'unselected-size')\">\r\n {{ value.name }}\r\n </a>\r\n }\r\n\r\n</div>\r\n}\r\n@default {\r\n\r\n}\r\n}\r\n}\r\n}\r\n}
|
|
7442
|
+
args: [{ selector: 'app-variants-ec', standalone: true, imports: [AsyncPipe], template: "@if(options$ | async; as options){\r\n@if(options && options.length ){\r\n@for(option of options; track $index){\r\n@switch (option.type) {\r\n@case ('color') {\r\n@if(option.values && option.values.length > 1) {\r\n<h5>Colores disponibles</h5>\r\n<div class=\"row w-100 mx-auto pb-3 mb-3\">\r\n @for(value of option.values; track $index; let x = $index){\r\n <a role=\"button\" [title]=\"value.description\" (click)=\"setOption(option.code, value.name)\"\r\n [class]=\"'item m-1 circle ' + (value.selected ? 'shadow' : '')\" [id]=\"x + value.name\"\r\n [style.background]=\"'#' + value.name\" [style.box-shadow]=\"(value.selected ? '0px 0px 0px 2px #000' : 'none')\">\r\n </a>\r\n }\r\n</div>\r\n}\r\n}\r\n@case ('size') {\r\n@if(option.values && option.values.length > 1) {\r\n<h5>Talles displonibles</h5>\r\n<div class=\"row w-100 mx-auto pb-3\">\r\n @for(value of option.values; track $index; let x = $index){\r\n <a role=\"buttom\" (click)=\"setOption(option.code, value.name)\" [id]=\"x + value.name\"\r\n [class]=\"'btn item m-1 ' + (value.selected ? 'selected-size' : 'unselected-size')\">\r\n {{ value.name }}\r\n </a>\r\n }\r\n\r\n</div>\r\n}\r\n}\r\n@default {\r\n\r\n}\r\n}\r\n}\r\n}\r\n}", styles: [".circle{width:32px;height:32px;border-radius:50%}.shadow{border:1px solid #000}\n"] }]
|
|
7430
7443
|
}] });
|
|
7431
7444
|
|
|
7432
7445
|
class BreadcrumbEcComponent {
|
|
@@ -8635,11 +8648,11 @@ class SidebarEcComponent {
|
|
|
8635
8648
|
throw new Error('Method not implemented.');
|
|
8636
8649
|
}
|
|
8637
8650
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: SidebarEcComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
8638
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.0", type: SidebarEcComponent, isStandalone: true, selector: "app-sidebar-ec", ngImport: i0, template: "<div class=\"nav my-4 mx-0 position-relative text-center shadow-sm border-bottom d-flex justify-content-center\">\r\n <h2 class=\"row text-center\">Mi carrito</h2>\r\n <div class=\" me-3 closeCart position-absolute end-0\" data-bs-dismiss=\"offcanvas\" aria-label=\"Close\">\r\n <i class=\"fa fa-times-circle fs-5\" aria-hidden=\"true\"></i>\r\n </div>\r\n</div>\r\n\r\n\r\n@if(cartItems$ | async; as items){\r\n @if(items.length > 0){\r\n <!-- PRODUCTO -->\r\n <div class=\"d-flex flex-column mb-4 items\">\r\n @for(item of items; track $index; let i = $index){\r\n <div class=\"productoCarrito mt-1 mb-2 w-100\">\r\n <app-cart-item-ec [inSidebar]=\"true\" [item]=\"item\"></app-cart-item-ec>\r\n </div>\r\n }\r\n </div>\r\n <div class=\"d-flex mx-4 justify-content-between border-top \">\r\n <p>Subtotal</p>\r\n <p class=\"fw-700\">{{ (subTotalAmount$ | async) | ecCurrencySymbol}}</p>\r\n </div>\r\n <div class=\"mx-4 bordeBot\">\r\n <app-coupon-ec></app-coupon-ec>\r\n </div>\r\n <div class=\"d-flex mx-4 justify-content-between bordeBot2\">\r\n <p>Descuentos:</p>\r\n <p>{{ (totalPromotionAmount$ | async) |ecCurrencySymbol }}</p>\r\n </div>\r\n\r\n <div class=\"d-flex mx-4 justify-content-between bordeBot2\">\r\n <!-- @if(this._cartService.cart.source.value.couponCode){\r\n <a class=\"quitar-cupon text-dark\" role=\"button\"\r\n (click)=\"removeCoupon()\">(Quitar cup\u00F3n)</a>\r\n } -->\r\n </div>\r\n <div class=\"d-flex mx-4 justify-content-between mb-3 mt-2\">\r\n <p class=\"fw-bold h5\">TOTAL</p>\r\n <p class=\"fw-bold h5\">{{(totalAmount$ | async) | ecCurrencySymbol}}</p>\r\n </div>\r\n <div class=\"d-flex flex-column mx-4 justify-content-between mb-3\" data-bs-dismiss=\"offcanvas\" aria-label=\"Close\">\r\n <a [routerLink]=\"['/cart']\" class=\"btn
|
|
8651
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.0", type: SidebarEcComponent, isStandalone: true, selector: "app-sidebar-ec", ngImport: i0, template: "<div class=\"nav my-4 mx-0 position-relative text-center shadow-sm border-bottom d-flex justify-content-center\">\r\n <h2 class=\"row text-center\">Mi carrito</h2>\r\n <div class=\" me-3 closeCart position-absolute end-0\" data-bs-dismiss=\"offcanvas\" aria-label=\"Close\">\r\n <i class=\"fa fa-times-circle fs-5\" aria-hidden=\"true\"></i>\r\n </div>\r\n</div>\r\n\r\n\r\n@if(cartItems$ | async; as items){\r\n @if(items.length > 0){\r\n <!-- PRODUCTO -->\r\n <div class=\"d-flex flex-column mb-4 items\">\r\n @for(item of items; track $index; let i = $index){\r\n <div class=\"productoCarrito mt-1 mb-2 w-100\">\r\n <app-cart-item-ec [inSidebar]=\"true\" [item]=\"item\"></app-cart-item-ec>\r\n </div>\r\n }\r\n </div>\r\n <div class=\"d-flex mx-4 justify-content-between border-top \">\r\n <p>Subtotal</p>\r\n <p class=\"fw-700\">{{ (subTotalAmount$ | async) | ecCurrencySymbol}}</p>\r\n </div>\r\n <div class=\"mx-4 bordeBot\">\r\n <app-coupon-ec></app-coupon-ec>\r\n </div>\r\n <div class=\"d-flex mx-4 justify-content-between bordeBot2\">\r\n <p>Descuentos:</p>\r\n <p>{{ (totalPromotionAmount$ | async) |ecCurrencySymbol }}</p>\r\n </div>\r\n\r\n <div class=\"d-flex mx-4 justify-content-between bordeBot2\">\r\n <!-- @if(this._cartService.cart.source.value.couponCode){\r\n <a class=\"quitar-cupon text-dark\" role=\"button\"\r\n (click)=\"removeCoupon()\">(Quitar cup\u00F3n)</a>\r\n } -->\r\n </div>\r\n <div class=\"d-flex mx-4 justify-content-between mb-3 mt-2\">\r\n <p class=\"fw-bold h5\">TOTAL</p>\r\n <p class=\"fw-bold h5\">{{(totalAmount$ | async) | ecCurrencySymbol}}</p>\r\n </div>\r\n <div class=\"d-flex flex-column mx-4 justify-content-between mb-3\" data-bs-dismiss=\"offcanvas\" aria-label=\"Close\">\r\n <a [routerLink]=\"['/cart']\" class=\"btn btnPedido mb-2\">FINALIZAR PEDIDO</a>\r\n <a [routerLink]=\"['/collection']\" class=\"btn btnSeguir mb-3\">SEGUIR COMPRANDO</a>\r\n </div>\r\n\r\n\r\n } @else {\r\n <div class=\"container-lg px-lg-0 px-md-4 my-5\">\r\n <div class=\"row\">\r\n <div class=\"col-12\">\r\n <h5 class=\"text-center mb-sm-4 text-uppercase\"> \u00B7 Su carrito se\r\n encuentra vac\u00EDo \u00B7 </h5>\r\n </div>\r\n </div>\r\n </div>\r\n }\r\n}", styles: [""], dependencies: [{ kind: "directive", type: RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "component", type: CouponEcComponent, selector: "app-coupon-ec" }, { kind: "component", type: CartItemEcComponent, selector: "app-cart-item-ec", inputs: ["item", "inSidebar"] }, { kind: "pipe", type: EcCurrencySymbolPipe, name: "ecCurrencySymbol" }] });
|
|
8639
8652
|
}
|
|
8640
8653
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: SidebarEcComponent, decorators: [{
|
|
8641
8654
|
type: Component,
|
|
8642
|
-
args: [{ selector: 'app-sidebar-ec', standalone: true, imports: [RouterLink, AsyncPipe, CouponEcComponent, CartItemEcComponent, EcCurrencySymbolPipe], template: "<div class=\"nav my-4 mx-0 position-relative text-center shadow-sm border-bottom d-flex justify-content-center\">\r\n <h2 class=\"row text-center\">Mi carrito</h2>\r\n <div class=\" me-3 closeCart position-absolute end-0\" data-bs-dismiss=\"offcanvas\" aria-label=\"Close\">\r\n <i class=\"fa fa-times-circle fs-5\" aria-hidden=\"true\"></i>\r\n </div>\r\n</div>\r\n\r\n\r\n@if(cartItems$ | async; as items){\r\n @if(items.length > 0){\r\n <!-- PRODUCTO -->\r\n <div class=\"d-flex flex-column mb-4 items\">\r\n @for(item of items; track $index; let i = $index){\r\n <div class=\"productoCarrito mt-1 mb-2 w-100\">\r\n <app-cart-item-ec [inSidebar]=\"true\" [item]=\"item\"></app-cart-item-ec>\r\n </div>\r\n }\r\n </div>\r\n <div class=\"d-flex mx-4 justify-content-between border-top \">\r\n <p>Subtotal</p>\r\n <p class=\"fw-700\">{{ (subTotalAmount$ | async) | ecCurrencySymbol}}</p>\r\n </div>\r\n <div class=\"mx-4 bordeBot\">\r\n <app-coupon-ec></app-coupon-ec>\r\n </div>\r\n <div class=\"d-flex mx-4 justify-content-between bordeBot2\">\r\n <p>Descuentos:</p>\r\n <p>{{ (totalPromotionAmount$ | async) |ecCurrencySymbol }}</p>\r\n </div>\r\n\r\n <div class=\"d-flex mx-4 justify-content-between bordeBot2\">\r\n <!-- @if(this._cartService.cart.source.value.couponCode){\r\n <a class=\"quitar-cupon text-dark\" role=\"button\"\r\n (click)=\"removeCoupon()\">(Quitar cup\u00F3n)</a>\r\n } -->\r\n </div>\r\n <div class=\"d-flex mx-4 justify-content-between mb-3 mt-2\">\r\n <p class=\"fw-bold h5\">TOTAL</p>\r\n <p class=\"fw-bold h5\">{{(totalAmount$ | async) | ecCurrencySymbol}}</p>\r\n </div>\r\n <div class=\"d-flex flex-column mx-4 justify-content-between mb-3\" data-bs-dismiss=\"offcanvas\" aria-label=\"Close\">\r\n <a [routerLink]=\"['/cart']\" class=\"btn
|
|
8655
|
+
args: [{ selector: 'app-sidebar-ec', standalone: true, imports: [RouterLink, AsyncPipe, CouponEcComponent, CartItemEcComponent, EcCurrencySymbolPipe], template: "<div class=\"nav my-4 mx-0 position-relative text-center shadow-sm border-bottom d-flex justify-content-center\">\r\n <h2 class=\"row text-center\">Mi carrito</h2>\r\n <div class=\" me-3 closeCart position-absolute end-0\" data-bs-dismiss=\"offcanvas\" aria-label=\"Close\">\r\n <i class=\"fa fa-times-circle fs-5\" aria-hidden=\"true\"></i>\r\n </div>\r\n</div>\r\n\r\n\r\n@if(cartItems$ | async; as items){\r\n @if(items.length > 0){\r\n <!-- PRODUCTO -->\r\n <div class=\"d-flex flex-column mb-4 items\">\r\n @for(item of items; track $index; let i = $index){\r\n <div class=\"productoCarrito mt-1 mb-2 w-100\">\r\n <app-cart-item-ec [inSidebar]=\"true\" [item]=\"item\"></app-cart-item-ec>\r\n </div>\r\n }\r\n </div>\r\n <div class=\"d-flex mx-4 justify-content-between border-top \">\r\n <p>Subtotal</p>\r\n <p class=\"fw-700\">{{ (subTotalAmount$ | async) | ecCurrencySymbol}}</p>\r\n </div>\r\n <div class=\"mx-4 bordeBot\">\r\n <app-coupon-ec></app-coupon-ec>\r\n </div>\r\n <div class=\"d-flex mx-4 justify-content-between bordeBot2\">\r\n <p>Descuentos:</p>\r\n <p>{{ (totalPromotionAmount$ | async) |ecCurrencySymbol }}</p>\r\n </div>\r\n\r\n <div class=\"d-flex mx-4 justify-content-between bordeBot2\">\r\n <!-- @if(this._cartService.cart.source.value.couponCode){\r\n <a class=\"quitar-cupon text-dark\" role=\"button\"\r\n (click)=\"removeCoupon()\">(Quitar cup\u00F3n)</a>\r\n } -->\r\n </div>\r\n <div class=\"d-flex mx-4 justify-content-between mb-3 mt-2\">\r\n <p class=\"fw-bold h5\">TOTAL</p>\r\n <p class=\"fw-bold h5\">{{(totalAmount$ | async) | ecCurrencySymbol}}</p>\r\n </div>\r\n <div class=\"d-flex flex-column mx-4 justify-content-between mb-3\" data-bs-dismiss=\"offcanvas\" aria-label=\"Close\">\r\n <a [routerLink]=\"['/cart']\" class=\"btn btnPedido mb-2\">FINALIZAR PEDIDO</a>\r\n <a [routerLink]=\"['/collection']\" class=\"btn btnSeguir mb-3\">SEGUIR COMPRANDO</a>\r\n </div>\r\n\r\n\r\n } @else {\r\n <div class=\"container-lg px-lg-0 px-md-4 my-5\">\r\n <div class=\"row\">\r\n <div class=\"col-12\">\r\n <h5 class=\"text-center mb-sm-4 text-uppercase\"> \u00B7 Su carrito se\r\n encuentra vac\u00EDo \u00B7 </h5>\r\n </div>\r\n </div>\r\n </div>\r\n }\r\n}" }]
|
|
8643
8656
|
}] });
|
|
8644
8657
|
|
|
8645
8658
|
// export * from './related-products-ec/related-products-ec.component';
|