ng-easycommerce 0.0.688 → 0.0.689
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/README.md +13 -0
- package/assets/docs/SEO.md +174 -0
- package/bundles/ng-easycommerce.umd.js +859 -558
- package/bundles/ng-easycommerce.umd.js.map +1 -1
- package/bundles/ng-easycommerce.umd.min.js +1 -1
- package/bundles/ng-easycommerce.umd.min.js.map +1 -1
- package/esm2015/lib/ec-component/auth-ec/auth-ec.component.js +31 -3
- package/esm2015/lib/ec-component/auth-ec/confirm-account-ec/confirm-account-ec.component.js +14 -3
- package/esm2015/lib/ec-component/auth-ec/forgot-password-ec/forgot-password-ec.component.js +14 -3
- package/esm2015/lib/ec-component/cart-ec/cart-ec.component.js +17 -3
- package/esm2015/lib/ec-component/checkout-ec/checkout-ec.component.js +17 -3
- package/esm2015/lib/ec-component/checkout-ec/dataform-ec/dataform-ec.component.js +3 -3
- package/esm2015/lib/ec-component/collection-ec/collection-ec.component.js +36 -3
- package/esm2015/lib/ec-component/home-ec/home-ec.component.js +14 -3
- package/esm2015/lib/ec-component/password-reset-ec/password-reset-ec.component.js +14 -3
- package/esm2015/lib/ec-component/product-detail-ec/product-detail-ec.component.js +17 -12
- package/esm2015/lib/ec-component/section-container-ec/section-container-ec.component.js +45 -4
- package/esm2015/lib/ec-directive/add-action-redirect.directive.js +35 -13
- package/esm2015/lib/ec-directive/product-off.directive.js +2 -2
- package/esm2015/lib/services/seo.service.js +112 -0
- package/esm2015/public-api.js +2 -1
- package/esm5/lib/ec-component/auth-ec/auth-ec.component.js +31 -3
- package/esm5/lib/ec-component/auth-ec/confirm-account-ec/confirm-account-ec.component.js +14 -3
- package/esm5/lib/ec-component/auth-ec/forgot-password-ec/forgot-password-ec.component.js +14 -3
- package/esm5/lib/ec-component/cart-ec/cart-ec.component.js +17 -3
- package/esm5/lib/ec-component/checkout-ec/checkout-ec.component.js +17 -3
- package/esm5/lib/ec-component/checkout-ec/dataform-ec/dataform-ec.component.js +3 -3
- package/esm5/lib/ec-component/collection-ec/collection-ec.component.js +36 -3
- package/esm5/lib/ec-component/home-ec/home-ec.component.js +14 -3
- package/esm5/lib/ec-component/password-reset-ec/password-reset-ec.component.js +14 -3
- package/esm5/lib/ec-component/product-detail-ec/product-detail-ec.component.js +17 -12
- package/esm5/lib/ec-component/section-container-ec/section-container-ec.component.js +45 -4
- package/esm5/lib/ec-directive/add-action-redirect.directive.js +35 -13
- package/esm5/lib/ec-directive/product-off.directive.js +2 -2
- package/esm5/lib/services/seo.service.js +116 -0
- package/esm5/public-api.js +2 -1
- package/fesm2015/ng-easycommerce.js +855 -559
- package/fesm2015/ng-easycommerce.js.map +1 -1
- package/fesm5/ng-easycommerce.js +860 -560
- package/fesm5/ng-easycommerce.js.map +1 -1
- package/lib/ec-component/auth-ec/auth-ec.component.d.ts +4 -1
- package/lib/ec-component/auth-ec/confirm-account-ec/confirm-account-ec.component.d.ts +3 -1
- package/lib/ec-component/auth-ec/forgot-password-ec/forgot-password-ec.component.d.ts +3 -1
- package/lib/ec-component/cart-ec/cart-ec.component.d.ts +4 -1
- package/lib/ec-component/checkout-ec/checkout-ec.component.d.ts +4 -1
- package/lib/ec-component/collection-ec/collection-ec.component.d.ts +5 -1
- package/lib/ec-component/home-ec/home-ec.component.d.ts +3 -1
- package/lib/ec-component/password-reset-ec/password-reset-ec.component.d.ts +3 -1
- package/lib/ec-component/product-detail-ec/product-detail-ec.component.d.ts +3 -3
- package/lib/ec-component/section-container-ec/section-container-ec.component.d.ts +7 -1
- package/lib/ec-directive/add-action-redirect.directive.d.ts +1 -0
- package/lib/services/seo.service.d.ts +16 -0
- package/ng-easycommerce.metadata.json +1 -1
- package/package.json +1 -1
- package/public-api.d.ts +1 -0
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { OnInit, OnChanges } from '@angular/core';
|
|
2
|
+
import { SeoService } from '../../services/seo.service';
|
|
2
3
|
import { FormBuilder, FormGroup } from '@angular/forms';
|
|
3
4
|
import { ActivatedRoute, Router } from '@angular/router';
|
|
4
5
|
import { AuthService } from '../../services/auth.service';
|
|
@@ -12,6 +13,7 @@ export declare class AuthEcComponent extends ComponentHelper implements OnInit,
|
|
|
12
13
|
protected activatedRoute: ActivatedRoute;
|
|
13
14
|
protected formBuilder: FormBuilder;
|
|
14
15
|
router: Router;
|
|
16
|
+
protected seo: SeoService;
|
|
15
17
|
complete: boolean;
|
|
16
18
|
data: {
|
|
17
19
|
email: any;
|
|
@@ -25,9 +27,10 @@ export declare class AuthEcComponent extends ComponentHelper implements OnInit,
|
|
|
25
27
|
loading: Boolean;
|
|
26
28
|
register_loading: Boolean;
|
|
27
29
|
params: any;
|
|
28
|
-
constructor(authService: AuthService, toastr: ToastService, paramsService: ParametersService, activatedRoute: ActivatedRoute, formBuilder: FormBuilder, router: Router);
|
|
30
|
+
constructor(authService: AuthService, toastr: ToastService, paramsService: ParametersService, activatedRoute: ActivatedRoute, formBuilder: FormBuilder, router: Router, seo: SeoService);
|
|
29
31
|
ngOnInit(): void;
|
|
30
32
|
ngOnChanges(): void;
|
|
33
|
+
private updateSeoForAuthRoute;
|
|
31
34
|
setProp: (prop: any, event: any) => void;
|
|
32
35
|
login: () => void;
|
|
33
36
|
redirectHome: () => void;
|
|
@@ -1,12 +1,14 @@
|
|
|
1
|
+
import { SeoService } from '../../../services/seo.service';
|
|
1
2
|
import { ActivatedRoute } from '@angular/router';
|
|
2
3
|
import { ComponentHelper } from '../../../classes/component-helper';
|
|
3
4
|
import { AuthService } from '../../../services/auth.service';
|
|
4
5
|
export declare class ConfirmAccountEcComponent extends ComponentHelper {
|
|
5
6
|
protected authService: AuthService;
|
|
6
7
|
protected activedRoute: ActivatedRoute;
|
|
8
|
+
protected seo: SeoService;
|
|
7
9
|
ok: Boolean;
|
|
8
10
|
error: Boolean;
|
|
9
|
-
constructor(authService: AuthService, activedRoute: ActivatedRoute);
|
|
11
|
+
constructor(authService: AuthService, activedRoute: ActivatedRoute, seo: SeoService);
|
|
10
12
|
ngOnInit(): void;
|
|
11
13
|
onSuccess: () => void;
|
|
12
14
|
onError: () => void;
|
|
@@ -1,13 +1,15 @@
|
|
|
1
|
+
import { SeoService } from '../../../services/seo.service';
|
|
1
2
|
import { ComponentHelper } from '../../../classes/component-helper';
|
|
2
3
|
import { AuthService } from '../../../services/auth.service';
|
|
3
4
|
import { ToastService } from '../../../utils/toast.service';
|
|
4
5
|
export declare class ForgotPasswordEcComponent extends ComponentHelper {
|
|
5
6
|
protected authService: AuthService;
|
|
6
7
|
protected toastr: ToastService;
|
|
8
|
+
protected seo: SeoService;
|
|
7
9
|
email: string;
|
|
8
10
|
loading: boolean;
|
|
9
11
|
ready: boolean;
|
|
10
|
-
constructor(authService: AuthService, toastr: ToastService);
|
|
12
|
+
constructor(authService: AuthService, toastr: ToastService, seo: SeoService);
|
|
11
13
|
ngOnInit(): void;
|
|
12
14
|
recoverPassword: (event: any) => void;
|
|
13
15
|
processOk: (response: any) => void;
|
|
@@ -11,6 +11,7 @@ import { ToastService } from "../../utils/toast.service";
|
|
|
11
11
|
import { Observable } from "rxjs";
|
|
12
12
|
import { AddressingService } from '../../services/checkout/addressing.service';
|
|
13
13
|
import { ChannelConfigService } from '../../services/channel-config.service';
|
|
14
|
+
import { SeoService } from '../../services/seo.service';
|
|
14
15
|
export declare class CartEcComponent extends ComponentHelper implements OnInit {
|
|
15
16
|
cartService: CartService;
|
|
16
17
|
authService: AuthService;
|
|
@@ -21,6 +22,7 @@ export declare class CartEcComponent extends ComponentHelper implements OnInit {
|
|
|
21
22
|
protected toastrService: ToastService;
|
|
22
23
|
addressingService: AddressingService;
|
|
23
24
|
channelConfigService: ChannelConfigService;
|
|
25
|
+
protected seo: SeoService;
|
|
24
26
|
variantsToShow: string[];
|
|
25
27
|
isLoggedIn: boolean;
|
|
26
28
|
mediaUrl: string;
|
|
@@ -46,10 +48,11 @@ export declare class CartEcComponent extends ComponentHelper implements OnInit {
|
|
|
46
48
|
[key: string]: string;
|
|
47
49
|
};
|
|
48
50
|
supportsUnitPromotionHover: boolean;
|
|
49
|
-
constructor(cartService: CartService, authService: AuthService, consts: Constants, productsService: ProductsService, router: Router, modalService: BsModalService, toastrService: ToastService, addressingService: AddressingService, channelConfigService: ChannelConfigService);
|
|
51
|
+
constructor(cartService: CartService, authService: AuthService, consts: Constants, productsService: ProductsService, router: Router, modalService: BsModalService, toastrService: ToastService, addressingService: AddressingService, channelConfigService: ChannelConfigService, seo: SeoService);
|
|
50
52
|
ngOnChanges(): void;
|
|
51
53
|
updateLoggedIn(): void;
|
|
52
54
|
ngOnInit(): void;
|
|
55
|
+
private updateCartSeo;
|
|
53
56
|
/**
|
|
54
57
|
* Convierte un monto crudo al formato decimal esperado por la UI.
|
|
55
58
|
*
|
|
@@ -13,6 +13,7 @@ import { ChannelConfigService } from '../../services/channel-config.service';
|
|
|
13
13
|
import { CheckoutViewType, Constants } from '../../core.consts';
|
|
14
14
|
import { BsModalService, BsModalRef } from 'ngx-bootstrap/modal';
|
|
15
15
|
import { ShippingPriceDisplayService } from '../../utils/shipping-price-display.service';
|
|
16
|
+
import { SeoService } from '../../services/seo.service';
|
|
16
17
|
export declare class CheckoutEcComponent extends ComponentHelper implements OnInit, AfterViewInit, OnDestroy {
|
|
17
18
|
checkoutService: CheckoutService;
|
|
18
19
|
toastrService: ToastService;
|
|
@@ -24,6 +25,7 @@ export declare class CheckoutEcComponent extends ComponentHelper implements OnIn
|
|
|
24
25
|
private elementRef;
|
|
25
26
|
private modalService;
|
|
26
27
|
private shippingPriceDisplay;
|
|
28
|
+
protected seo: SeoService;
|
|
27
29
|
stepper: Stepper;
|
|
28
30
|
loadingSubject: BehaviorSubject<boolean>;
|
|
29
31
|
canCheckout: boolean;
|
|
@@ -61,7 +63,8 @@ export declare class CheckoutEcComponent extends ComponentHelper implements OnIn
|
|
|
61
63
|
private dataformComponents;
|
|
62
64
|
private paymentComponents;
|
|
63
65
|
private unsavedChangesModal;
|
|
64
|
-
constructor(checkoutService: CheckoutService, toastrService: ToastService, router: Router, cartService: CartService, productsService: ProductsService, channelService: ChannelConfigService, consts: Constants, elementRef: ElementRef, modalService: BsModalService, shippingPriceDisplay: ShippingPriceDisplayService);
|
|
66
|
+
constructor(checkoutService: CheckoutService, toastrService: ToastService, router: Router, cartService: CartService, productsService: ProductsService, channelService: ChannelConfigService, consts: Constants, elementRef: ElementRef, modalService: BsModalService, shippingPriceDisplay: ShippingPriceDisplayService, seo: SeoService);
|
|
67
|
+
private updateCheckoutSeo;
|
|
65
68
|
ngOnInit(): void;
|
|
66
69
|
ngAfterViewInit(): void;
|
|
67
70
|
ngOnDestroy(): void;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { OnInit } from '@angular/core';
|
|
2
|
+
import { SeoService } from '../../services/seo.service';
|
|
2
3
|
import { ActivatedRoute } from '@angular/router';
|
|
3
4
|
import { FilterElement } from '../../interfaces/filter';
|
|
4
5
|
import { Subscription } from 'rxjs';
|
|
@@ -25,6 +26,7 @@ export declare class CollectionEcComponent extends ComponentHelper implements On
|
|
|
25
26
|
cartService: CartService;
|
|
26
27
|
consts: Constants;
|
|
27
28
|
filtersService: FiltersService;
|
|
29
|
+
private seo;
|
|
28
30
|
filters: Filter[];
|
|
29
31
|
filters_top: Filter[];
|
|
30
32
|
private defaultFilters;
|
|
@@ -41,7 +43,7 @@ export declare class CollectionEcComponent extends ComponentHelper implements On
|
|
|
41
43
|
value: any;
|
|
42
44
|
productsWithUniqueVariant: boolean;
|
|
43
45
|
optionsFilters: FilterType[];
|
|
44
|
-
constructor(productsService: ProductsService, paramsSrv: ParametersService, activeRoute: ActivatedRoute, optionsService: OptionsService, authService: AuthService, analyticsService: AnalyticsService, cartService: CartService, consts: Constants, filtersService: FiltersService);
|
|
46
|
+
constructor(productsService: ProductsService, paramsSrv: ParametersService, activeRoute: ActivatedRoute, optionsService: OptionsService, authService: AuthService, analyticsService: AnalyticsService, cartService: CartService, consts: Constants, filtersService: FiltersService, seo: SeoService);
|
|
45
47
|
ngOnInit(): void;
|
|
46
48
|
getProductsAndSubscribe(): void;
|
|
47
49
|
/**
|
|
@@ -64,4 +66,6 @@ export declare class CollectionEcComponent extends ComponentHelper implements On
|
|
|
64
66
|
changeFilter: (e: any) => void;
|
|
65
67
|
addAllProductosToCart: (products?: any) => void;
|
|
66
68
|
getObjectWithVariant: () => ParamsProductsWithUniqueVariant;
|
|
69
|
+
private normalizeSeoBreadcrumbTitle;
|
|
70
|
+
private updateCollectionSeo;
|
|
67
71
|
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { OnInit } from '@angular/core';
|
|
2
|
+
import { SeoService } from '../../services/seo.service';
|
|
2
3
|
import { ComponentHelper } from '../../classes/component-helper';
|
|
3
4
|
import { Constants } from '../../core.consts';
|
|
4
5
|
import { IBlock } from '../../interfaces/block';
|
|
@@ -6,7 +7,8 @@ import { BlocksService } from '../../services/blocks/blocks.service';
|
|
|
6
7
|
export declare class HomeEcComponent extends ComponentHelper implements OnInit {
|
|
7
8
|
blocksService: BlocksService;
|
|
8
9
|
protected consts: Constants;
|
|
9
|
-
|
|
10
|
+
protected seo: SeoService;
|
|
11
|
+
constructor(blocksService: BlocksService, consts: Constants, seo: SeoService);
|
|
10
12
|
ngOnInit(): void;
|
|
11
13
|
getHTMLContent: (block: IBlock) => any;
|
|
12
14
|
noNewsletter: (block: any) => boolean;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { OnInit } from '@angular/core';
|
|
2
|
+
import { SeoService } from '../../services/seo.service';
|
|
2
3
|
import { FormBuilder, FormGroup } from '@angular/forms';
|
|
3
4
|
import { ActivatedRoute, Router } from '@angular/router';
|
|
4
5
|
import { ComponentHelper } from '../../classes/component-helper';
|
|
@@ -10,12 +11,13 @@ export declare class PasswordResetEcComponent extends ComponentHelper implements
|
|
|
10
11
|
protected activedRoute: ActivatedRoute;
|
|
11
12
|
router: Router;
|
|
12
13
|
protected formBuilder: FormBuilder;
|
|
14
|
+
protected seo: SeoService;
|
|
13
15
|
email: string;
|
|
14
16
|
loading: boolean;
|
|
15
17
|
ready: boolean;
|
|
16
18
|
protected token: any;
|
|
17
19
|
formGroup: FormGroup;
|
|
18
|
-
constructor(authService: AuthService, toastr: ToastService, activedRoute: ActivatedRoute, router: Router, formBuilder: FormBuilder);
|
|
20
|
+
constructor(authService: AuthService, toastr: ToastService, activedRoute: ActivatedRoute, router: Router, formBuilder: FormBuilder, seo: SeoService);
|
|
19
21
|
ngOnInit(): void;
|
|
20
22
|
sendNewPassword: (event: any) => void;
|
|
21
23
|
invalidForm: () => boolean;
|
|
@@ -8,7 +8,7 @@ import { OptionsService } from '../../services/options.service';
|
|
|
8
8
|
import { ProductDetailService } from '../../services/products/product-detail.service';
|
|
9
9
|
import { ProductsService } from '../../services/products/products.service';
|
|
10
10
|
import { ToastService } from '../../utils/toast.service';
|
|
11
|
-
import {
|
|
11
|
+
import { SeoService } from '../../services/seo.service';
|
|
12
12
|
import { Injector } from '@angular/core';
|
|
13
13
|
export declare class ProductDetailEcComponent extends ComponentHelper implements OnInit {
|
|
14
14
|
productService: ProductDetailService;
|
|
@@ -20,8 +20,8 @@ export declare class ProductDetailEcComponent extends ComponentHelper implements
|
|
|
20
20
|
analyticsService: AnalyticsService;
|
|
21
21
|
router: Router;
|
|
22
22
|
protected toastrService: ToastService;
|
|
23
|
-
private meta;
|
|
24
23
|
injector: Injector;
|
|
24
|
+
private seo?;
|
|
25
25
|
product: any;
|
|
26
26
|
mediaUrl: any;
|
|
27
27
|
show: boolean;
|
|
@@ -41,7 +41,7 @@ export declare class ProductDetailEcComponent extends ComponentHelper implements
|
|
|
41
41
|
multipleQty: number;
|
|
42
42
|
private prefillSub?;
|
|
43
43
|
contact: ElementRef;
|
|
44
|
-
constructor(productService: ProductDetailService, consts: Constants, activedRoute: ActivatedRoute, cartService: CartService, optionsService: OptionsService, productsService: ProductsService, analyticsService: AnalyticsService, router: Router, toastrService: ToastService,
|
|
44
|
+
constructor(productService: ProductDetailService, consts: Constants, activedRoute: ActivatedRoute, cartService: CartService, optionsService: OptionsService, productsService: ProductsService, analyticsService: AnalyticsService, router: Router, toastrService: ToastService, injector: Injector, seo?: SeoService);
|
|
45
45
|
deleteHTML(cadena: string): string;
|
|
46
46
|
ngOnInit(): void;
|
|
47
47
|
ngOnDestroy(): void;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { OnInit } from '@angular/core';
|
|
2
|
+
import { SeoService } from '../../services/seo.service';
|
|
2
3
|
import { DomSanitizer, SafeHtml } from '@angular/platform-browser';
|
|
3
4
|
import { ActivatedRoute } from '@angular/router';
|
|
4
5
|
import { ToastrService } from 'ngx-toastr';
|
|
@@ -9,14 +10,19 @@ export declare class SectionContainerEcComponent extends ComponentHelper impleme
|
|
|
9
10
|
protected optionsService: OptionsService;
|
|
10
11
|
protected toastrService: ToastrService;
|
|
11
12
|
protected sanitizer: DomSanitizer;
|
|
13
|
+
protected seo: SeoService;
|
|
12
14
|
content_html: SafeHtml;
|
|
13
15
|
loadSection: boolean;
|
|
14
16
|
sanitizeHtml: boolean;
|
|
15
17
|
name: any;
|
|
16
18
|
dataSection: any;
|
|
19
|
+
sectionDescription: string;
|
|
17
20
|
private sections;
|
|
18
|
-
constructor(activatedRoute: ActivatedRoute, optionsService: OptionsService, toastrService: ToastrService, sanitizer: DomSanitizer);
|
|
21
|
+
constructor(activatedRoute: ActivatedRoute, optionsService: OptionsService, toastrService: ToastrService, sanitizer: DomSanitizer, seo: SeoService);
|
|
19
22
|
ngOnInit(): void;
|
|
20
23
|
getSection: (link: any) => void;
|
|
21
24
|
getDataSection: (code: any) => void;
|
|
25
|
+
private stripHTML;
|
|
26
|
+
private formatSectionTitle;
|
|
27
|
+
private updateSectionSeo;
|
|
22
28
|
}
|
|
@@ -22,6 +22,7 @@ export declare class AddActionRedirectDirective implements OnChanges, OnInit, On
|
|
|
22
22
|
ngOnInit(): void;
|
|
23
23
|
ngOnChanges(changes: SimpleChanges): void;
|
|
24
24
|
redirectFromUrl: (evt: any) => void;
|
|
25
|
+
private getAccessibleLabel;
|
|
25
26
|
private isExternalUrl;
|
|
26
27
|
ngOnDestroy(): void;
|
|
27
28
|
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Meta, Title } from '@angular/platform-browser';
|
|
2
|
+
export declare class SeoService {
|
|
3
|
+
private document;
|
|
4
|
+
private platformId;
|
|
5
|
+
private titleService;
|
|
6
|
+
private metaService;
|
|
7
|
+
constructor(document: any, platformId: Object, titleService: Title, metaService: Meta);
|
|
8
|
+
setTitle: (title: string) => void;
|
|
9
|
+
setDescription: (description: string) => void;
|
|
10
|
+
setOgImage: (imageUrl: string) => void;
|
|
11
|
+
setOgType: (type: "product" | "website") => void;
|
|
12
|
+
setCanonical: (url: string) => void;
|
|
13
|
+
setRobots: (content: string) => void;
|
|
14
|
+
setNoIndex: (enabled?: boolean) => void;
|
|
15
|
+
getSiteName: (fallback?: string) => string;
|
|
16
|
+
}
|