simpo-component-library 3.6.641 → 3.6.643
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 +24 -24
- package/esm2022/lib/components/delete-hover-element/delete-hover-element.component.mjs +3 -3
- package/esm2022/lib/components/document/document.component.mjs +3 -3
- package/esm2022/lib/components/image-loading/image-loading.component.mjs +3 -3
- package/esm2022/lib/components/payment-details/payment-details.component.mjs +3 -3
- package/esm2022/lib/constants/business.constant.mjs +1 -1
- package/esm2022/lib/directive/alignment.directive.mjs +1 -1
- package/esm2022/lib/directive/blur-content.directive.mjs +1 -1
- package/esm2022/lib/directive/borderlessImage.directive.mjs +1 -1
- package/esm2022/lib/directive/button-directive.directive.mjs +1 -1
- package/esm2022/lib/directive/button-editor.directive.mjs +1 -1
- package/esm2022/lib/directive/color.directive.mjs +1 -1
- package/esm2022/lib/directive/column-directive.directive.mjs +1 -1
- package/esm2022/lib/directive/container-alignment.directive.mjs +1 -1
- package/esm2022/lib/directive/container-fir.directive.mjs +1 -1
- package/esm2022/lib/directive/content-title-spacing.directive.mjs +1 -1
- package/esm2022/lib/directive/contenteditable.directive.mjs +1 -1
- package/esm2022/lib/directive/corner-directive.mjs +1 -1
- package/esm2022/lib/directive/height.directive.mjs +1 -1
- package/esm2022/lib/directive/hover-animation.directive.mjs +1 -1
- package/esm2022/lib/directive/hoverborder.directive.mjs +1 -1
- package/esm2022/lib/directive/icon-directive.directive.mjs +1 -1
- package/esm2022/lib/directive/image-container.directive.mjs +1 -1
- package/esm2022/lib/directive/image-directive.directive.mjs +1 -1
- package/esm2022/lib/directive/image-editor.directive.mjs +1 -1
- package/esm2022/lib/directive/image-position.directive.mjs +1 -1
- package/esm2022/lib/directive/letters-only.directive.mjs +1 -1
- package/esm2022/lib/directive/merge-header.directive.mjs +1 -1
- package/esm2022/lib/directive/numbers-only.directive.mjs +1 -1
- package/esm2022/lib/directive/position-layout-directive.directive.mjs +1 -1
- package/esm2022/lib/directive/set-dynamic-background.directive.mjs +1 -1
- package/esm2022/lib/directive/spacing-around.directive.mjs +1 -1
- package/esm2022/lib/directive/spacing-horizontal.directive.mjs +1 -1
- package/esm2022/lib/directive/spacing.directive.mjs +1 -1
- package/esm2022/lib/directive/sticky-directive.mjs +1 -1
- package/esm2022/lib/directive/text-background-directive.directive.mjs +1 -1
- package/esm2022/lib/directive/text-size.directive.mjs +1 -1
- package/esm2022/lib/directive/translate-onhover.directive.mjs +1 -1
- package/esm2022/lib/directive/wrap-containers.directive.mjs +1 -1
- package/esm2022/lib/ecommerce/sections/address/address.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/authenticate-user/authenticate-user.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/authentication-required/authentication-required.component.mjs +89 -170
- package/esm2022/lib/ecommerce/sections/authentication-required/authentication-required.model.mjs +1 -1
- package/esm2022/lib/ecommerce/sections/book-appointment/book-appointment.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/book-appointment/book-appointment.model.mjs +1 -1
- package/esm2022/lib/ecommerce/sections/category-product/category-product.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/category-product/category-product.model.mjs +1 -1
- package/esm2022/lib/ecommerce/sections/checkout/checkout.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/checkout/checkout.modal.mjs +1 -1
- package/esm2022/lib/ecommerce/sections/customer-review/customer-review.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/customer-review/customer-review.model.mjs +1 -1
- package/esm2022/lib/ecommerce/sections/enrollment-form/enrollment-form.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/enrollment-form/enrollment-form.model.mjs +1 -1
- package/esm2022/lib/ecommerce/sections/featured-category/featured-category.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/featured-category/featured-category.modal.mjs +1 -1
- package/esm2022/lib/ecommerce/sections/featured-category/featured-collection.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/featured-products/featured-products.modal.mjs +1 -1
- package/esm2022/lib/ecommerce/sections/item-varient/item-varient.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/new-collection/new-collection.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/new-collection/new-collection.modal.mjs +1 -1
- package/esm2022/lib/ecommerce/sections/pagnination/pagnination.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/passbook-transactions/passbook-transactions.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/product-category-list/product-category-list.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/product-category-list/product-category-list.model.mjs +1 -1
- package/esm2022/lib/ecommerce/sections/product-desc/product-desc.component.mjs +12 -18
- package/esm2022/lib/ecommerce/sections/product-desc/product-desc.modal.mjs +1 -1
- package/esm2022/lib/ecommerce/sections/product-list/product-list.component.mjs +17 -74
- package/esm2022/lib/ecommerce/sections/product-list/product-list.modal.mjs +1 -1
- package/esm2022/lib/ecommerce/sections/returns-calculator/returns-calculator.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/returns-calculator/returns-calculator.model.mjs +1 -1
- package/esm2022/lib/ecommerce/sections/scheme-details/scheme-details.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/scheme-selection/scheme-selection.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/schemes/schemes.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/schemes/schemes.component.model.mjs +1 -1
- package/esm2022/lib/ecommerce/sections/small-product-listing/small-product-listing.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/store-list/store-list.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/store-list/store-list.modal.mjs +1 -1
- package/esm2022/lib/ecommerce/sections/store-page/store-page.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/store-page/store-page.model.mjs +1 -1
- package/esm2022/lib/ecommerce/sections/user-basic-info/user-basic-info.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/user-profile/user-profile.component.mjs +1 -1
- package/esm2022/lib/ecommerce/sections/user-profile/user-profile.modal.mjs +1 -1
- package/esm2022/lib/ecommerce/sections/verify-payment/verify-payment.component.mjs +3 -3
- package/esm2022/lib/ecommerce/sections/verify-payment/verify-payment.model.mjs +1 -1
- package/esm2022/lib/ecommerce/sections/whislist/whislist.component.mjs +3 -3
- package/esm2022/lib/ecommerce/styles/BaseCollection.modal.mjs +1 -1
- package/esm2022/lib/ecommerce/styles/Collection.modal.mjs +1 -1
- package/esm2022/lib/ecommerce/styles/OrderedItems.modal.mjs +1 -1
- package/esm2022/lib/ecommerce/styles/PincodeLocation.model.mjs +1 -1
- package/esm2022/lib/ecommerce/styles/PincodeLocationInter.model.mjs +1 -1
- package/esm2022/lib/ecommerce/styles/cart.modal.mjs +1 -1
- package/esm2022/lib/ecommerce/styles/category.modal.mjs +1 -1
- package/esm2022/lib/ecommerce/styles/order.modal.mjs +1 -1
- package/esm2022/lib/ecommerce/styles/product.modal.mjs +1 -1
- package/esm2022/lib/ecommerce/styles/review.modal.mjs +1 -1
- package/esm2022/lib/ecommerce/styles/user.modal.mjs +1 -1
- package/esm2022/lib/elements/add-section/add-section.component.mjs +3 -3
- package/esm2022/lib/elements/address-list/address-list.component.mjs +3 -3
- package/esm2022/lib/elements/below-image-card/below-image-card.component.mjs +2 -2
- package/esm2022/lib/elements/button/button.component.mjs +3 -3
- package/esm2022/lib/elements/button/button.model.mjs +1 -1
- package/esm2022/lib/elements/card-skeleton-loader/card-skeleton-loader.component.mjs +3 -3
- package/esm2022/lib/elements/covering-image-card/covering-image-card.component.mjs +3 -3
- package/esm2022/lib/elements/editor-service.service.mjs +1 -1
- package/esm2022/lib/elements/heading-element/heading-element.component.mjs +3 -3
- package/esm2022/lib/elements/image-editor/image-editor.component.mjs +1 -1
- package/esm2022/lib/elements/index.mjs +1 -1
- package/esm2022/lib/elements/list-home-appointment/list-home-appointment.component.mjs +3 -3
- package/esm2022/lib/elements/media-selector/media-selector.component.mjs +3 -3
- package/esm2022/lib/elements/portfolio/portfolio.component.mjs +3 -3
- package/esm2022/lib/elements/property/property.component.mjs +3 -3
- package/esm2022/lib/elements/schedule-video-call/schedule-video-call.component.mjs +3 -3
- package/esm2022/lib/elements/simpo-button/simpo-button.component.mjs +3 -9
- package/esm2022/lib/elements/svg-divider/svg-divider.component.mjs +3 -3
- package/esm2022/lib/elements/text/text.component.mjs +3 -3
- package/esm2022/lib/elements/top-of-image-card/top-of-image-card.component.mjs +3 -3
- package/esm2022/lib/pipes/amount.pipe.mjs +1 -1
- package/esm2022/lib/pipes/gender.pipe.mjs +1 -1
- package/esm2022/lib/sections/add-new-section/add-new-section.component.mjs +3 -3
- package/esm2022/lib/sections/appointment-form/appointment-form.component.mjs +3 -3
- package/esm2022/lib/sections/appointment-form/appointment-form.model.mjs +1 -1
- package/esm2022/lib/sections/banner-carousel/banner-carousel.component.mjs +2 -2
- package/esm2022/lib/sections/banner-carousel/banner-carousel.model.mjs +1 -1
- package/esm2022/lib/sections/banner-grid-section/banner-grid-section.component.mjs +3 -3
- package/esm2022/lib/sections/banner-section/banner-section.component.mjs +2 -2
- package/esm2022/lib/sections/blog-list/blog-list.component.mjs +1 -1
- package/esm2022/lib/sections/blog-list/blog-list.model.mjs +1 -1
- package/esm2022/lib/sections/carousel-banner/carousel-banner.component.mjs +2 -2
- package/esm2022/lib/sections/choose-us-section/choose-us-section.component.mjs +3 -3
- package/esm2022/lib/sections/choose-us-section/choose-us-section.model.mjs +1 -1
- package/esm2022/lib/sections/condensed-and-gradient/condensed-and-gradient.component.mjs +2 -2
- package/esm2022/lib/sections/countdown-banner/countdown-banner.component.mjs +2 -2
- package/esm2022/lib/sections/faq-section/faq-section.component.mjs +3 -3
- package/esm2022/lib/sections/faq-section/faq-section.modal.mjs +1 -1
- package/esm2022/lib/sections/features-section/features-section.component.mjs +3 -3
- package/esm2022/lib/sections/features-section/features-section.model.mjs +1 -1
- package/esm2022/lib/sections/footer/footer.component.mjs +1 -1
- package/esm2022/lib/sections/footer/footer.modal.mjs +1 -1
- package/esm2022/lib/sections/footer-section/footer-section.component.mjs +2 -2
- package/esm2022/lib/sections/header-section/header-section.component.mjs +2 -2
- package/esm2022/lib/sections/header-text/header-text.component.mjs +2 -2
- package/esm2022/lib/sections/header-text/header-text.model.mjs +1 -1
- package/esm2022/lib/sections/image-background/image-background/image-background.component.mjs +2 -2
- package/esm2022/lib/sections/image-carousel-section/image-carousel-section.component.mjs +3 -3
- package/esm2022/lib/sections/image-carousel-section/image-carousel.model.mjs +1 -1
- package/esm2022/lib/sections/image-grid-section/image-grid-section.component.mjs +3 -3
- package/esm2022/lib/sections/image-grid-section/image-grid-section.model.mjs +1 -1
- package/esm2022/lib/sections/image-section/image-section.component.mjs +3 -3
- package/esm2022/lib/sections/image-section/image-section.model.mjs +1 -1
- package/esm2022/lib/sections/location-section/location-section.component.mjs +3 -3
- package/esm2022/lib/sections/location-section/location-section.modal.mjs +1 -1
- package/esm2022/lib/sections/logo-showcase/logo-showcase.component.mjs +2 -2
- package/esm2022/lib/sections/logo-showcase/logo-showcase.modal.mjs +1 -1
- package/esm2022/lib/sections/moving-text/moving-text.component.mjs +3 -3
- package/esm2022/lib/sections/moving-text/moving-text.modal.mjs +1 -1
- package/esm2022/lib/sections/navbar-section/navbar-section.component.mjs +2 -2
- package/esm2022/lib/sections/new-services/new-services.component.mjs +4 -4
- package/esm2022/lib/sections/new-services/new-services.model.mjs +1 -1
- package/esm2022/lib/sections/new-testimonials/new-testimonials.component.mjs +4 -4
- package/esm2022/lib/sections/new-testimonials/new-testimonials.model.mjs +1 -1
- package/esm2022/lib/sections/news-letter-component/news-letter-component.component.mjs +3 -3
- package/esm2022/lib/sections/news-letter-component/news-letter.modal.mjs +1 -1
- package/esm2022/lib/sections/overlapping-image/overlapping-image.component.mjs +2 -2
- package/esm2022/lib/sections/pricing-section/pricing-section.component.mjs +2 -2
- package/esm2022/lib/sections/pricing-section/pricing-section.modal.mjs +1 -1
- package/esm2022/lib/sections/process-modern/process-modern.component.mjs +3 -3
- package/esm2022/lib/sections/process-modern/process-modern.model.mjs +1 -1
- package/esm2022/lib/sections/process-section/process-section.component.mjs +3 -3
- package/esm2022/lib/sections/process-section/process-section.modal.mjs +1 -1
- package/esm2022/lib/sections/property-component/property-component.component.mjs +3 -3
- package/esm2022/lib/sections/property-component/property-component.modal.mjs +1 -1
- package/esm2022/lib/sections/property-list/property-list.component.mjs +3 -3
- package/esm2022/lib/sections/property-list/property-list.modal.mjs +1 -1
- package/esm2022/lib/sections/recent-blog-post-section/recent-blog-post-section.component.mjs +3 -3
- package/esm2022/lib/sections/recent-blog-post-section/recent-blog-post-section.model.mjs +1 -1
- package/esm2022/lib/sections/registration-form/registration-form.component.mjs +3 -3
- package/esm2022/lib/sections/registration-form/registrationForm.model.mjs +1 -1
- package/esm2022/lib/sections/scheme-detail/scheme-detail.component.mjs +3 -3
- package/esm2022/lib/sections/scheme-detail/scheme-detail.modal.mjs +1 -1
- package/esm2022/lib/sections/service-section/service-section.component.mjs +2 -2
- package/esm2022/lib/sections/service-section/service-section.model.mjs +1 -1
- package/esm2022/lib/sections/skeleton-loader-section/skeleton-loader-section.component.mjs +3 -3
- package/esm2022/lib/sections/team-member-section/team-member-section.component.mjs +3 -3
- package/esm2022/lib/sections/team-member-section/team-member-section.model.mjs +1 -1
- package/esm2022/lib/sections/testimonial-fullwidth/testimonial-fullwidth.component.mjs +3 -3
- package/esm2022/lib/sections/testimonial-fullwidth/testimonial-fullwidth.model.mjs +1 -1
- package/esm2022/lib/sections/testimonial-section/testimonial-section.component.mjs +3 -3
- package/esm2022/lib/sections/testimonial-section/testimonial-section.model.mjs +1 -1
- package/esm2022/lib/sections/testimonial-video/testimonial-video.component.mjs +3 -3
- package/esm2022/lib/sections/testimonial-video/testimonial-video.model.mjs +1 -1
- package/esm2022/lib/sections/text-image-section/text-image-section.component.mjs +2 -2
- package/esm2022/lib/sections/text-section/text-section.component.mjs +2 -2
- package/esm2022/lib/sections/text-section/text-section.model.mjs +1 -1
- package/esm2022/lib/sections/usp-video-section/usp-video-section.component.mjs +3 -3
- package/esm2022/lib/sections/usp-video-section/usp-video-section.model.mjs +1 -1
- package/esm2022/lib/sections/video-section/video-section.component.mjs +1 -1
- package/esm2022/lib/sections/video-section/video-section.model.mjs +1 -1
- package/esm2022/lib/sections/view-blog/view-blog.component.mjs +1 -1
- package/esm2022/lib/services/cart.service.mjs +5 -44
- package/esm2022/lib/services/endUser.service.mjs +1 -1
- package/esm2022/lib/services/image-upload-service.service.mjs +1 -1
- package/esm2022/lib/services/rest.service.mjs +1 -5
- package/esm2022/lib/services/sanitizeHtml.mjs +1 -1
- package/esm2022/lib/styles/index.mjs +2 -2
- package/esm2022/lib/styles/types.mjs +1 -1
- package/esm2022/lib/tokens/api-token.mjs +1 -1
- package/fesm2022/simpo-component-library.mjs +261 -597
- package/fesm2022/simpo-component-library.mjs.map +1 -1
- package/lib/components/input-fields/input-fields.component.d.ts +1 -1
- package/lib/ecommerce/sections/authentication-required/authentication-required.component.d.ts +3 -12
- package/lib/ecommerce/sections/featured-category/featured-category.component.d.ts +1 -1
- package/lib/ecommerce/sections/featured-category/featured-collection.component.d.ts +1 -1
- package/lib/ecommerce/sections/new-collection/new-collection.component.d.ts +1 -1
- package/lib/ecommerce/sections/product-desc/product-desc.component.d.ts +2 -4
- package/lib/ecommerce/sections/product-list/product-list.component.d.ts +1 -6
- package/lib/elements/link-editor/link-editor.component.d.ts +1 -1
- package/lib/elements/pricing-s1/pricing-s1.component.d.ts +1 -1
- package/lib/elements/simpo-button/simpo-button.component.d.ts +1 -3
- package/lib/sections/banner-carousel/banner-carousel.component.d.ts +2 -2
- package/lib/sections/carousel-banner/carousel-banner.component.d.ts +1 -1
- package/lib/sections/image-grid-hotspot/image-grid-hotspot.component.d.ts +1 -1
- package/lib/sections/image-grid-section/image-grid-section.component.d.ts +1 -1
- package/lib/sections/image-section/image-section.component.d.ts +2 -2
- package/lib/sections/logo-showcase/logo-showcase.component.d.ts +2 -2
- package/lib/sections/pricing-section/pricing-section.component.d.ts +1 -1
- package/lib/services/cart.service.d.ts +1 -7
- package/lib/services/rest.service.d.ts +0 -1
- package/lib/styles/index.d.ts +1 -1
- package/package.json +1 -1
- package/simpo-component-library-3.6.643.tgz +0 -0
- package/esm2022/lib/services/analytics.service.mjs +0 -160
- package/lib/services/analytics.service.d.ts +0 -33
- package/simpo-component-library-3.6.641.tgz +0 -0
|
@@ -13,7 +13,7 @@ export declare class InputFieldsComponent implements OnChanges {
|
|
|
13
13
|
constructor(elementRef: ElementRef);
|
|
14
14
|
ngOnChanges(changes: SimpleChanges): void;
|
|
15
15
|
handleMoneyInput(event: any): void;
|
|
16
|
-
get getTextColor(): "#
|
|
16
|
+
get getTextColor(): "#000" | "#FFF";
|
|
17
17
|
interpolateColor(color1: string, color2: string, factor: number): string;
|
|
18
18
|
padZero(str: string, length: number): string;
|
|
19
19
|
generateColorBasedOnNumber(number: number): string;
|
package/lib/ecommerce/sections/authentication-required/authentication-required.component.d.ts
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import { ElementRef
|
|
2
|
-
import { FormArray, FormControl } from '@angular/forms';
|
|
1
|
+
import { ElementRef } from '@angular/core';
|
|
3
2
|
import { RestService } from '../../../services/rest.service';
|
|
4
3
|
import { ActivatedRoute, Router } from '@angular/router';
|
|
5
4
|
import { MessageService } from 'primeng/api';
|
|
@@ -20,7 +19,7 @@ export declare class AuthenticationRequiredComponent extends BaseSection {
|
|
|
20
19
|
private elementRef;
|
|
21
20
|
private readonly dialogRef;
|
|
22
21
|
private readonly bottomsheetRef;
|
|
23
|
-
data?: AuthenticationModel
|
|
22
|
+
data?: AuthenticationModel;
|
|
24
23
|
index?: number;
|
|
25
24
|
edit?: boolean;
|
|
26
25
|
delete?: boolean;
|
|
@@ -32,7 +31,6 @@ export declare class AuthenticationRequiredComponent extends BaseSection {
|
|
|
32
31
|
email: string;
|
|
33
32
|
mobile: string;
|
|
34
33
|
otp: string;
|
|
35
|
-
otpControls: FormArray<FormControl<string | null>>;
|
|
36
34
|
password: string;
|
|
37
35
|
confPassword: string;
|
|
38
36
|
userName: string;
|
|
@@ -51,15 +49,8 @@ export declare class AuthenticationRequiredComponent extends BaseSection {
|
|
|
51
49
|
proceedToEnrollment: boolean;
|
|
52
50
|
tryAtHome: boolean;
|
|
53
51
|
navigateToSchemeDetails: boolean;
|
|
54
|
-
inputs: QueryList<ElementRef>;
|
|
55
52
|
ngOnInit(): void;
|
|
56
53
|
ngAfterViewInit(): void;
|
|
57
|
-
onInput(index: number): void;
|
|
58
|
-
onKeyDown(event: KeyboardEvent, index: number): void;
|
|
59
|
-
getGradientDirection(direction: string | undefined): string;
|
|
60
|
-
get fontColor(): string;
|
|
61
|
-
get accentBackground(): string;
|
|
62
|
-
getFormOtp(): string;
|
|
63
54
|
loginType: "PASSWORD" | "OTP";
|
|
64
55
|
generateOtp: boolean;
|
|
65
56
|
loginAuthentication(loginType: "PASSWORD" | "OTP"): void;
|
|
@@ -81,7 +72,7 @@ export declare class AuthenticationRequiredComponent extends BaseSection {
|
|
|
81
72
|
validateNumber(event: KeyboardEvent): void;
|
|
82
73
|
validateOTP(event: KeyboardEvent): void;
|
|
83
74
|
checkStrength(): void;
|
|
84
|
-
getStrengthColor(index: number): "
|
|
75
|
+
getStrengthColor(index: number): "tomato" | "#d3d3d3ba" | "orange" | "yellow" | "lightgreen";
|
|
85
76
|
emailDebounceTimer: any;
|
|
86
77
|
onEmailChange(): void;
|
|
87
78
|
emailCheck: boolean;
|
|
@@ -32,7 +32,7 @@ export declare class FeaturedCategoryComponent extends BaseSection {
|
|
|
32
32
|
get getDirection(): "ROW" | "COLUMN" | undefined;
|
|
33
33
|
get stylesLayout(): LayOutModel;
|
|
34
34
|
get isMobile(): boolean;
|
|
35
|
-
getJustifyContent():
|
|
35
|
+
getJustifyContent(): import("simpo-component-library").ALIGN | "" | "flex-start";
|
|
36
36
|
static ɵfac: i0.ɵɵFactoryDeclaration<FeaturedCategoryComponent, never>;
|
|
37
37
|
static ɵcmp: i0.ɵɵComponentDeclaration<FeaturedCategoryComponent, "simpo-featured-category", never, { "data": { "alias": "data"; "required": false; }; "responseData": { "alias": "responseData"; "required": false; }; "index": { "alias": "index"; "required": false; }; "edit": { "alias": "edit"; "required": false; }; "delete": { "alias": "delete"; "required": false; }; "customClass": { "alias": "customClass"; "required": false; }; "nextComponentColor": { "alias": "nextComponentColor"; "required": false; }; }, {}, never, never, true, never>;
|
|
38
38
|
}
|
|
@@ -32,7 +32,7 @@ export declare class FeaturedCollectionComponent extends BaseSection {
|
|
|
32
32
|
get getDirection(): "ROW" | "COLUMN" | undefined;
|
|
33
33
|
get isMobile(): boolean;
|
|
34
34
|
editSection(): void;
|
|
35
|
-
getJustifyContent():
|
|
35
|
+
getJustifyContent(): import("simpo-component-library").ALIGN | "" | "flex-start";
|
|
36
36
|
static ɵfac: i0.ɵɵFactoryDeclaration<FeaturedCollectionComponent, never>;
|
|
37
37
|
static ɵcmp: i0.ɵɵComponentDeclaration<FeaturedCollectionComponent, "simpo-featured-collection", never, { "data": { "alias": "data"; "required": false; }; "responseData": { "alias": "responseData"; "required": false; }; "index": { "alias": "index"; "required": false; }; "edit": { "alias": "edit"; "required": false; }; "delete": { "alias": "delete"; "required": false; }; "customClass": { "alias": "customClass"; "required": false; }; "nextComponentColor": { "alias": "nextComponentColor"; "required": false; }; }, {}, never, never, true, never>;
|
|
38
38
|
}
|
|
@@ -33,7 +33,7 @@ export declare class NewCollectionComponent extends BaseSection {
|
|
|
33
33
|
get isMobile(): boolean;
|
|
34
34
|
editSection(): void;
|
|
35
35
|
getColor(color: any): "#000000" | "#ffffff";
|
|
36
|
-
getJustifyContent():
|
|
36
|
+
getJustifyContent(): import("simpo-component-library").ALIGN | "" | "flex-start";
|
|
37
37
|
static ɵfac: i0.ɵɵFactoryDeclaration<NewCollectionComponent, never>;
|
|
38
38
|
static ɵcmp: i0.ɵɵComponentDeclaration<NewCollectionComponent, "simpo-new-collection", never, { "data": { "alias": "data"; "required": false; }; "responseData": { "alias": "responseData"; "required": false; }; "index": { "alias": "index"; "required": false; }; "edit": { "alias": "edit"; "required": false; }; "delete": { "alias": "delete"; "required": false; }; "customClass": { "alias": "customClass"; "required": false; }; "nextComponentColor": { "alias": "nextComponentColor"; "required": false; }; }, {}, never, never, true, never>;
|
|
39
39
|
}
|
|
@@ -14,7 +14,6 @@ import { Meta, Title } from '@angular/platform-browser';
|
|
|
14
14
|
import { MatDialog } from '@angular/material/dialog';
|
|
15
15
|
import { MatBottomSheet } from '@angular/material/bottom-sheet';
|
|
16
16
|
import { CustomerReviewComponent } from '../../sections/customer-review/customer-review.component';
|
|
17
|
-
import { AnalyticsService } from '../../../services/analytics.service';
|
|
18
17
|
import * as i0 from "@angular/core";
|
|
19
18
|
export declare class ProductDescComponent extends BaseSection {
|
|
20
19
|
private platformId;
|
|
@@ -30,7 +29,6 @@ export declare class ProductDescComponent extends BaseSection {
|
|
|
30
29
|
private readonly bottomSheet;
|
|
31
30
|
private renderer;
|
|
32
31
|
private matDialog;
|
|
33
|
-
private analyticsService;
|
|
34
32
|
reviewComponent: CustomerReviewComponent;
|
|
35
33
|
aboveHeight: ElementRef<HTMLDivElement>;
|
|
36
34
|
container: ElementRef<HTMLDivElement>;
|
|
@@ -54,7 +52,7 @@ export declare class ProductDescComponent extends BaseSection {
|
|
|
54
52
|
showReview: boolean;
|
|
55
53
|
selectedReview: any;
|
|
56
54
|
currentImageIndex: number;
|
|
57
|
-
constructor(platformId: Object, _eventService: EventsService, router: Router, activatedRoute: ActivatedRoute, restService: RestService, cartService: CartService, storageService: StorageServiceService, messageService: MessageService, metaTagService: Meta, titleService: Title, bottomSheet: MatBottomSheet, renderer: Renderer2, matDialog: MatDialog
|
|
55
|
+
constructor(platformId: Object, _eventService: EventsService, router: Router, activatedRoute: ActivatedRoute, restService: RestService, cartService: CartService, storageService: StorageServiceService, messageService: MessageService, metaTagService: Meta, titleService: Title, bottomSheet: MatBottomSheet, renderer: Renderer2, matDialog: MatDialog);
|
|
58
56
|
buttonId?: string;
|
|
59
57
|
button?: ButtonModel;
|
|
60
58
|
styles?: ProductDescStylesModal;
|
|
@@ -119,7 +117,7 @@ export declare class ProductDescComponent extends BaseSection {
|
|
|
119
117
|
getTextColor(color: any): "#000000" | "#ffffff";
|
|
120
118
|
languages: string[];
|
|
121
119
|
selectedLang: string;
|
|
122
|
-
getClass(map: any): "col-
|
|
120
|
+
getClass(map: any): "col-6" | "col-4" | "col-3" | "width-max";
|
|
123
121
|
onFindInStore(id: string): void;
|
|
124
122
|
onBookAppointment(): void;
|
|
125
123
|
isDetails: boolean;
|
|
@@ -12,7 +12,6 @@ import { MatDialog } from '@angular/material/dialog';
|
|
|
12
12
|
import { CartService } from '../../../services/cart.service';
|
|
13
13
|
import { MenuItem, MessageService } from 'primeng/api';
|
|
14
14
|
import { ProductCardTheme } from '../../../styles/index';
|
|
15
|
-
import { AnalyticsService } from '../../../services/analytics.service';
|
|
16
15
|
import * as i0 from "@angular/core";
|
|
17
16
|
interface BaseModel {
|
|
18
17
|
option: string;
|
|
@@ -32,7 +31,6 @@ export declare class ProductListComponent extends BaseSection {
|
|
|
32
31
|
private readonly cartService;
|
|
33
32
|
private readonly messageService;
|
|
34
33
|
private renderer;
|
|
35
|
-
private readonly analyticsService;
|
|
36
34
|
responseData?: Product[];
|
|
37
35
|
data?: ProductListModal;
|
|
38
36
|
index?: number;
|
|
@@ -71,7 +69,6 @@ export declare class ProductListComponent extends BaseSection {
|
|
|
71
69
|
searchTxt: string;
|
|
72
70
|
theme: typeof ProductCardTheme;
|
|
73
71
|
items: MenuItem[] | null;
|
|
74
|
-
latestAnalyicsEvent: string;
|
|
75
72
|
private filterBottomSheetRef;
|
|
76
73
|
private sortingDialogRef;
|
|
77
74
|
categories: BaseModel[];
|
|
@@ -80,7 +77,7 @@ export declare class ProductListComponent extends BaseSection {
|
|
|
80
77
|
listScrollContainer: ElementRef<HTMLDivElement>;
|
|
81
78
|
getScreenSize(): void;
|
|
82
79
|
onWindowScroll(event: Event): void;
|
|
83
|
-
constructor(platformId: Object, _eventService: EventsService, restService: RestService, router: Router, activatedRoute: ActivatedRoute, storageService: StorageServiceService, matBottomSheet: MatBottomSheet, matDialog: MatDialog, cartService: CartService, messageService: MessageService, renderer: Renderer2
|
|
80
|
+
constructor(platformId: Object, _eventService: EventsService, restService: RestService, router: Router, activatedRoute: ActivatedRoute, storageService: StorageServiceService, matBottomSheet: MatBottomSheet, matDialog: MatDialog, cartService: CartService, messageService: MessageService, renderer: Renderer2);
|
|
84
81
|
get stylesLayout(): LayOutModel;
|
|
85
82
|
isOpen: boolean;
|
|
86
83
|
toggleDropdown(): void;
|
|
@@ -106,8 +103,6 @@ export declare class ProductListComponent extends BaseSection {
|
|
|
106
103
|
toShowInJewellery: boolean;
|
|
107
104
|
IsEcommerce: boolean;
|
|
108
105
|
ngOnInit(): void;
|
|
109
|
-
fetchAnalytics(): void;
|
|
110
|
-
getCategoriesAndCollection(): void;
|
|
111
106
|
get selectedCategoryCollectionChips(): {
|
|
112
107
|
id: string;
|
|
113
108
|
name: string;
|
|
@@ -31,7 +31,7 @@ export declare class LinkEditorComponent {
|
|
|
31
31
|
changeButtonStyle(): void;
|
|
32
32
|
getContrastTextColor(backgroundHex: any): void;
|
|
33
33
|
backgroundType: string[];
|
|
34
|
-
setBorderRadius(): "0px" | "
|
|
34
|
+
setBorderRadius(): "0px" | "7px" | "99px";
|
|
35
35
|
setBorder(): string;
|
|
36
36
|
setColor(): any;
|
|
37
37
|
setBackground(): any;
|
|
@@ -15,7 +15,7 @@ export declare class PricingS1Component extends BaseSection {
|
|
|
15
15
|
editSection(): void;
|
|
16
16
|
getButtonId(): string;
|
|
17
17
|
redirectTo(data: any): void;
|
|
18
|
-
getClass(): "col-
|
|
18
|
+
getClass(): "col-12" | "col-4" | "col-5";
|
|
19
19
|
static ɵfac: i0.ɵɵFactoryDeclaration<PricingS1Component, never>;
|
|
20
20
|
static ɵcmp: i0.ɵɵComponentDeclaration<PricingS1Component, "simpo-pricing-s1", never, { "data": { "alias": "data"; "required": false; }; "edit": { "alias": "edit"; "required": false; }; }, {}, never, never, true, never>;
|
|
21
21
|
}
|
|
@@ -10,11 +10,9 @@ export declare class SimpoButtonComponent {
|
|
|
10
10
|
sectionId?: string;
|
|
11
11
|
edit?: boolean;
|
|
12
12
|
backgroundInfo?: BackgroundModel;
|
|
13
|
-
disabled?: boolean;
|
|
14
|
-
loading?: boolean;
|
|
15
13
|
constructor(_eventService: EventsService);
|
|
16
14
|
ngOnInit(): void;
|
|
17
15
|
redirectTo(): void;
|
|
18
16
|
static ɵfac: i0.ɵɵFactoryDeclaration<SimpoButtonComponent, never>;
|
|
19
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<SimpoButtonComponent, "app-button-element", never, { "buttonContent": { "alias": "buttonContent"; "required": false; }; "buttonStyle": { "alias": "buttonStyle"; "required": false; }; "buttonId": { "alias": "buttonId"; "required": false; }; "color": { "alias": "color"; "required": false; }; "sectionId": { "alias": "sectionId"; "required": false; }; "edit": { "alias": "edit"; "required": false; }; "backgroundInfo": { "alias": "backgroundInfo"; "required": false; };
|
|
17
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<SimpoButtonComponent, "app-button-element", never, { "buttonContent": { "alias": "buttonContent"; "required": false; }; "buttonStyle": { "alias": "buttonStyle"; "required": false; }; "buttonId": { "alias": "buttonId"; "required": false; }; "color": { "alias": "color"; "required": false; }; "sectionId": { "alias": "sectionId"; "required": false; }; "edit": { "alias": "edit"; "required": false; }; "backgroundInfo": { "alias": "backgroundInfo"; "required": false; }; }, {}, never, never, true, never>;
|
|
20
18
|
}
|
|
@@ -25,8 +25,8 @@ export declare class BannerCarouselComponent extends BaseSection implements OnIn
|
|
|
25
25
|
get stylesLayout(): LayOutModel;
|
|
26
26
|
get getBlurValue(): "NONE" | "LIGHT" | "MODERATE" | "STRONG" | "VERY_STRONG" | undefined;
|
|
27
27
|
get getBackgroundColor(): BackgroundModel;
|
|
28
|
-
get getBackgroundOpacity(): "
|
|
29
|
-
opacityValue(value: OverlayValue): "
|
|
28
|
+
get getBackgroundOpacity(): "0.5" | "0.7" | "0" | "0.6" | "0.8" | "1";
|
|
29
|
+
opacityValue(value: OverlayValue): "0.5" | "0.7" | "0.6" | "0.8" | "1";
|
|
30
30
|
editSection(): void;
|
|
31
31
|
getScreenSize(): number;
|
|
32
32
|
static ɵfac: i0.ɵɵFactoryDeclaration<BannerCarouselComponent, never>;
|
|
@@ -25,7 +25,7 @@ export declare class CarouselBannerComponent extends BaseSection implements OnIn
|
|
|
25
25
|
get canMergeNavbar(): boolean | undefined;
|
|
26
26
|
get isBorderlessImage(): boolean | undefined;
|
|
27
27
|
get getPositionLayout(): PositionLayoutModal;
|
|
28
|
-
opacityValue(value: OverlayValue): "0" | "0.
|
|
28
|
+
opacityValue(value: OverlayValue): "0.2" | "0.3" | "0.5" | "0.7" | "0";
|
|
29
29
|
editSection(): void;
|
|
30
30
|
static ɵfac: i0.ɵɵFactoryDeclaration<CarouselBannerComponent, never>;
|
|
31
31
|
static ɵcmp: i0.ɵɵComponentDeclaration<CarouselBannerComponent, "simpo-carousel-banner", never, { "data": { "alias": "data"; "required": false; }; "index": { "alias": "index"; "required": false; }; "edit": { "alias": "edit"; "required": false; }; "delete": { "alias": "delete"; "required": false; }; "customClass": { "alias": "customClass"; "required": false; }; "nextComponentColor": { "alias": "nextComponentColor"; "required": false; }; }, {}, never, never, true, never>;
|
|
@@ -23,7 +23,7 @@ export declare class ImageGridHotspotComponent extends BaseSection {
|
|
|
23
23
|
get headingSpace(): SPACING;
|
|
24
24
|
editSection(): void;
|
|
25
25
|
getLength(): number;
|
|
26
|
-
getJustifyContent():
|
|
26
|
+
getJustifyContent(): import("simpo-component-library").ALIGN | "" | "flex-start";
|
|
27
27
|
private get scrollStep();
|
|
28
28
|
scrollRight(): void;
|
|
29
29
|
isOverflowing: boolean;
|
|
@@ -23,7 +23,7 @@ export declare class ImageGridSectionComponent extends BaseSection {
|
|
|
23
23
|
get headingSpace(): SPACING;
|
|
24
24
|
editSection(): void;
|
|
25
25
|
getLength(): number;
|
|
26
|
-
getJustifyContent():
|
|
26
|
+
getJustifyContent(): import("simpo-component-library").ALIGN | "" | "flex-start";
|
|
27
27
|
private get scrollStep();
|
|
28
28
|
scrollRight(): void;
|
|
29
29
|
isOverflowing: boolean;
|
|
@@ -20,9 +20,9 @@ export declare class ImageSectionComponent extends BaseSection {
|
|
|
20
20
|
constructor(_eventService: EventsService);
|
|
21
21
|
ngOnInit(): void;
|
|
22
22
|
get canMergeNavbar(): boolean | undefined;
|
|
23
|
-
get getBackgroundOpacity(): "
|
|
23
|
+
get getBackgroundOpacity(): "0.2" | "0.3" | "0.5" | "0.7" | "1";
|
|
24
24
|
get stylesLayout(): LayOutModel;
|
|
25
|
-
opacityValue(value: OverlayValue): "
|
|
25
|
+
opacityValue(value: OverlayValue): "0.2" | "0.3" | "0.5" | "0.7" | "1";
|
|
26
26
|
editSection(): void;
|
|
27
27
|
redirectTo(): void;
|
|
28
28
|
static ɵfac: i0.ɵɵFactoryDeclaration<ImageSectionComponent, never>;
|
|
@@ -23,8 +23,8 @@ export declare class LogoShowcaseComponent extends BaseSection implements OnInit
|
|
|
23
23
|
constructor(_eventService: EventsService);
|
|
24
24
|
ngOnInit(): void;
|
|
25
25
|
get stylesLayout(): LayOutModel;
|
|
26
|
-
get animationDuration(): "3s" | "
|
|
27
|
-
get animationDirection():
|
|
26
|
+
get animationDuration(): "3s" | "6s" | "5s" | "4s" | logoSpeed.Normal;
|
|
27
|
+
get animationDirection(): "reverse" | "normal" | logoDirection.Left;
|
|
28
28
|
get isMobile(): boolean;
|
|
29
29
|
get getPositionLayout(): PositionLayoutModal;
|
|
30
30
|
screenWidth: number;
|
|
@@ -23,7 +23,7 @@ export declare class PricingSectionComponent extends BaseSection {
|
|
|
23
23
|
getButtonId(): string;
|
|
24
24
|
editSection(): void;
|
|
25
25
|
redirectTo(data: any): void;
|
|
26
|
-
getClass(): "col-
|
|
26
|
+
getClass(): "col-12" | "col-6" | "col-4" | "col-3";
|
|
27
27
|
getAlignment(): "justify-content-start" | "justify-content-center" | "justify-content-end";
|
|
28
28
|
static ɵfac: i0.ɵɵFactoryDeclaration<PricingSectionComponent, never>;
|
|
29
29
|
static ɵcmp: i0.ɵɵComponentDeclaration<PricingSectionComponent, "simpo-pricing-section", never, { "data": { "alias": "data"; "required": false; }; "index": { "alias": "index"; "required": false; }; "edit": { "alias": "edit"; "required": false; }; "customClass": { "alias": "customClass"; "required": false; }; "delete": { "alias": "delete"; "required": false; }; "nextComponentColor": { "alias": "nextComponentColor"; "required": false; }; }, {}, never, never, true, never>;
|
|
@@ -2,20 +2,15 @@ import { OrderedItems } from '../ecommerce/styles/OrderedItems.modal';
|
|
|
2
2
|
import { Product } from '../ecommerce/styles/product.modal';
|
|
3
3
|
import { RestService } from './rest.service';
|
|
4
4
|
import { StorageServiceService } from './storage.service';
|
|
5
|
-
import { Router } from '@angular/router';
|
|
6
|
-
import { StorageLike } from '../services/storage-like';
|
|
7
5
|
import * as i0 from "@angular/core";
|
|
8
6
|
export declare class CartService {
|
|
9
7
|
private readonly storageService;
|
|
10
8
|
private readonly restService;
|
|
11
|
-
|
|
12
|
-
private storage;
|
|
13
|
-
constructor(storageService: StorageServiceService, restService: RestService, router: Router, storage: StorageLike);
|
|
9
|
+
constructor(storageService: StorageServiceService, restService: RestService);
|
|
14
10
|
addItemFromCartPage(product: OrderedItems, userCart: any): import("rxjs").Observable<Object>;
|
|
15
11
|
addItemFromWishlistPage(product: OrderedItems, userWishlist: any): import("rxjs").Observable<Object>;
|
|
16
12
|
removeItemFromWishlistPage(product: OrderedItems, userWishlist: any): import("rxjs").Observable<Object>;
|
|
17
13
|
addItemToCart(product: Product | OrderedItems, varientId?: string): void | IDBRequest<IDBValidKey>;
|
|
18
|
-
captureCartAnalytics(productId: string, type: 'ADD_TO_CART' | 'REMOVE_FROM_CART', variantId?: string): void;
|
|
19
14
|
addItemToFavourite(product: Product, varientId?: string): void;
|
|
20
15
|
addItemToTrial(product: Product, varientId?: string): Promise<boolean>;
|
|
21
16
|
addItemToFavFromCart(product: OrderedItems): void;
|
|
@@ -23,7 +18,6 @@ export declare class CartService {
|
|
|
23
18
|
removeItemFromFavourite(varientId: string): void;
|
|
24
19
|
removeItemFromCart(product: Product | OrderedItems): void;
|
|
25
20
|
private objectMapper;
|
|
26
|
-
trackUser(event: any, eventType: string): void;
|
|
27
21
|
static ɵfac: i0.ɵɵFactoryDeclaration<CartService, never>;
|
|
28
22
|
static ɵprov: i0.ɵɵInjectableDeclaration<CartService>;
|
|
29
23
|
}
|
|
@@ -135,7 +135,6 @@ export declare class RestService implements OnDestroy {
|
|
|
135
135
|
createLead(payload: any): Observable<Object>;
|
|
136
136
|
getAppointmentPaymentStatus(orderId: any): Observable<Object>;
|
|
137
137
|
getOtpForLogin(payload: any): Observable<Object>;
|
|
138
|
-
flush(eventsToSend: any): void;
|
|
139
138
|
static ɵfac: i0.ɵɵFactoryDeclaration<RestService, never>;
|
|
140
139
|
static ɵprov: i0.ɵɵInjectableDeclaration<RestService>;
|
|
141
140
|
}
|
package/lib/styles/index.d.ts
CHANGED
package/package.json
CHANGED
|
Binary file
|
|
@@ -1,160 +0,0 @@
|
|
|
1
|
-
import { Inject, Injectable, PLATFORM_ID } from '@angular/core';
|
|
2
|
-
import { interval } from 'rxjs';
|
|
3
|
-
import { DOCUMENT } from '@angular/common';
|
|
4
|
-
import { API_URL } from '../tokens/api-token';
|
|
5
|
-
import { LOCAL_STORAGE } from '../services/local-storage.token';
|
|
6
|
-
import { NavigationEnd } from '@angular/router';
|
|
7
|
-
import * as i0 from "@angular/core";
|
|
8
|
-
import * as i1 from "@angular/common/http";
|
|
9
|
-
import * as i2 from "./storage.service";
|
|
10
|
-
import * as i3 from "@angular/router";
|
|
11
|
-
export class AnalyticsService {
|
|
12
|
-
constructor(http, platformId, document, storageService, API_URL, storage, router) {
|
|
13
|
-
this.http = http;
|
|
14
|
-
this.platformId = platformId;
|
|
15
|
-
this.document = document;
|
|
16
|
-
this.storageService = storageService;
|
|
17
|
-
this.API_URL = API_URL;
|
|
18
|
-
this.storage = storage;
|
|
19
|
-
this.router = router;
|
|
20
|
-
this.eventQueue = [];
|
|
21
|
-
this.BATCH_SIZE = 10;
|
|
22
|
-
this.FLUSH_INTERVAL = 5000; // 5 seconds
|
|
23
|
-
// ===== Duration Tracking =====
|
|
24
|
-
this.currentPage = '';
|
|
25
|
-
this.currentContextMetadata = null;
|
|
26
|
-
this.contextStartTime = null;
|
|
27
|
-
this.contextActiveTime = 0;
|
|
28
|
-
this.currentEvent = '';
|
|
29
|
-
this.startAutoFlush();
|
|
30
|
-
this.listenToUnload();
|
|
31
|
-
this.listenToRouteChange();
|
|
32
|
-
}
|
|
33
|
-
startNewContext(metadata, event) {
|
|
34
|
-
this.closeCurrentContext(); // close previous filter session
|
|
35
|
-
this.currentContextMetadata = metadata;
|
|
36
|
-
this.contextStartTime = Date.now();
|
|
37
|
-
this.contextActiveTime = 0;
|
|
38
|
-
this.currentEvent = event;
|
|
39
|
-
}
|
|
40
|
-
getCurrentContext() {
|
|
41
|
-
return this.currentContextMetadata;
|
|
42
|
-
}
|
|
43
|
-
closeCurrentContext(useBeacon = false) {
|
|
44
|
-
if (!this.currentContextMetadata)
|
|
45
|
-
return;
|
|
46
|
-
if (this.contextStartTime) {
|
|
47
|
-
this.contextActiveTime += Date.now() - this.contextStartTime;
|
|
48
|
-
}
|
|
49
|
-
const user = this.storageService.getUser();
|
|
50
|
-
const requestFrom = this.storage.getItem('REQUEST_FROM');
|
|
51
|
-
if (!user || requestFrom === 'ECOMMERCE')
|
|
52
|
-
return;
|
|
53
|
-
const event = {
|
|
54
|
-
businessId: this.storage.getItem('bId') || '',
|
|
55
|
-
businessName: this.storage.getItem('bName') || '',
|
|
56
|
-
userId: user.userId,
|
|
57
|
-
createdTimeStamp: new Date().toISOString(),
|
|
58
|
-
page: this.currentPage,
|
|
59
|
-
duration: this.contextActiveTime,
|
|
60
|
-
eventType: this.currentEvent,
|
|
61
|
-
metadata: this.currentContextMetadata
|
|
62
|
-
};
|
|
63
|
-
if (useBeacon) {
|
|
64
|
-
fetch(this.API_URL + 'ecommerce/analytics/batch', {
|
|
65
|
-
method: 'POST',
|
|
66
|
-
body: JSON.stringify([event]),
|
|
67
|
-
headers: {
|
|
68
|
-
'Content-Type': 'application/json'
|
|
69
|
-
},
|
|
70
|
-
keepalive: true
|
|
71
|
-
});
|
|
72
|
-
}
|
|
73
|
-
else {
|
|
74
|
-
this.eventQueue.push(event);
|
|
75
|
-
}
|
|
76
|
-
this.currentContextMetadata = null;
|
|
77
|
-
this.contextStartTime = null;
|
|
78
|
-
this.contextActiveTime = 0;
|
|
79
|
-
this.currentEvent = '';
|
|
80
|
-
}
|
|
81
|
-
// ===============================
|
|
82
|
-
// 🔥 ROUTE CHANGE LISTENER
|
|
83
|
-
// ===============================
|
|
84
|
-
listenToRouteChange() {
|
|
85
|
-
this.router.events.subscribe(event => {
|
|
86
|
-
if (event instanceof NavigationEnd) {
|
|
87
|
-
// Close previous page context
|
|
88
|
-
this.closeCurrentContext();
|
|
89
|
-
this.currentPage = this.router.url.split('?')[0];
|
|
90
|
-
this.contextStartTime = Date.now();
|
|
91
|
-
this.contextActiveTime = 0;
|
|
92
|
-
}
|
|
93
|
-
});
|
|
94
|
-
}
|
|
95
|
-
trackUser(event, eventType) {
|
|
96
|
-
const user = this.storageService.getUser();
|
|
97
|
-
const requestFrom = this.storage.getItem('REQUEST_FROM');
|
|
98
|
-
if (user === null || requestFrom === 'ECOMMERCE') {
|
|
99
|
-
return;
|
|
100
|
-
}
|
|
101
|
-
const page = this.router.url.split('?')[0];
|
|
102
|
-
this.eventQueue.push({
|
|
103
|
-
businessId: this.storage.getItem('bId') || '',
|
|
104
|
-
businessName: this.storage.getItem('bName') || '',
|
|
105
|
-
userId: user?.userId,
|
|
106
|
-
createdTimeStamp: new Date().toISOString(),
|
|
107
|
-
page: page,
|
|
108
|
-
metadata: event,
|
|
109
|
-
eventType: eventType
|
|
110
|
-
});
|
|
111
|
-
if (this.eventQueue.length >= this.BATCH_SIZE) {
|
|
112
|
-
this.flush();
|
|
113
|
-
}
|
|
114
|
-
}
|
|
115
|
-
startAutoFlush() {
|
|
116
|
-
interval(this.FLUSH_INTERVAL).subscribe(() => {
|
|
117
|
-
if (this.eventQueue.length > 0) {
|
|
118
|
-
this.flush();
|
|
119
|
-
}
|
|
120
|
-
});
|
|
121
|
-
}
|
|
122
|
-
flush() {
|
|
123
|
-
const eventsToSend = [...this.eventQueue];
|
|
124
|
-
this.eventQueue = [];
|
|
125
|
-
this.http.post(this.API_URL + 'ecommerce/analytics/batch', eventsToSend)
|
|
126
|
-
.subscribe({ error: () => { } });
|
|
127
|
-
}
|
|
128
|
-
listenToUnload() {
|
|
129
|
-
this.document.addEventListener('visibilitychange', () => {
|
|
130
|
-
if (this.document.visibilityState === 'visible') {
|
|
131
|
-
this.contextStartTime = Date.now();
|
|
132
|
-
}
|
|
133
|
-
else {
|
|
134
|
-
if (this.contextStartTime) {
|
|
135
|
-
this.contextActiveTime += Date.now() - this.contextStartTime;
|
|
136
|
-
}
|
|
137
|
-
this.closeCurrentContext(true);
|
|
138
|
-
}
|
|
139
|
-
});
|
|
140
|
-
}
|
|
141
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: AnalyticsService, deps: [{ token: i1.HttpClient }, { token: PLATFORM_ID }, { token: DOCUMENT }, { token: i2.StorageServiceService }, { token: API_URL }, { token: LOCAL_STORAGE }, { token: i3.Router }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
142
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: AnalyticsService, providedIn: 'root' }); }
|
|
143
|
-
}
|
|
144
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: AnalyticsService, decorators: [{
|
|
145
|
-
type: Injectable,
|
|
146
|
-
args: [{ providedIn: 'root' }]
|
|
147
|
-
}], ctorParameters: () => [{ type: i1.HttpClient }, { type: Object, decorators: [{
|
|
148
|
-
type: Inject,
|
|
149
|
-
args: [PLATFORM_ID]
|
|
150
|
-
}] }, { type: Document, decorators: [{
|
|
151
|
-
type: Inject,
|
|
152
|
-
args: [DOCUMENT]
|
|
153
|
-
}] }, { type: i2.StorageServiceService }, { type: undefined, decorators: [{
|
|
154
|
-
type: Inject,
|
|
155
|
-
args: [API_URL]
|
|
156
|
-
}] }, { type: undefined, decorators: [{
|
|
157
|
-
type: Inject,
|
|
158
|
-
args: [LOCAL_STORAGE]
|
|
159
|
-
}] }, { type: i3.Router }] });
|
|
160
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYW5hbHl0aWNzLnNlcnZpY2UuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9zaW1wby11aS9zcmMvbGliL3NlcnZpY2VzL2FuYWx5dGljcy5zZXJ2aWNlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxNQUFNLEVBQUUsVUFBVSxFQUFFLFdBQVcsRUFBRSxNQUFNLGVBQWUsQ0FBQztBQUVoRSxPQUFPLEVBQUUsUUFBUSxFQUFFLE1BQU0sTUFBTSxDQUFDO0FBQ2hDLE9BQU8sRUFBRSxRQUFRLEVBQXFCLE1BQU0saUJBQWlCLENBQUM7QUFFOUQsT0FBTyxFQUFFLE9BQU8sRUFBRSxNQUFNLHFCQUFxQixDQUFDO0FBRzlDLE9BQU8sRUFBRSxhQUFhLEVBQUUsTUFBTSxpQ0FBaUMsQ0FBQztBQUNoRSxPQUFPLEVBQUUsYUFBYSxFQUFVLE1BQU0saUJBQWlCLENBQUM7Ozs7O0FBR3hELE1BQU0sT0FBTyxnQkFBZ0I7SUFhekI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dGl2ZVRpbWUsXHJcbiAgICAgICAgICAgIGV2ZW50VHlwZTogIHRoaXMuY3VycmVudEV2ZW50LFxyXG4gICAgICAgICAgICBtZXRhZGF0YTogdGhpcy5jdXJyZW50Q29udGV4dE1ldGFkYXRhXHJcbiAgICAgICAgfTtcclxuXHJcbiAgICAgICAgaWYgKHVzZUJlYWNvbikge1xyXG5cclxuICAgICAgICAgICBmZXRjaCh0aGlzLkFQSV9VUkwgKyAnZWNvbW1lcmNlL2FuYWx5dGljcy9iYXRjaCcsIHtcclxuICAgICAgICAgICAgICAgIG1ldGhvZDogJ1BPU1QnLFxyXG4gICAgICAgICAgICAgICAgYm9keTogSlNPTi5zdHJpbmdpZnkoW2V2ZW50XSksXHJcbiAgICAgICAgICAgICAgICBoZWFkZXJzOiB7XHJcbiAgICAgICAgICAgICAgICAnQ29udGVudC1UeXBlJzogJ2FwcGxpY2F0aW9uL2pzb24nXHJcbiAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAga2VlcGFsaXZlOiB0cnVlXHJcbiAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICB9IGVsc2Uge1xyXG4gICAgICAgICAgICB0aGlzLmV2ZW50UXVldWUucHVzaChldmVudCk7XHJcbiAgICAgICAgfVxyXG5cclxuICAgICAgICB0aGlzLmN1cnJlbnRDb250ZXh0TWV0YWRhdGEgPSBudWxsO1xyXG4gICAgICAgIHRoaXMuY29udGV4dFN0YXJ0VGltZSA9IG51bGw7XHJcbiAgICAgICAgdGhpcy5jb250ZXh0QWN0aXZlVGltZSA9IDA7XHJcbiAgICAgICAgdGhpcy5jdXJyZW50RXZlbnQgPSAnJztcclxuICAgIH1cclxuXHJcbiAgICAvLyA9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09XHJcbiAgICAvLyDwn5SlIFJPVVRFIENIQU5HRSBMSVNURU5FUlxyXG4gICAgLy8gPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PVxyXG4gICAgcHJpdmF0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2FuYWx5dGljcy9iYXRjaCcsIGV2ZW50c1RvU2VuZClcclxuICAgICAgICAgICAgLnN1YnNjcmliZSh7IGVycm9yOiAoKSA9PiB7IH0gfSk7XHJcbiAgICB9XHJcblxyXG4gICAgcHJpdmF0ZSBsaXN0ZW5Ub1VubG9hZCgpIHtcclxuICAgICAgICB0aGlzLmRvY3VtZW50LmFkZEV2ZW50TGlzdGVuZXIoJ3Zpc2liaWxpdHljaGFuZ2UnLCAoKSA9PiB7XHJcblxyXG4gICAgICAgICAgICBpZiAodGhpcy5kb2N1bWVudC52aXNpYmlsaXR5U3RhdGUgPT09ICd2aXNpYmxlJykge1xyXG4gICAgICAgICAgICAgICAgdGhpcy5jb250ZXh0U3RhcnRUaW1lID0gRGF0ZS5ub3coKTtcclxuICAgICAgICAgICAgfSBlbHNlIHtcclxuXHJcbiAgICAgICAgICAgICAgICBpZiAodGhpcy5jb250ZXh0U3RhcnRUaW1lKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgdGhpcy5jb250ZXh0QWN0aXZlVGltZSArPSBEYXRlLm5vdygpIC0gdGhpcy5jb250ZXh0U3RhcnRUaW1lO1xyXG4gICAgICAgICAgICAgICAgfVxyXG5cclxuICAgICAgICAgICAgICAgIHRoaXMuY2xvc2VDdXJyZW50Q29udGV4dCh0cnVlKTtcclxuICAgICAgICAgICAgfVxyXG4gICAgICAgIH0pO1xyXG4gICAgfVxyXG59Il19
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import { HttpClient } from '@angular/common/http';
|
|
2
|
-
import { StorageServiceService } from './storage.service';
|
|
3
|
-
import { StorageLike } from '../services/storage-like';
|
|
4
|
-
import { Router } from '@angular/router';
|
|
5
|
-
import * as i0 from "@angular/core";
|
|
6
|
-
export declare class AnalyticsService {
|
|
7
|
-
private http;
|
|
8
|
-
private platformId;
|
|
9
|
-
private document;
|
|
10
|
-
private readonly storageService;
|
|
11
|
-
private API_URL;
|
|
12
|
-
private storage;
|
|
13
|
-
private router;
|
|
14
|
-
private eventQueue;
|
|
15
|
-
private BATCH_SIZE;
|
|
16
|
-
private FLUSH_INTERVAL;
|
|
17
|
-
private currentPage;
|
|
18
|
-
private currentContextMetadata;
|
|
19
|
-
private contextStartTime;
|
|
20
|
-
private contextActiveTime;
|
|
21
|
-
private currentEvent;
|
|
22
|
-
constructor(http: HttpClient, platformId: Object, document: Document, storageService: StorageServiceService, API_URL: string, storage: StorageLike, router: Router);
|
|
23
|
-
startNewContext(metadata: any, event: string): void;
|
|
24
|
-
getCurrentContext(): any;
|
|
25
|
-
private closeCurrentContext;
|
|
26
|
-
private listenToRouteChange;
|
|
27
|
-
trackUser(event: any, eventType: string): void;
|
|
28
|
-
private startAutoFlush;
|
|
29
|
-
private flush;
|
|
30
|
-
private listenToUnload;
|
|
31
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<AnalyticsService, never>;
|
|
32
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<AnalyticsService>;
|
|
33
|
-
}
|
|
Binary file
|