simpo-component-library 3.6.934 → 3.6.935

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.
@@ -47,7 +47,7 @@ export declare class CartComponent extends BaseSection implements OnInit, OnDest
47
47
  isLoading: boolean;
48
48
  styles?: CartSectionStylesModel;
49
49
  currentTab: 'BAG' | 'ADDRESS' | 'PAYMENT';
50
- cartType: 'SHOPPING' | 'TRIAL';
50
+ cartType: 'SHOPPING' | 'BOOKING';
51
51
  d2: ElementRef;
52
52
  pincode: any;
53
53
  constructor(_eventService: EventsService, cartService: CartService, router: Router, restService: RestService, matDialog: MatDialog, storageService: StorageServiceService, messageService: MessageService, bottomSheet: MatBottomSheet, activatedRoute: ActivatedRoute, matDialogData: any, dialogRef: MatDialogRef<CartComponent>);
@@ -61,8 +61,8 @@ export declare class CartComponent extends BaseSection implements OnInit, OnDest
61
61
  featureProductData: FeaturedProductModal | null;
62
62
  private USER_CART;
63
63
  private USER_WISHLIST;
64
- trialCartItem: OrderedItems[] | null;
65
64
  selectMatureScheme: boolean;
65
+ get getTotalBookingItems(): number;
66
66
  cartInfo: any;
67
67
  loadingSubscription?: Subscription;
68
68
  subIndustryName: string;
@@ -78,8 +78,6 @@ export declare class CartComponent extends BaseSection implements OnInit, OnDest
78
78
  getSchemeDetails(): void;
79
79
  ngOnDestroy(): void;
80
80
  onToggleChange(): void;
81
- getTrialCart(): void;
82
- getTrialCartIndexDBData(): void;
83
81
  updateUserCart(): void;
84
82
  getDefaultAddress(): void;
85
83
  get stylesLayout(): LayOutModel;
@@ -137,8 +135,6 @@ export declare class CartComponent extends BaseSection implements OnInit, OnDest
137
135
  getButtonId(index: number): string;
138
136
  getButtonStyle(index: number): import("../../../styles/style.model").ButtonStyleModel | undefined;
139
137
  changeQuantity(quantity: any, item: OrderedItems): void;
140
- removeTrialItem(item: OrderedItems): void;
141
- bookAppointment(): void;
142
138
  showReedemError: boolean;
143
139
  vaildAmount: number;
144
140
  redeemScheme(scheme: any, action: boolean): void;
@@ -146,6 +146,7 @@ export declare class ProductDescComponent extends BaseSection {
146
146
  isSubmitting: boolean;
147
147
  scheduled: boolean;
148
148
  scheduleVideoCall(): void;
149
+ continueVideoCallBooking(): void;
149
150
  resetValidationErrors(): void;
150
151
  resetForm(): void;
151
152
  onInputChange(field: any): void;
@@ -157,12 +158,15 @@ export declare class ProductDescComponent extends BaseSection {
157
158
  closeDialog(): void;
158
159
  getRatings(noofratings: any): any;
159
160
  /**
160
- * "Try at Home" now feeds the new Home Visit booking flow (BookingGroup.productLines,
161
- * submitted directly at hold time) rather than the old ecommerce TRIAL_CART/HomeAppointments
162
- * flow being retired — see appointment_service's design doc. Opens the real booking wizard
163
- * pre-seeded with this product instead of navigating to the old trial-cart checkout page.
161
+ * "Try at Home" feeds the Home Visit booking flow (BookingGroup.productLines, submitted
162
+ * directly at hold time) rather than the old ecommerce TRIAL_CART/HomeAppointments flow being
163
+ * retired — see appointment_service's design doc. Just adds to the local Home Visit cart and
164
+ * confirms, like a normal add-to-cart — it does not open the booking wizard. The wizard opens
165
+ * only when the shopper deliberately clicks Continue Booking (continueHomeVisitBooking), so
166
+ * adding never interrupts browsing and never trips the wizard's login gate on an anonymous add.
164
167
  */
165
168
  addToTrialCart(): void;
169
+ continueHomeVisitBooking(): void;
166
170
  reviewsData: any[];
167
171
  ratingCounts: any;
168
172
  pageNumber: number;
@@ -222,7 +222,12 @@ export declare class ProductListComponent extends BaseSection implements OnDestr
222
222
  materialCollapsed: boolean;
223
223
  metalCollapsed: boolean;
224
224
  ringStyleCollapsed: boolean;
225
- /** Feeds the new Home Visit booking flow directly (BookingGroup.productLines) rather than the retiring TRIAL_CART. */
225
+ /**
226
+ * Feeds the Home Visit booking flow directly (BookingGroup.productLines) rather than the
227
+ * retiring TRIAL_CART. Just adds to the local Home Visit cart and confirms with a toast — it
228
+ * does not open the booking wizard, so a shopper can keep browsing the grid and add more
229
+ * pieces. They continue into the wizard later from the Booking Cart (header icon / cart page).
230
+ */
226
231
  addToTrialCart(product: Product): Promise<void>;
227
232
  productName: string;
228
233
  videoCallProduct: Product | null;
@@ -234,6 +239,7 @@ export declare class ProductListComponent extends BaseSection implements OnDestr
234
239
  isSubmitting: boolean;
235
240
  scheduled: boolean;
236
241
  scheduleVideoCall(): void;
242
+ continueVideoCallBooking(): void;
237
243
  resetValidationErrors(): void;
238
244
  resetForm(): void;
239
245
  onInputChange(field: any): void;
@@ -0,0 +1,38 @@
1
+ import { OnInit } from '@angular/core';
2
+ import { MatDialog, MatDialogRef } from '@angular/material/dialog';
3
+ import { BookingProductCartService, BookingCartMode } from '../../services/booking-product-cart.service';
4
+ import { StorageServiceService } from '../../services/storage.service';
5
+ import { OrderedItems } from '../../ecommerce/styles/OrderedItems.modal';
6
+ import * as i0 from "@angular/core";
7
+ interface BookingCartGroup {
8
+ mode: BookingCartMode;
9
+ title: string;
10
+ items: OrderedItems[];
11
+ }
12
+ /**
13
+ * Shared "grouped booking cart" view — one section per non-empty mode (Home Visit / Video Call),
14
+ * each with its own Continue Booking action, since a booking can only ever be one mode. Used
15
+ * both as the header's Bookings drawer (opened via MatDialog, panelClass 'sidepanel-class', same
16
+ * convention as the rest of this app's side panels) and embedded inline in the Cart page's
17
+ * Booking Cart tab, so the two surfaces never show different data.
18
+ */
19
+ export declare class BookingCartGroupsComponent implements OnInit {
20
+ private readonly bookingProductCartService;
21
+ private readonly storageService;
22
+ private readonly matDialog;
23
+ private readonly dialogRef;
24
+ groups: BookingCartGroup[];
25
+ loading: boolean;
26
+ constructor(bookingProductCartService: BookingProductCartService, storageService: StorageServiceService, matDialog: MatDialog, dialogRef: MatDialogRef<BookingCartGroupsComponent>);
27
+ ngOnInit(): void;
28
+ load(): Promise<void>;
29
+ get isEmpty(): boolean;
30
+ get dialogRefPresent(): boolean;
31
+ removeItem(group: BookingCartGroup, item: OrderedItems): Promise<void>;
32
+ close(): void;
33
+ browse(): void;
34
+ continueBooking(group: BookingCartGroup): void;
35
+ static ɵfac: i0.ɵɵFactoryDeclaration<BookingCartGroupsComponent, [null, null, null, { optional: true; }]>;
36
+ static ɵcmp: i0.ɵɵComponentDeclaration<BookingCartGroupsComponent, "simpo-booking-cart-groups", never, {}, {}, never, never, true, never>;
37
+ }
38
+ export {};
@@ -27,6 +27,7 @@ export declare class ScheduleVideoCallComponent implements OnInit {
27
27
  scheduled: boolean;
28
28
  resetValidationErrors(): void;
29
29
  scheduleVideoCall(): void;
30
+ continueBooking(): void;
30
31
  selectedItems(item: any): void;
31
32
  static ɵfac: i0.ɵɵFactoryDeclaration<ScheduleVideoCallComponent, never>;
32
33
  static ɵcmp: i0.ɵɵComponentDeclaration<ScheduleVideoCallComponent, "simpo-schedule-video-call", never, {}, {}, never, never, true, never>;
@@ -61,6 +61,7 @@ export declare class HeaderSectionComponent implements OnInit, AfterViewInit, On
61
61
  get getUserName(): string | undefined;
62
62
  goToWishlist(): void;
63
63
  goToCart(): void;
64
+ goToBookings(): void;
64
65
  applyFilter(value: any, type: string): void;
65
66
  movingText?: MovingTextModal;
66
67
  toShowInJewellery: boolean;
@@ -114,6 +115,7 @@ export declare class HeaderSectionComponent implements OnInit, AfterViewInit, On
114
115
  get showMobileHomeIcon(): boolean;
115
116
  get getCartItemsCount(): number;
116
117
  get getWishlistItemsCount(): number;
118
+ get getBookingItemsCount(): number;
117
119
  get getCartTotalAmount(): number;
118
120
  get getHeaderStyling(): Header_Type | undefined;
119
121
  get isMobile(): boolean;
@@ -43,6 +43,7 @@ export declare class NavbarSectionComponent implements OnInit {
43
43
  goToAccount(): void;
44
44
  goToWishlist(): void;
45
45
  goToCart(): void;
46
+ goToBookings(): void;
46
47
  applyFilter(value: any, type: string): void;
47
48
  onStickyScrolled(scrolled: boolean): void;
48
49
  ngOnInit(): void;
@@ -69,6 +70,7 @@ export declare class NavbarSectionComponent implements OnInit {
69
70
  get canShowMobileFooter(): boolean;
70
71
  get showMobileHomeIcon(): boolean;
71
72
  get getCartItemsCount(): number;
73
+ get getBookingItemsCount(): number;
72
74
  get getHeaderStyling(): HEADER_STYLING | undefined;
73
75
  get isMobile(): boolean;
74
76
  getKeys(object: any): string[];
@@ -20,6 +20,10 @@ export declare class StorageServiceService {
20
20
  get getTotalCartItems(): number;
21
21
  private totalWishlistItems;
22
22
  get getTotalWishlistItems(): number;
23
+ /** Combined count across HOME_VISIT_CART + VIDEO_CALL_CART, for the header Bookings badge. */
24
+ private totalBookingItems;
25
+ get getTotalBookingItems(): number;
26
+ calculateBookingCartTotals(): void;
23
27
  calculateCartTotals(): void;
24
28
  calculateWishlistTotals(): void;
25
29
  databaseName: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "simpo-component-library",
3
- "version": "3.6.934",
3
+ "version": "3.6.935",
4
4
  "peerDependencies": {
5
5
  "@angular/common": "^17.2.0",
6
6
  "@angular/core": "^17.2.0",
Binary file