@idsoftsource/initial-process 2.2.9 → 2.3.1

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/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import * as i0 from '@angular/core';
2
- import { InjectionToken, OnInit, ElementRef, EventEmitter, TemplateRef, OnChanges, AfterViewInit, Injector, ChangeDetectorRef, SimpleChanges, ViewContainerRef, OnDestroy, ComponentFactoryResolver, Renderer2, ModuleWithProviders, PipeTransform, NgZone } from '@angular/core';
2
+ import { InjectionToken, OnInit, ElementRef, EventEmitter, TemplateRef, OnDestroy, AfterViewInit, Injector, OnChanges, ChangeDetectorRef, SimpleChanges, ViewContainerRef, ComponentFactoryResolver, Renderer2, ModuleWithProviders, PipeTransform, NgZone } from '@angular/core';
3
3
  import * as _angular_forms from '@angular/forms';
4
4
  import { FormGroup, FormBuilder, FormControl, FormArray, UntypedFormGroup, UntypedFormBuilder, ControlValueAccessor, NgForm, AbstractControl } from '@angular/forms';
5
5
  import * as i17 from '@angular/router';
@@ -170,17 +170,6 @@ interface PrivacyAndTerms {
170
170
  websiteurl?: string | null;
171
171
  currentYear?: any | null;
172
172
  }
173
- /** Raw section shape as stored/retrieved from DB */
174
- interface TermsSection {
175
- id: string;
176
- versionName: string;
177
- /** HTML string — use {{fieldName}} tokens for PrivacyAndTerms values */
178
- content: string;
179
- orderby: number;
180
- createdDate: string;
181
- createdBy: string;
182
- type: number;
183
- }
184
173
 
185
174
  interface GridResult<TReadModel> {
186
175
  data: TReadModel[];
@@ -293,6 +282,16 @@ interface UserUpdateModel {
293
282
  };
294
283
  }
295
284
 
285
+ interface TermsandConditionModel {
286
+ versionName: string;
287
+ content: string;
288
+ orderby: number;
289
+ createdDate: string;
290
+ createdBy: string;
291
+ type: number;
292
+ id: string;
293
+ }
294
+
296
295
  declare class UserDetailService {
297
296
  private http;
298
297
  private readonly baseUrl;
@@ -306,6 +305,9 @@ declare class UserDetailService {
306
305
  resetPassword(model: any): Observable<Result>;
307
306
  private buildParams;
308
307
  getByUserId(userId: string, query?: any): Observable<UserAccountReadModel>;
308
+ getTermsAndConditions(query: {
309
+ type: number;
310
+ }): Observable<TermsandConditionModel[]>;
309
311
  static ɵfac: i0.ɵɵFactoryDeclaration<UserDetailService, never>;
310
312
  static ɵprov: i0.ɵɵInjectableDeclaration<UserDetailService>;
311
313
  }
@@ -915,7 +917,7 @@ declare class InitialProcessComponent implements OnInit {
915
917
  static ɵcmp: i0.ɵɵComponentDeclaration<InitialProcessComponent, "app-initial-process", never, {}, {}, never, never, false, never>;
916
918
  }
917
919
 
918
- interface ProcessedSection {
920
+ interface ProcessedSection$1 {
919
921
  id: string;
920
922
  versionName: string;
921
923
  content: SafeHtml;
@@ -924,38 +926,56 @@ interface ProcessedSection {
924
926
  createdBy: string;
925
927
  type: number;
926
928
  }
927
- declare class TermsConditionsComponent implements OnChanges {
929
+ declare class TermsConditionsComponent implements OnInit, OnDestroy {
928
930
  private sanitizer;
931
+ private userDetailsService;
929
932
  title: string;
930
933
  branding: {
931
934
  logo: string;
932
935
  displayName: string;
933
936
  };
934
937
  PrivacyAndTerms: PrivacyAndTerms;
935
- /** Raw sections array parsed from DB JSON — parent does JSON.parse(), passes the array here */
936
- sections: TermsSection[];
937
- parsedSections: ProcessedSection[];
938
- constructor(sanitizer: DomSanitizer);
939
- ngOnChanges(): void;
938
+ parsedSections: ProcessedSection$1[];
939
+ isLoading: boolean;
940
+ private destroy$;
941
+ constructor(sanitizer: DomSanitizer, userDetailsService: UserDetailService);
942
+ ngOnInit(): void;
943
+ ngOnDestroy(): void;
944
+ private getTermsAndConditions;
940
945
  private buildSections;
941
- /**
942
- * 1. Unescape backslash-escaped quotes left over from JSON string storage (\" → ")
943
- * 2. Replace {{PrivacyAndTerms?.field}} and {{field}} tokens with live values
944
- * 3. Convert literal \n sequences to <br> for HTML line breaks
945
- */
946
946
  private interpolate;
947
947
  isFilteredBrand(): boolean;
948
948
  static ɵfac: i0.ɵɵFactoryDeclaration<TermsConditionsComponent, never>;
949
- static ɵcmp: i0.ɵɵComponentDeclaration<TermsConditionsComponent, "app-terms-conditions", never, { "title": { "alias": "title"; "required": false; }; "branding": { "alias": "branding"; "required": false; }; "PrivacyAndTerms": { "alias": "PrivacyAndTerms"; "required": false; }; "sections": { "alias": "sections"; "required": false; }; }, {}, never, never, false, never>;
949
+ static ɵcmp: i0.ɵɵComponentDeclaration<TermsConditionsComponent, "app-terms-conditions", never, { "title": { "alias": "title"; "required": false; }; "branding": { "alias": "branding"; "required": false; }; "PrivacyAndTerms": { "alias": "PrivacyAndTerms"; "required": false; }; }, {}, never, never, false, never>;
950
950
  }
951
951
 
952
- declare class PrivacyPolicyComponent {
952
+ interface ProcessedSection {
953
+ id: string;
954
+ versionName: string;
955
+ content: SafeHtml;
956
+ orderby: number;
957
+ createdDate: string;
958
+ createdBy: string;
959
+ type: number;
960
+ }
961
+ declare class PrivacyPolicyComponent implements OnInit, OnDestroy {
962
+ private sanitizer;
963
+ private userDetailsService;
953
964
  title: string;
954
965
  branding: {
955
966
  logo: string;
956
967
  displayName: string;
957
968
  };
958
969
  PrivacyAndTerms: PrivacyAndTerms;
970
+ parsedSections: ProcessedSection[];
971
+ isLoading: boolean;
972
+ private destroy$;
973
+ constructor(sanitizer: DomSanitizer, userDetailsService: UserDetailService);
974
+ ngOnInit(): void;
975
+ ngOnDestroy(): void;
976
+ private getPrivacyPolicy;
977
+ private buildSections;
978
+ private interpolate;
959
979
  isFilteredBrand(): boolean;
960
980
  static ɵfac: i0.ɵɵFactoryDeclaration<PrivacyPolicyComponent, never>;
961
981
  static ɵcmp: i0.ɵɵComponentDeclaration<PrivacyPolicyComponent, "app-privacy-policy", never, { "title": { "alias": "title"; "required": false; }; "branding": { "alias": "branding"; "required": false; }; "PrivacyAndTerms": { "alias": "PrivacyAndTerms"; "required": false; }; }, {}, never, never, false, never>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@idsoftsource/initial-process",
3
- "version": "2.2.9",
3
+ "version": "2.3.1",
4
4
  "peerDependencies": {
5
5
  "@angular/common": "^20.0.0",
6
6
  "@angular/core": "^20.0.0",