simpo-component-library 3.6.963 → 3.6.967

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.
@@ -0,0 +1,13 @@
1
+ export declare class BlogCategory {
2
+ id: string;
3
+ businessId: string;
4
+ categoryName: string;
5
+ description: string;
6
+ blogsCreatedCount: number;
7
+ createdById: string;
8
+ createdByName: string;
9
+ createdTimeStamp: string;
10
+ constructor(json?: {
11
+ [key: string]: any;
12
+ });
13
+ }
@@ -1,21 +1,34 @@
1
1
  import { EventsService } from '../../services/events.service';
2
2
  import { BlogListContentModel, BlogListSectionModel, BlogListStylesModel } from './blog-list.model';
3
+ import { RestService } from '../../services/rest.service';
4
+ import { StorageLike } from '../../services/storage-like';
5
+ import { BlogCategory } from './blog-category.model';
3
6
  import { SPACING } from '../../directive/content-title-spacing.directive';
4
7
  import BaseSection from '../BaseSection';
5
8
  import { BackgroundModel, LayOutModel } from '../../styles/style.model';
6
9
  import * as i0 from "@angular/core";
7
10
  export declare class BlogListComponent extends BaseSection {
8
11
  private _eventService;
12
+ private readonly restService;
13
+ private readonly storage;
9
14
  responseData: any[];
10
15
  index?: number;
11
16
  edit?: boolean;
12
17
  customClass?: string;
13
18
  data?: BlogListSectionModel;
14
19
  nextComponentColor?: BackgroundModel;
15
- constructor(_eventService: EventsService);
20
+ categoryList: BlogCategory[];
21
+ selectedCategoryId: string | null | undefined;
22
+ filteredBlogs: any[] | null;
23
+ apiLoading: boolean;
24
+ constructor(_eventService: EventsService, restService: RestService, storage: StorageLike);
16
25
  style?: BlogListStylesModel;
17
26
  blogContent?: BlogListContentModel;
18
27
  ngOnInit(): void;
28
+ get businessId(): string | null;
29
+ get displayedBlogs(): any[];
30
+ loadBlogCategories(): void;
31
+ selectCategory(categoryId: string | null): void;
19
32
  get headingSpace(): SPACING;
20
33
  get stylesLayout(): LayOutModel;
21
34
  getBlogById(blogId: any): void;
@@ -1,11 +1,35 @@
1
+ import { AfterViewInit, ElementRef, OnChanges, OnDestroy, OnInit, SimpleChanges } from '@angular/core';
1
2
  import { EventsService } from './../../services/events.service';
2
3
  import * as i0 from "@angular/core";
3
- export declare class ViewBlogComponent {
4
+ interface TocItem {
5
+ id: string;
6
+ text: string;
7
+ }
8
+ export declare class ViewBlogComponent implements OnInit, OnChanges, AfterViewInit, OnDestroy {
4
9
  private readonly _eventService;
10
+ private readonly _elementRef;
5
11
  responseData: any;
6
- constructor(_eventService: EventsService);
12
+ tocItems: TocItem[];
13
+ tocOpen: boolean;
14
+ activeTocId: string | null;
15
+ private readonly headingBlockIds;
16
+ private readonly isBrowser;
17
+ private tocObserver?;
18
+ constructor(_eventService: EventsService, _elementRef: ElementRef<HTMLElement>, platformId: object);
7
19
  ngOnInit(): void;
20
+ ngOnChanges(changes: SimpleChanges): void;
21
+ ngAfterViewInit(): void;
22
+ ngOnDestroy(): void;
8
23
  editSection(): void;
24
+ scrollToBlock(event: Event, blockId: string): void;
25
+ private buildTableOfContents;
26
+ isTocAnchor(blockId: string): boolean;
27
+ hasVisibleText(html: string | undefined): boolean;
28
+ private getHeadingCandidate;
29
+ private getBoldParagraphHeading;
30
+ private stripHtml;
31
+ private setupScrollSpy;
9
32
  static ɵfac: i0.ɵɵFactoryDeclaration<ViewBlogComponent, never>;
10
33
  static ɵcmp: i0.ɵɵComponentDeclaration<ViewBlogComponent, "simpo-view-blog", never, { "responseData": { "alias": "responseData"; "required": false; }; }, {}, never, never, true, never>;
11
34
  }
35
+ export {};
@@ -1,10 +1,10 @@
1
- import { HttpClient } from "@angular/common/http";
2
- import { OnDestroy } from "@angular/core";
3
- import { Observable } from "rxjs";
4
- import { Review } from "../ecommerce/styles/review.modal";
5
- import { DeviceInfo } from "../ecommerce/styles/user.modal";
6
- import { checkItemAlreadyAdded, syncItemToServerDBRequest } from "../ecommerce/styles/product.modal";
7
- import { CookieService } from "ngx-cookie-service";
1
+ import { HttpClient } from '@angular/common/http';
2
+ import { OnDestroy } from '@angular/core';
3
+ import { Observable } from 'rxjs';
4
+ import { Review } from '../ecommerce/styles/review.modal';
5
+ import { DeviceInfo } from '../ecommerce/styles/user.modal';
6
+ import { checkItemAlreadyAdded, syncItemToServerDBRequest } from '../ecommerce/styles/product.modal';
7
+ import { CookieService } from 'ngx-cookie-service';
8
8
  import { StorageLike } from '../services/storage-like';
9
9
  import * as i0 from "@angular/core";
10
10
  export declare class RestService implements OnDestroy {
@@ -27,6 +27,8 @@ export declare class RestService implements OnDestroy {
27
27
  getFeaturedProduct(collectionId: string | undefined | null): Observable<any>;
28
28
  getCategoriesByCollectionId(collectionId: string): Observable<any>;
29
29
  getAllCategoriesByBusinessId(payload: any): Observable<Object>;
30
+ getBlogCategories(businessId: string): Observable<any>;
31
+ getBlogsByCategory(businessId: string, categoryId: string): Observable<Object>;
30
32
  getPassbookOrderStatus(orderId: any): Observable<Object>;
31
33
  getProductBySelectedCategory(categoryId: string): Observable<Object>;
32
34
  getAllSchemes(userId?: any, storeId?: any): any;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "simpo-component-library",
3
- "version": "3.6.963",
3
+ "version": "3.6.967",
4
4
  "peerDependencies": {
5
5
  "@angular/common": "^17.2.0",
6
6
  "@angular/core": "^17.2.0",
Binary file