@rangertechnologies/ngnxt 2.1.83 → 2.1.85

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.
@@ -29,6 +29,9 @@ import { NgSelectModule } from '@ng-select/ng-select';
29
29
  import * as i9$1 from '@angular/material/tooltip';
30
30
  import { MatTooltipModule } from '@angular/material/tooltip';
31
31
  import * as i10 from '@angular/cdk/bidi';
32
+ import * as i4$2 from '@angular/cdk/drag-drop';
33
+ import { moveItemInArray, DragDropModule } from '@angular/cdk/drag-drop';
34
+ import { v4 } from 'uuid';
32
35
 
33
36
  class NxtAppService {
34
37
  constructor() { }
@@ -4064,8 +4067,8 @@ class DataService {
4064
4067
  const headers = new HttpHeaders().set('Authorization', `${tkn}`);
4065
4068
  headers.append('Accept', 'application/json');
4066
4069
  headers.append('Access-Control-Allow-Origin', '*');
4067
- // Use Shengel Go Server IP/Domain https://dev-api.shengelgo.com
4068
- this.http.get('https://dev-api.shengelgo.com/nxt/api/process/?dataType=' + params[0] + '&operation=' + params[1] + '&param=' + params[2], { headers: headers, observe: 'response' })
4070
+ // MR 23JAN24 - This should be removed, for now testing with dev-hse-api
4071
+ this.http.get('https://dev-hse-api.rangerfusion.com/nxt/api/process/?dataType=' + params[0] + '&operation=' + params[1] + '&param=' + params[2], { headers: headers, observe: 'response' })
4069
4072
  .subscribe(response => {
4070
4073
  if (response.status == 200) {
4071
4074
  resolve(response.body);
@@ -4278,7 +4281,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
4278
4281
 
4279
4282
  // Changes commented out due to Angular version compatibility; will apply after upgrade.
4280
4283
  // // RS 06JAN2025
4281
- // RS 17JAN2025
4284
+ // RS 17JAN2025
4282
4285
  // An array fontFamilyArr is created containing a list of font family names as strings.
4283
4286
  const fontFamilyArr = ["Roboto", "Roboto Condensed", "Arial", "Verdana", "Tahoma", "Trebuchet MS",
4284
4287
  "Georgia", "Times New Roman", "Courier New", "Palatino Linotype",
@@ -4288,7 +4291,7 @@ const fontFamilyArr = ["Roboto", "Roboto Condensed", "Arial", "Verdana", "Tahoma
4288
4291
  Quill.register('modules/mention', Mention);
4289
4292
  ImageResizor.Quill = Quill;
4290
4293
  Quill.register('modules/imageResizor', ImageResizor);
4291
- // RS 17JAN2025
4294
+ // RS 17JAN2025
4292
4295
  //The Quill font style attributor is imported and it is registered with Quil
4293
4296
  let fonts = Quill.import("attributors/style/font");
4294
4297
  fonts.whitelist = fontFamilyArr;
@@ -4394,13 +4397,28 @@ class CustomRichTextComponent {
4394
4397
  }
4395
4398
  }
4396
4399
  }
4397
- onEditorChange(event) {
4398
- if (event && event.html !== undefined) {
4399
- this.textValueChange.emit(event.html);
4400
- }
4401
- else {
4402
- this.textValueChange.emit('');
4403
- }
4400
+ // onEditorChange(event: any): void {
4401
+ // if (event && event.html !== undefined) {
4402
+ // this.textValueChange.emit(event.html);
4403
+ // } else {
4404
+ // this.textValueChange.emit('');
4405
+ // }
4406
+ // }
4407
+ // onEditorChange(event: any): void {
4408
+ // console.log('Typing detected...', event.html);
4409
+ // if (this.typingTimer) {
4410
+ // clearTimeout(this.typingTimer); // Clear previous timer
4411
+ // }
4412
+ // this.typingTimer = setTimeout(() => {
4413
+ // console.log('Debounced event fired:', event.html);
4414
+ // const newValue = event?.html ? event.html : ''; // Ensure empty values are handled
4415
+ // this.textValueChange.emit(newValue);
4416
+ // }, this.doneTypingInterval);
4417
+ // }
4418
+ onEditorBlur() {
4419
+ // Only emit if we have a value change
4420
+ const currentValue = this.value || '';
4421
+ this.textValueChange.emit(currentValue);
4404
4422
  }
4405
4423
  // Added ngOnDestroy to prevent memory leaks
4406
4424
  ngOnDestroy() {
@@ -4409,11 +4427,11 @@ class CustomRichTextComponent {
4409
4427
  }
4410
4428
  }
4411
4429
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: CustomRichTextComponent, deps: [{ token: I18nService }, { token: ChangeService }], target: i0.ɵɵFactoryTarget.Component });
4412
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: CustomRichTextComponent, isStandalone: true, selector: "app-custom-rich-text", inputs: { value: "value", placeholder: "placeholder", error: "error", question: "question", rows: "rows", readOnly: "readOnly", minLength: "minLength", maxLength: "maxLength" }, outputs: { textValueChange: "textValueChange" }, ngImport: i0, template: "<!-- RS 06JAN25 -->\r\n<div class=\"rich-text-container\">\r\n <quill-editor\r\n [(ngModel)]=\"value\"\r\n [placeholder]=\"placeholder\"\r\n [modules]=\"quillConfiguration\"\r\n [readOnly]=\"readOnly\"\r\n (onContentChanged)=\"onEditorChange($event)\"\r\n [class.error]=\"error\">\r\n </quill-editor>\r\n <div *ngIf=\"error\" class=\"error-message\">\r\n {{ error }}\r\n </div>\r\n</div>", styles: [".rich-text-container{width:100%;margin:10px 0}.error{border:1px solid red}:is() .ql-editor img{cursor:pointer}:is() .image-resizer{display:block!important;visibility:visible!important}:is() .ql-editor .image-resizer{border:1px dashed #000;position:absolute}:is() .ql-editor .image-resizer .handle{background-color:#000;border:1px solid #fff;border-radius:50%;height:12px;width:12px;position:absolute}quill-editor{width:100%}\n"], dependencies: [{ kind: "component", type: QuillEditorComponent, selector: "quill-editor" }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
4430
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: CustomRichTextComponent, isStandalone: true, selector: "app-custom-rich-text", inputs: { value: "value", placeholder: "placeholder", error: "error", question: "question", rows: "rows", readOnly: "readOnly", minLength: "minLength", maxLength: "maxLength" }, outputs: { textValueChange: "textValueChange" }, ngImport: i0, template: "<!-- RS 06JAN25 -->\r\n<div class=\"rich-text-container\">\r\n <quill-editor\r\n [(ngModel)]=\"value\"\r\n [placeholder]=\"placeholder\"\r\n [modules]=\"quillConfiguration\"\r\n [readOnly]=\"readOnly\"\r\n (onBlur)=\"onEditorBlur()\"\r\n [class.error]=\"error\">\r\n </quill-editor>\r\n <div *ngIf=\"error\" class=\"error-message\">\r\n {{ error }}\r\n </div>\r\n</div>", styles: [".rich-text-container{width:100%;margin:10px 0}.error{border:1px solid red}:is() .ql-editor img{cursor:pointer}:is() .image-resizer{display:block!important;visibility:visible!important}:is() .ql-editor .image-resizer{border:1px dashed #000;position:absolute}:is() .ql-editor .image-resizer .handle{background-color:#000;border:1px solid #fff;border-radius:50%;height:12px;width:12px;position:absolute}quill-editor{width:100%}\n"], dependencies: [{ kind: "component", type: QuillEditorComponent, selector: "quill-editor" }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
4413
4431
  }
4414
4432
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: CustomRichTextComponent, decorators: [{
4415
4433
  type: Component,
4416
- args: [{ imports: [QuillEditorComponent, FormsModule, CommonModule], selector: 'app-custom-rich-text', standalone: true, template: "<!-- RS 06JAN25 -->\r\n<div class=\"rich-text-container\">\r\n <quill-editor\r\n [(ngModel)]=\"value\"\r\n [placeholder]=\"placeholder\"\r\n [modules]=\"quillConfiguration\"\r\n [readOnly]=\"readOnly\"\r\n (onContentChanged)=\"onEditorChange($event)\"\r\n [class.error]=\"error\">\r\n </quill-editor>\r\n <div *ngIf=\"error\" class=\"error-message\">\r\n {{ error }}\r\n </div>\r\n</div>", styles: [".rich-text-container{width:100%;margin:10px 0}.error{border:1px solid red}:is() .ql-editor img{cursor:pointer}:is() .image-resizer{display:block!important;visibility:visible!important}:is() .ql-editor .image-resizer{border:1px dashed #000;position:absolute}:is() .ql-editor .image-resizer .handle{background-color:#000;border:1px solid #fff;border-radius:50%;height:12px;width:12px;position:absolute}quill-editor{width:100%}\n"] }]
4434
+ args: [{ imports: [QuillEditorComponent, FormsModule, CommonModule], selector: 'app-custom-rich-text', standalone: true, template: "<!-- RS 06JAN25 -->\r\n<div class=\"rich-text-container\">\r\n <quill-editor\r\n [(ngModel)]=\"value\"\r\n [placeholder]=\"placeholder\"\r\n [modules]=\"quillConfiguration\"\r\n [readOnly]=\"readOnly\"\r\n (onBlur)=\"onEditorBlur()\"\r\n [class.error]=\"error\">\r\n </quill-editor>\r\n <div *ngIf=\"error\" class=\"error-message\">\r\n {{ error }}\r\n </div>\r\n</div>", styles: [".rich-text-container{width:100%;margin:10px 0}.error{border:1px solid red}:is() .ql-editor img{cursor:pointer}:is() .image-resizer{display:block!important;visibility:visible!important}:is() .ql-editor .image-resizer{border:1px dashed #000;position:absolute}:is() .ql-editor .image-resizer .handle{background-color:#000;border:1px solid #fff;border-radius:50%;height:12px;width:12px;position:absolute}quill-editor{width:100%}\n"] }]
4417
4435
  }], ctorParameters: () => [{ type: I18nService }, { type: ChangeService }], propDecorators: { value: [{
4418
4436
  type: Input
4419
4437
  }], placeholder: [{
@@ -4470,6 +4488,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
4470
4488
  class PickLocationComponent {
4471
4489
  i18nService;
4472
4490
  ngZone;
4491
+ cdr;
4473
4492
  latitude = null;
4474
4493
  longitude = null;
4475
4494
  zoom = 10;
@@ -4488,9 +4507,10 @@ class PickLocationComponent {
4488
4507
  apiKey; // HA10012024 declared Api key to src
4489
4508
  constructor(
4490
4509
  // private mapsAPILoader: MapsAPILoader,
4491
- i18nService, ngZone) {
4510
+ i18nService, ngZone, cdr) {
4492
4511
  this.i18nService = i18nService;
4493
4512
  this.ngZone = ngZone;
4513
+ this.cdr = cdr;
4494
4514
  // HA09012024 is to avoid google is undefined error and calling the below created function
4495
4515
  }
4496
4516
  ngOnInit() {
@@ -4507,6 +4527,32 @@ class PickLocationComponent {
4507
4527
  });
4508
4528
  }
4509
4529
  }
4530
+ // RS 23JAN2025
4531
+ ngOnChanges(changes) {
4532
+ if (changes['address'] && changes['address'].currentValue !== changes['address'].previousValue) {
4533
+ // Ensure latitude & longitude update when the address changes
4534
+ if (this.address) {
4535
+ this.geoCoder.geocode({ address: this.address }, (results, status) => {
4536
+ if (status === 'OK' && results[0]?.geometry?.location) {
4537
+ this.latitude = results[0].geometry.location.lat();
4538
+ this.longitude = results[0].geometry.location.lng();
4539
+ this.markerPosition = { lat: this.latitude, lng: this.longitude };
4540
+ this.center = { lat: this.latitude, lng: this.longitude };
4541
+ this.zoom = 18;
4542
+ this.cdr.detectChanges(); // Force Angular to update the UI
4543
+ }
4544
+ });
4545
+ }
4546
+ else {
4547
+ // Reset if no address is provided
4548
+ this.latitude = null;
4549
+ this.longitude = null;
4550
+ this.markerPosition = null;
4551
+ this.center = null;
4552
+ this.cdr.detectChanges(); // FORCE UI UPDATE
4553
+ }
4554
+ }
4555
+ }
4510
4556
  // HA09012024 is to avoid google is undefined error
4511
4557
  loadGoogleMapsScript() {
4512
4558
  const script = document.createElement('script');
@@ -4627,13 +4673,13 @@ class PickLocationComponent {
4627
4673
  closeModal() {
4628
4674
  this.showModal = false;
4629
4675
  }
4630
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: PickLocationComponent, deps: [{ token: I18nService }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component });
4631
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: PickLocationComponent, selector: "app-pick-location", inputs: { address: "address", question: "question", apiKey: "apiKey" }, outputs: { locationSelected: "locationSelected" }, viewQueries: [{ propertyName: "searchElementRef", first: true, predicate: ["search"], descendants: true, static: true }], ngImport: i0, template: "<div>\r\n <!-- <label class=\"she-label\">Location</label> -->\r\n <!-- HA 19DEC23 For translation -->\r\n <input #search class=\"she-line-input form-control\" type=\"text\" placeholder=\"{{ 'enterLocation' | i18n:i18nService.currentLanguage }}\"\r\n (keydown.enter)=\"$event.preventDefault()\" placeholder=\"{{ 'searchNearestLocation' | i18n:i18nService.currentLanguage }}\" autocorrect=\"off\"\r\n autocapitalize=\"off\" spellcheck=\"off\" type=\"text\" [(ngModel)]=\"address\"\r\n >\r\n <a (click)=\"openMap()\"\r\n style=\"color:#48B7FF;position:relative;top:5px;cursor: pointer;\">\r\n <i class=\"fa fa-location-arrow\" aria-hidden=\"true\">\r\n <!-- HA 19DEC23 For translation -->\r\n </i> {{ 'pickLocation' | i18n:i18nService.currentLanguage }}</a>\r\n</div>\r\n\r\n<div class=\"map-overlay\" *ngIf=\"showModal\">\r\n <div class=\"map-modal\">\r\n <div class=\"map-modal-content\">\r\n <div class=\"map-modal-header\">\r\n <!-- HA 19DEC23 For translation -->\r\n <h4>{{ 'pickYourLocation' | i18n:i18nService.currentLanguage }}</h4>\r\n <button class=\"close-button\" (click)=\"closeModal()\">X</button>\r\n </div>\r\n <!-- Modal content goes here -->\r\n <!-- <agm-map [latitude]=\"latitude\" [longitude]=\"longitude\" [zoom]=\"zoom\" (mapClick)=\"markerDragEnd($event)\"\r\n [fullscreenControl]=\"true\">\r\n <agm-marker [latitude]=\"latitude\" [longitude]=\"longitude\" [markerDraggable]=\"true\"\r\n (dragEnd)=\"markerDragEnd($event)\"></agm-marker>\r\n </agm-map> -->\r\n <google-map [latitude]=\"latitude\" [longitude]=\"longitude\" [zoom]=\"zoom\" [center]=\"center\" (mapClick)=\"onMapClick($event)\">\r\n <map-marker [position]=\"markerPosition\" [options]=\"markerOptions\"></map-marker>\r\n </google-map>\r\n </div>\r\n </div>\r\n</div>\r\n\r\n\r\n\r\n\r\n\r\n\r\n", styles: [".she-label{font-weight:400;color:#9a9a9a;padding-bottom:5px;padding-top:5px;padding-right:15px;font-size:14px}.she-line-input{border:none;background:#fff;border-bottom:1px solid #eeeeee;border-radius:0}.fa-location-arrow:before{content:\"\\f124\"}google-map .map-container{width:auto!important}.map-overlay{position:fixed;top:0;left:0;width:100%;height:100%;background-color:#00000080;display:flex;align-items:center;justify-content:center;z-index:1}.map-modal{width:600px;background-color:#fff;border-radius:5px;box-shadow:0 2px 4px #0003}.map-modal-header{display:flex;align-items:center;justify-content:space-between;padding:0 0 10px;background-color:#fff;border-bottom:2px solid #e5e5e5}.map-modal-header h3{margin:0}.map-modal-content{padding:20px}.close-button{border:none;cursor:pointer;font-size:21px;font-weight:700;line-height:1;color:#000;text-shadow:0 1px 0 #fff;opacity:.2}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i4.GoogleMap, selector: "google-map", inputs: ["height", "width", "mapId", "mapTypeId", "center", "zoom", "options"], outputs: ["mapInitialized", "authFailure", "boundsChanged", "centerChanged", "mapClick", "mapDblclick", "mapDrag", "mapDragend", "mapDragstart", "headingChanged", "idle", "maptypeidChanged", "mapMousemove", "mapMouseout", "mapMouseover", "projectionChanged", "mapRightclick", "tilesloaded", "tiltChanged", "zoomChanged"], exportAs: ["googleMap"] }, { kind: "directive", type: i4.MapMarker, selector: "map-marker", inputs: ["title", "position", "label", "clickable", "options", "icon", "visible"], outputs: ["animationChanged", "mapClick", "clickableChanged", "cursorChanged", "mapDblclick", "mapDrag", "mapDragend", "draggableChanged", "mapDragstart", "flatChanged", "iconChanged", "mapMousedown", "mapMouseout", "mapMouseover", "mapMouseup", "positionChanged", "mapRightclick", "shapeChanged", "titleChanged", "visibleChanged", "zindexChanged", "markerInitialized"], exportAs: ["mapMarker"] }, { kind: "pipe", type: I18nPipe, name: "i18n" }] });
4676
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: PickLocationComponent, deps: [{ token: I18nService }, { token: i0.NgZone }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
4677
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: PickLocationComponent, selector: "app-pick-location", inputs: { address: "address", question: "question", apiKey: "apiKey" }, outputs: { locationSelected: "locationSelected" }, viewQueries: [{ propertyName: "searchElementRef", first: true, predicate: ["search"], descendants: true, static: true }], usesOnChanges: true, ngImport: i0, template: "<div>\r\n <!-- <label class=\"she-label\">Location</label> -->\r\n <!-- HA 19DEC23 For translation -->\r\n <input #search class=\"she-line-input form-control\" type=\"text\" placeholder=\"{{ 'enterLocation' | i18n:i18nService.currentLanguage }}\"\r\n (keydown.enter)=\"$event.preventDefault()\" placeholder=\"{{ 'searchNearestLocation' | i18n:i18nService.currentLanguage }}\" autocorrect=\"off\"\r\n autocapitalize=\"off\" spellcheck=\"off\" type=\"text\" [(ngModel)]=\"address\"\r\n >\r\n <a (click)=\"openMap()\"\r\n style=\"color:#48B7FF;position:relative;top:5px;cursor: pointer;\">\r\n <i class=\"fa fa-location-arrow\" aria-hidden=\"true\">\r\n <!-- HA 19DEC23 For translation -->\r\n </i> {{ 'pickLocation' | i18n:i18nService.currentLanguage }}</a>\r\n</div>\r\n\r\n<div class=\"map-overlay\" *ngIf=\"showModal\">\r\n <div class=\"map-modal\">\r\n <div class=\"map-modal-content\">\r\n <div class=\"map-modal-header\">\r\n <!-- HA 19DEC23 For translation -->\r\n <h4>{{ 'pickYourLocation' | i18n:i18nService.currentLanguage }}</h4>\r\n <button class=\"close-button\" (click)=\"closeModal()\">X</button>\r\n </div>\r\n <!-- Modal content goes here -->\r\n <!-- <agm-map [latitude]=\"latitude\" [longitude]=\"longitude\" [zoom]=\"zoom\" (mapClick)=\"markerDragEnd($event)\"\r\n [fullscreenControl]=\"true\">\r\n <agm-marker [latitude]=\"latitude\" [longitude]=\"longitude\" [markerDraggable]=\"true\"\r\n (dragEnd)=\"markerDragEnd($event)\"></agm-marker>\r\n </agm-map> -->\r\n <google-map [latitude]=\"latitude\" [longitude]=\"longitude\" [zoom]=\"zoom\" [center]=\"center\" (mapClick)=\"onMapClick($event)\">\r\n <map-marker [position]=\"markerPosition\" [options]=\"markerOptions\"></map-marker>\r\n </google-map>\r\n </div>\r\n </div>\r\n</div>\r\n\r\n\r\n\r\n\r\n\r\n\r\n", styles: [".she-label{font-weight:400;color:#9a9a9a;padding-bottom:5px;padding-top:5px;padding-right:15px;font-size:14px}.she-line-input{border:none;background:#fff;border-bottom:1px solid #eeeeee;border-radius:0}.fa-location-arrow:before{content:\"\\f124\"}google-map .map-container{width:auto!important}.map-overlay{position:fixed;top:0;left:0;width:100%;height:100%;background-color:#00000080;display:flex;align-items:center;justify-content:center;z-index:1}.map-modal{width:600px;background-color:#fff;border-radius:5px;box-shadow:0 2px 4px #0003}.map-modal-header{display:flex;align-items:center;justify-content:space-between;padding:0 0 10px;background-color:#fff;border-bottom:2px solid #e5e5e5}.map-modal-header h3{margin:0}.map-modal-content{padding:20px}.close-button{border:none;cursor:pointer;font-size:21px;font-weight:700;line-height:1;color:#000;text-shadow:0 1px 0 #fff;opacity:.2}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i4.GoogleMap, selector: "google-map", inputs: ["height", "width", "mapId", "mapTypeId", "center", "zoom", "options"], outputs: ["mapInitialized", "authFailure", "boundsChanged", "centerChanged", "mapClick", "mapDblclick", "mapDrag", "mapDragend", "mapDragstart", "headingChanged", "idle", "maptypeidChanged", "mapMousemove", "mapMouseout", "mapMouseover", "projectionChanged", "mapRightclick", "tilesloaded", "tiltChanged", "zoomChanged"], exportAs: ["googleMap"] }, { kind: "directive", type: i4.MapMarker, selector: "map-marker", inputs: ["title", "position", "label", "clickable", "options", "icon", "visible"], outputs: ["animationChanged", "mapClick", "clickableChanged", "cursorChanged", "mapDblclick", "mapDrag", "mapDragend", "draggableChanged", "mapDragstart", "flatChanged", "iconChanged", "mapMousedown", "mapMouseout", "mapMouseover", "mapMouseup", "positionChanged", "mapRightclick", "shapeChanged", "titleChanged", "visibleChanged", "zindexChanged", "markerInitialized"], exportAs: ["mapMarker"] }, { kind: "pipe", type: I18nPipe, name: "i18n" }] });
4632
4678
  }
4633
4679
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: PickLocationComponent, decorators: [{
4634
4680
  type: Component,
4635
4681
  args: [{ selector: 'app-pick-location', template: "<div>\r\n <!-- <label class=\"she-label\">Location</label> -->\r\n <!-- HA 19DEC23 For translation -->\r\n <input #search class=\"she-line-input form-control\" type=\"text\" placeholder=\"{{ 'enterLocation' | i18n:i18nService.currentLanguage }}\"\r\n (keydown.enter)=\"$event.preventDefault()\" placeholder=\"{{ 'searchNearestLocation' | i18n:i18nService.currentLanguage }}\" autocorrect=\"off\"\r\n autocapitalize=\"off\" spellcheck=\"off\" type=\"text\" [(ngModel)]=\"address\"\r\n >\r\n <a (click)=\"openMap()\"\r\n style=\"color:#48B7FF;position:relative;top:5px;cursor: pointer;\">\r\n <i class=\"fa fa-location-arrow\" aria-hidden=\"true\">\r\n <!-- HA 19DEC23 For translation -->\r\n </i> {{ 'pickLocation' | i18n:i18nService.currentLanguage }}</a>\r\n</div>\r\n\r\n<div class=\"map-overlay\" *ngIf=\"showModal\">\r\n <div class=\"map-modal\">\r\n <div class=\"map-modal-content\">\r\n <div class=\"map-modal-header\">\r\n <!-- HA 19DEC23 For translation -->\r\n <h4>{{ 'pickYourLocation' | i18n:i18nService.currentLanguage }}</h4>\r\n <button class=\"close-button\" (click)=\"closeModal()\">X</button>\r\n </div>\r\n <!-- Modal content goes here -->\r\n <!-- <agm-map [latitude]=\"latitude\" [longitude]=\"longitude\" [zoom]=\"zoom\" (mapClick)=\"markerDragEnd($event)\"\r\n [fullscreenControl]=\"true\">\r\n <agm-marker [latitude]=\"latitude\" [longitude]=\"longitude\" [markerDraggable]=\"true\"\r\n (dragEnd)=\"markerDragEnd($event)\"></agm-marker>\r\n </agm-map> -->\r\n <google-map [latitude]=\"latitude\" [longitude]=\"longitude\" [zoom]=\"zoom\" [center]=\"center\" (mapClick)=\"onMapClick($event)\">\r\n <map-marker [position]=\"markerPosition\" [options]=\"markerOptions\"></map-marker>\r\n </google-map>\r\n </div>\r\n </div>\r\n</div>\r\n\r\n\r\n\r\n\r\n\r\n\r\n", styles: [".she-label{font-weight:400;color:#9a9a9a;padding-bottom:5px;padding-top:5px;padding-right:15px;font-size:14px}.she-line-input{border:none;background:#fff;border-bottom:1px solid #eeeeee;border-radius:0}.fa-location-arrow:before{content:\"\\f124\"}google-map .map-container{width:auto!important}.map-overlay{position:fixed;top:0;left:0;width:100%;height:100%;background-color:#00000080;display:flex;align-items:center;justify-content:center;z-index:1}.map-modal{width:600px;background-color:#fff;border-radius:5px;box-shadow:0 2px 4px #0003}.map-modal-header{display:flex;align-items:center;justify-content:space-between;padding:0 0 10px;background-color:#fff;border-bottom:2px solid #e5e5e5}.map-modal-header h3{margin:0}.map-modal-content{padding:20px}.close-button{border:none;cursor:pointer;font-size:21px;font-weight:700;line-height:1;color:#000;text-shadow:0 1px 0 #fff;opacity:.2}\n"] }]
4636
- }], ctorParameters: () => [{ type: I18nService }, { type: i0.NgZone }], propDecorators: { searchElementRef: [{
4682
+ }], ctorParameters: () => [{ type: I18nService }, { type: i0.NgZone }, { type: i0.ChangeDetectorRef }], propDecorators: { searchElementRef: [{
4637
4683
  type: ViewChild,
4638
4684
  args: ['search', { static: true }]
4639
4685
  }], address: [{
@@ -10192,6 +10238,811 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
10192
10238
  }]
10193
10239
  }], ctorParameters: () => [{ type: i0.ViewContainerRef }] });
10194
10240
 
10241
+ // AP 22JAN25
10242
+ class FormBuilderService {
10243
+ formElements = [];
10244
+ formElementsSubject = new BehaviorSubject([]);
10245
+ selectedElementSubject = new BehaviorSubject(-1);
10246
+ elementComponent = null;
10247
+ book;
10248
+ formElements$ = this.formElementsSubject.asObservable();
10249
+ selectedElement$ = this.selectedElementSubject.asObservable();
10250
+ unique_id;
10251
+ tempElem;
10252
+ // book: { bookQuestionsMap: { unique_id: { subQuestions: any[]; }; }; };
10253
+ constructor() {
10254
+ // Load saved elements from localStorage
10255
+ const savedFormElements = localStorage.getItem('formElements');
10256
+ if (savedFormElements) {
10257
+ this.formElements = JSON.parse(savedFormElements);
10258
+ this.formElementsSubject.next([...this.formElements]);
10259
+ this.book = JSON.parse(localStorage.getItem('book') || '{}');
10260
+ this.unique_id = localStorage.getItem('unique_id');
10261
+ }
10262
+ }
10263
+ // Get the element component reference
10264
+ getElementComponent() {
10265
+ return this.elementComponent;
10266
+ }
10267
+ setElementComponent(component) {
10268
+ this.elementComponent = component;
10269
+ }
10270
+ // Add a new element to the form
10271
+ addElement(element, parentId = null) {
10272
+ // const savedFormElements = localStorage.getItem('formElements');
10273
+ console.log("aswin", this.formElements.length);
10274
+ if (this.formElements.length == 0) {
10275
+ console.log("savedFormElements", this.formElements);
10276
+ // this.formElements = JSON.parse(savedFormElements);
10277
+ // this.formElementsSubject.next([...this.formElements]);
10278
+ // this.book = JSON.parse(localStorage.getItem('book') || '{}');
10279
+ this.book = {};
10280
+ if (localStorage.getItem('status') == "edit") {
10281
+ this.unique_id = localStorage.getItem('unique_id');
10282
+ this.book = {
10283
+ 'bookQuestionsMap': {
10284
+ [this.unique_id]: {
10285
+ 'subQuestions': []
10286
+ }
10287
+ }
10288
+ };
10289
+ }
10290
+ else {
10291
+ this.unique_id = v4();
10292
+ this.book = {
10293
+ 'bookQuestionsMap': {
10294
+ [this.unique_id]: {
10295
+ 'subQuestions': []
10296
+ }
10297
+ }
10298
+ };
10299
+ }
10300
+ // this.unique_id = uuidv4();
10301
+ localStorage.setItem('book', JSON.stringify(this.book));
10302
+ localStorage.setItem('unique_id', this.unique_id);
10303
+ }
10304
+ this.formElements.push(element);
10305
+ localStorage.setItem('formElements', JSON.stringify(this.formElements));
10306
+ this.formElementsSubject.next([...this.formElements]);
10307
+ }
10308
+ updateElement(index, updates) {
10309
+ const elements = [...this.getElements()];
10310
+ if (elements[index]) {
10311
+ elements[index] = {
10312
+ ...elements[index],
10313
+ ...updates
10314
+ };
10315
+ this.formElementsSubject.next(elements);
10316
+ }
10317
+ if (index >= 0 && index < this.formElements.length) {
10318
+ const updatedElement = {
10319
+ ...this.formElements[index],
10320
+ ...updates
10321
+ };
10322
+ if (updates.required !== undefined) {
10323
+ if (updatedElement.questionText) {
10324
+ const questionText = updatedElement.questionText.replace(/\s*\*+$/, '');
10325
+ updatedElement.questionText = updates.required ? `${questionText} *` : questionText;
10326
+ }
10327
+ }
10328
+ // Handle special cases
10329
+ if (updates.required === true && updatedElement.questionText && !updatedElement.questionText.endsWith('*')) {
10330
+ updatedElement.questionText = `${updatedElement.questionText} *`;
10331
+ }
10332
+ else if (updates.required === false && updatedElement.questionText && updatedElement.questionText.endsWith('*')) {
10333
+ updatedElement.questionText = updatedElement.questionText.slice(0, -2);
10334
+ }
10335
+ this.formElements[index] = updatedElement;
10336
+ this.formElementsSubject.next([...this.formElements]);
10337
+ localStorage.setItem('formElements', JSON.stringify(this.formElements));
10338
+ }
10339
+ }
10340
+ setSelectedElement(index) {
10341
+ this.selectedElementSubject.next(index);
10342
+ }
10343
+ getElements() {
10344
+ return this.formElements;
10345
+ }
10346
+ downloadElement() {
10347
+ console.log("book", this.book);
10348
+ this.book.bookQuestionsMap[this.unique_id].subQuestions = this.formElements;
10349
+ let tempElement = {};
10350
+ this.formElements.forEach((element) => {
10351
+ if (element.type === 'Dropdown' || element.type === 'Radio' || element.type === 'CheckBox') {
10352
+ // Initialize the array if it doesn't exist
10353
+ if (!tempElement[element.id]) {
10354
+ tempElement[element.id] = [];
10355
+ }
10356
+ // Push the current element into the array
10357
+ tempElement[element.id].push(element);
10358
+ }
10359
+ });
10360
+ this.book.bookQuestionsMap[this.unique_id]['sqOptions'] = tempElement;
10361
+ return this.book;
10362
+ }
10363
+ // // Find an element by its ID
10364
+ // findElementById(id: string): FormElement | null {
10365
+ // const findRecursive = (elements: FormElement[]): FormElement | null => {
10366
+ // for (const el of elements) {
10367
+ // if (el.id === id) return el;
10368
+ // if (el.subQuestions) {
10369
+ // const found = findRecursive(el.subQuestions);
10370
+ // if (found) return found;
10371
+ // }
10372
+ // }
10373
+ // return null;
10374
+ // };
10375
+ // return findRecursive(this.formElements);
10376
+ // }
10377
+ // Remove an element by UID
10378
+ // Save elements to localStorage and update the subject
10379
+ removeElementComponent(uid) {
10380
+ this.tempElem = [];
10381
+ this.formElements.forEach((element) => {
10382
+ if (element.uid !== uid) {
10383
+ this.tempElem.push(element);
10384
+ }
10385
+ });
10386
+ this.formElements = this.tempElem;
10387
+ localStorage.setItem('formElements', JSON.stringify(this.formElements));
10388
+ this.formElementsSubject.next([...this.formElements]);
10389
+ }
10390
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: FormBuilderService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
10391
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: FormBuilderService, providedIn: 'root' });
10392
+ }
10393
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: FormBuilderService, decorators: [{
10394
+ type: Injectable,
10395
+ args: [{
10396
+ providedIn: 'root',
10397
+ }]
10398
+ }], ctorParameters: () => [] });
10399
+
10400
+ // AP 22JAN25 - form preview and All form elements
10401
+ class ElementComponent {
10402
+ formBuilderService;
10403
+ elementButtonClicked = new EventEmitter();
10404
+ formContainer;
10405
+ bookletJSON;
10406
+ bookletId;
10407
+ formElements = [];
10408
+ constructor(formBuilderService) {
10409
+ this.formBuilderService = formBuilderService;
10410
+ }
10411
+ ngOnInit() {
10412
+ // Subscribe to the formElements$ observable
10413
+ this.formBuilderService.formElements$.subscribe((elements) => {
10414
+ this.formElements = elements; // Update the local array with the latest data
10415
+ console.log('Form Elements:', this.formElements);
10416
+ });
10417
+ console.log("bookletJSON==" + this.bookletJSON);
10418
+ if (this.bookletJSON) {
10419
+ // AP-23JAN25 - empty string to clear the local storage
10420
+ localStorage.setItem('formElements', "");
10421
+ localStorage.setItem('status', ("edit"));
10422
+ localStorage.setItem('unique_id', (this.bookletId));
10423
+ this.formElements = [];
10424
+ this.bookletJSON.bookQuestionsMap[this.bookletId].subQuestions.forEach(newElement => {
10425
+ this.formBuilderService.addElement(newElement);
10426
+ this.formElements = this.formBuilderService.getElements();
10427
+ });
10428
+ }
10429
+ else {
10430
+ localStorage.setItem('status', ("new"));
10431
+ }
10432
+ }
10433
+ drop(event) {
10434
+ moveItemInArray(this.formElements, event.previousIndex, event.currentIndex);
10435
+ }
10436
+ // Add this method to handle element selection
10437
+ selectElement(index) {
10438
+ this.formBuilderService.setSelectedElement(index);
10439
+ const element = this.formElements[index];
10440
+ this.elementButtonClicked.emit(element.type); // Emit the type when selecting
10441
+ }
10442
+ addElement(type) {
10443
+ const unique_id = v4();
10444
+ const newElement = {
10445
+ id: unique_id,
10446
+ uid: unique_id,
10447
+ name: '',
10448
+ type,
10449
+ questionText: '',
10450
+ question: '',
10451
+ helpText: '',
10452
+ errorMessage: '',
10453
+ isReadOnly: false,
10454
+ isHidden: false,
10455
+ required: false,
10456
+ subText: '',
10457
+ referenceField: '',
10458
+ additionalRichContent: '',
10459
+ groupName: '',
10460
+ isDateBackward: false,
10461
+ title: '',
10462
+ subTitle: '',
10463
+ isDateForward: false,
10464
+ isOptional: false,
10465
+ isTitle: false,
10466
+ nextQuestion: '',
10467
+ allowedFileExtensions: '',
10468
+ questionNumber: this.formBuilderService.getElements().length + 1,
10469
+ questionBookId: '',
10470
+ parentQuestion: '',
10471
+ fieldsMeta: '',
10472
+ recordTypeName: '',
10473
+ recordTypeId: '',
10474
+ trackingId: '',
10475
+ dateText: '',
10476
+ timeText: '',
10477
+ recordId: '',
10478
+ qbReference: '',
10479
+ qbReferenceQuestions: '',
10480
+ questionBookSubTitle: '',
10481
+ style: '',
10482
+ options: type === 'CheckBox' || type === 'Radio' || type === 'Dropdown' ? [
10483
+ { label: 'Option 1', value: '', type: 'text', key: 'option1' },
10484
+ { label: 'Option 2', value: '', type: 'text', key: 'option2' }
10485
+ ] : null,
10486
+ };
10487
+ this.formBuilderService.addElement(newElement);
10488
+ this.formElements = this.formBuilderService.getElements();
10489
+ }
10490
+ addOption(options) {
10491
+ options.push({ label: `Option ${options.length + 1}`, value: '' });
10492
+ }
10493
+ removeOption(options, index) {
10494
+ options.splice(index, 1);
10495
+ }
10496
+ // Remove an element by index
10497
+ removeElement(field, index) {
10498
+ console.log('remove', index);
10499
+ this.formBuilderService.removeElementComponent(field.uid);
10500
+ this.formElements = this.formBuilderService.getElements();
10501
+ }
10502
+ getFontStyles(field) {
10503
+ const styles = {
10504
+ 'font-family': field.font || 'Helvetica Neue',
10505
+ 'font-weight': field.fontWeight || '400',
10506
+ 'width': `${field.width || 980}px`,
10507
+ 'height': `${field.height || 91}px`,
10508
+ 'text-align': field.textAlign || 'left'
10509
+ };
10510
+ // Handle array of style classes
10511
+ if (field.styles && Array.isArray(field.styles)) {
10512
+ if (field.styles.includes('bold')) {
10513
+ styles['font-weight'] = '700';
10514
+ }
10515
+ if (field.styles.includes('italic')) {
10516
+ styles['font-style'] = 'italic';
10517
+ }
10518
+ if (field.styles.includes('underline')) {
10519
+ styles['text-decoration'] = 'underline';
10520
+ }
10521
+ if (field.styles.includes('capitalize')) {
10522
+ styles['text-transform'] = 'capitalize';
10523
+ }
10524
+ if (field.styles.includes('lowercase')) {
10525
+ styles['text-transform'] = 'lowercase';
10526
+ }
10527
+ }
10528
+ return styles;
10529
+ }
10530
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: ElementComponent, deps: [{ token: FormBuilderService }], target: i0.ɵɵFactoryTarget.Component });
10531
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: ElementComponent, selector: "app-element", inputs: { bookletJSON: "bookletJSON", bookletId: "bookletId" }, outputs: { elementButtonClicked: "elementButtonClicked" }, viewQueries: [{ propertyName: "formContainer", first: true, predicate: ["formContainer"], descendants: true }], ngImport: i0, template: "<!-- AP 22JAN25 - form preview and All form elements -->\r\n<div class=\"center-frame\">\r\n <link href=\"https://fonts.googleapis.com/css?family=Roboto:300,400,500&display=swap\" rel=\"stylesheet\">\r\n <div class=\"form-preview\" cdkDropList [cdkDropListData]=\"formElements\" (cdkDropListDropped)=\"drop($event)\">\r\n <ng-container *ngFor=\"let field of formElements; let i = index\" getProperties().elementProps>\r\n\r\n <!-- TextBox -->\r\n <div *ngIf=\"field.type === 'Text'\" class=\"\" style=\"padding: 10px;\r\n background-color: whitesmoke;\" (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\" cdkDrag>\r\n <div class=\"flex\" style=\"display: flex;\">\r\n <div class=\"all-dots\"><div *ngFor=\"let _ of [1,2,3,4,5,6,7,8]\"></div></div>\r\n <div style=\"width: 97%;\">\r\n <div class=\"flex lab-conatiner\">\r\n <label [class.required]=\"field.required\">{{ field.questionText ? field.questionText : 'lable' }}</label>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n <input type=\"text\" [placeholder]=\"field.question || 'Enter text'\" [readonly]=\"field.isReadOnly\" [class.hidden]=\"field.isHidden\" [(ngModel)]=\"field.text\" />\r\n </div>\r\n </div>\r\n </div>\r\n\r\n <!-- CheckBox -->\r\n <div class=\"CheckBox-options\" *ngIf=\"field.type === 'CheckBox'\" cdkDrag (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\">\r\n <span class=\"label-text\">{{ field.questionText }}</span>\r\n <div class=\"checkbox-container\">\r\n <label class=\"option-label\">\r\n <!-- Options Section -->\r\n <div *ngIf=\"field.options?.length > 0\" class=\"options-container\">\r\n <div *ngFor=\"let option of field.options; let i = index\" class=\"option-item\">\r\n <!-- Option Input -->\r\n <input type=\"text\" [(ngModel)]=\"option.label\" placeholder=\"Label\" class=\"option-label\"/>\r\n <input type=\"text\" [(ngModel)]=\"option.value\" placeholder=\"Value\"class=\"option-value\"/>\r\n <!-- Remove Button -->\r\n <button class=\"remove-option-btn\" (click)=\"removeOption(field.options, i)\">\r\n <img src=\"../assets/icons/Trash.svg\" alt=\"Remove Option\" />\r\n </button>\r\n </div>\r\n <!-- Add Option Button -->\r\n <button type=\"button\" class=\"add-option-btn\" (click)=\"addOption(field.options)\">\r\n <span class=\"text-lg\">+</span>\r\n </button>\r\n </div>\r\n </label>\r\n <button class=\"trash-right\" (click)=\"removeElement(field, i)\">\r\n <img src=\"../assets/icons/Trash.svg\" alt=\"Delete\" />\r\n </button>\r\n </div>\r\n </div>\r\n\r\n <!-- Dropdown -->\r\n <div *ngIf=\"field.type === 'Dropdown'\" class=\"dropdown-container\" cdkDrag (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\">\r\n <label>{{ field.questionText }}</label>\r\n <select class=\"dropdown-options\"><option *ngFor=\"let option of field.options\" >{{ option }}</option></select>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n\r\n <!-- Calendar -->\r\n<div *ngIf=\"['Calendar'].includes(field.type)\" class=\"\" style=\"padding: 10px; background-color: whitesmoke;\" (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\" cdkDrag>\r\n <div class=\"flex\" style=\"display: flex;\">\r\n <div class=\"all-dots\"><div *ngFor=\"let _ of [1,2,3,4,5,6,7,8]\"></div></div>\r\n <div style=\"width: 97%;\">\r\n <div class=\"flex lab-conatiner\">\r\n <label [class.required]=\"field.required\">{{ field.questionText ? field.questionText : 'Select Date' }}</label>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n <input type=\"date\" [readonly]=\"field.isReadOnly\" [class.hidden]=\"field.isHidden\" [(ngModel)]=\"field.date\" />\r\n </div>\r\n </div>\r\n</div>\r\n\r\n <!-- Email -->\r\n<div *ngIf=\"field.type === 'Email'\" class=\"\" style=\"padding: 10px; background-color: whitesmoke;\" (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\" cdkDrag>\r\n <div class=\"flex\" style=\"display: flex;\">\r\n <div class=\"all-dots\"><div *ngFor=\"let _ of [1,2,3,4,5,6,7,8]\"></div></div>\r\n <div style=\"width: 97%;\">\r\n <div class=\"flex lab-conatiner\">\r\n <label [class.required]=\"field.required\">{{ field.questionText ? field.questionText : 'label' }}</label>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n <input type=\"email\" [placeholder]=\"field.question || 'Enter email'\" [readonly]=\"field.isReadOnly\" [class.hidden]=\"field.isHidden\" [(ngModel)]=\"field.email\" />\r\n </div>\r\n </div>\r\n</div>\r\n\r\n\r\n <!-- Numbers -->\r\n<div *ngIf=\"field.type === 'Numbers'\" class=\"\" style=\"padding: 10px; background-color: whitesmoke;\" (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\" cdkDrag>\r\n <div class=\"flex\" style=\"display: flex;\">\r\n <div class=\"all-dots\"><div *ngFor=\"let _ of [1,2,3,4,5,6,7,8]\"></div></div>\r\n <div style=\"width: 97%;\">\r\n <div class=\"flex lab-conatiner\">\r\n <label [class.required]=\"field.required\">{{ field.questionText ? field.questionText : 'label' }}</label>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n <input type=\"number\" [placeholder]=\"field.question || 'Enter number'\" [readonly]=\"field.isReadOnly\" [class.hidden]=\"field.isHidden\" [(ngModel)]=\"field.value\" />\r\n </div>\r\n </div>\r\n</div>\r\n\r\n,\r\n\r\n <!-- List -->\r\n <div *ngIf=\"field.type === 'List'\" class=\"list-container\" cdkDrag (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\">\r\n <label>{{ field.questionText }}</label>\r\n <ul><li *ngFor=\"let item of field.items\">{{ item }}</li></ul>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n\r\n <!-- TextArea -->\r\n<div *ngIf=\"field.type === 'TextArea'\" class=\"\" style=\"padding: 10px; background-color: whitesmoke;\" (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\" cdkDrag>\r\n <div class=\"flex\" style=\"display: flex;\">\r\n <div class=\"all-dots\"><div *ngFor=\"let _ of [1,2,3,4,5,6,7,8]\"></div></div>\r\n <div style=\"width: 97%;\">\r\n <div class=\"flex lab-conatiner\">\r\n <label [class.required]=\"field.required\">\r\n {{ field.questionText ? field.questionText : 'Enter your text' }}\r\n <span *ngIf=\"field.required\" class=\"text-red-500\">*</span>\r\n </label>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n <textarea\r\n [placeholder]=\"field.question || 'Enter detailed text here...'\"\r\n [style.height.px]=\"field.size || 100\"\r\n [style.width.%]=\"100\"\r\n [readonly]=\"field.readOnly\"\r\n [class.hidden]=\"field.isHide\"\r\n [(ngModel)]=\"field.text\">\r\n </textarea>\r\n </div>\r\n </div>\r\n</div>\r\n\r\n <!-- Radio -->\r\n <div *ngIf=\"field.type === 'Radio'\" class=\"Radio-options\" cdkDrag (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\">\r\n <label>{{ field.questionText }}</label>\r\n <div *ngFor=\"let option of field.options\" class=\"radio-item\">\r\n <label><input type=\"radio\" name=\"{{ field.questionText }}\" /><span>{{ option }}</span></label>\r\n </div>\r\n <button class=\"delete-btn2\" (click)=\"removeElement(field, i)\"><img src=\"../assets/icons/Trash.svg\" alt=\"Delete\" /></button>\r\n </div>\r\n\r\n <!-- Image -->\r\n <div *ngIf=\"field.type === 'Image'\" class=\"image-container\" cdkDrag (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\">\r\n <label>{{ field.questionText }}</label>\r\n <input type=\"file\" accept=\"image/*\" />\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n\r\n <!-- Button -->\r\n <div *ngIf=\"field.type === 'Button'\" class=\"button-container\" cdkDrag (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\">\r\n <button>{{ field.questionText }}</button>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n\r\n <!-- File -->\r\n <div *ngIf=\"field.type === 'File'\" class=\"file-field-container\" cdkDrag (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\" [ngStyle]=\"getFontStyles(field)\">\r\n <label>{{ field.questionText }}</label>\r\n <input type=\"file\" />\r\n <img class=\"trash-right\" src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n\r\n<!-- Tables -->\r\n<div *ngIf=\"field.type === 'Tables'\" class=\"table-container\" cdkDrag (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\">\r\n <label>{{ field.questionText }}</label>\r\n <table [style.width.px]=\"field.colWidth\" [style.height.%]=\"field.rowHeight\">\r\n <thead><tr><th *ngFor=\"let header of field.headers\" [style.width.px]=\"field.colWidth / field.colNos\">{{ header }}</th></tr></thead>\r\n <tbody><tr *ngFor=\"let row of field.rows\"><td *ngFor=\"let cell of row\">{{ cell }}</td></tr></tbody>\r\n </table>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n</div>\r\n\r\n\r\n <!-- Book -->\r\n<div *ngIf=\"field.type === 'Book'\" class=\"\" style=\"padding: 10px; background-color: whitesmoke;\" (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\" cdkDrag>\r\n <div class=\"flex\" style=\"display: flex;\">\r\n <div class=\"all-dots\"><div *ngFor=\"let _ of [1,2,3,4,5,6,7,8]\"></div></div>\r\n <div style=\"width: 97%;\">\r\n <div class=\"flex lab-conatiner\">\r\n <label [class.required]=\"field.required\">{{ field.questionText ? field.questionText : 'Book Title' }}</label>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n <!-- No input box here -->\r\n </div>\r\n </div>\r\n</div>\r\n\r\n <!-- Label -->\r\n<div *ngIf=\"field.type === 'Label'\" class=\"\" style=\"padding: 10px; background-color: whitesmoke;\" (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\" cdkDrag>\r\n <div class=\"flex\" style=\"display: flex;\">\r\n <div class=\"all-dots\"><div *ngFor=\"let _ of [1,2,3,4,5,6,7,8]\"></div></div>\r\n <div style=\"width: 97%;\">\r\n <div class=\"flex lab-conatiner\">\r\n <label [class.required]=\"field.required\">{{ field.questionText ? field.questionText : 'Label' }}</label>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n <!-- No input box here -->\r\n </div>\r\n </div>\r\n</div>\r\n</ng-container>\r\n </div>\r\n <!-- Form Builder Section All Elements -->\r\n <div class=\"form-builder\">\r\n <div class=\"element\" (click)=\"addElement('Calendar')\">\r\n <img class=\"calendar-img\" src=\"../assets/icons/Calendar.svg\">\r\n <div class=\"hover-label\">Calendar</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('CheckBox')\">\r\n <img src=\"../assets/icons/CheckBox.svg\">\r\n <div class=\"hover-label\">Check Box</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('Email')\">\r\n <img src=\"../assets/icons/Email.svg\">\r\n <div class=\"hover-label\">Email</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('File')\">\r\n <img src=\"../assets/icons/File.svg\">\r\n <div class=\"hover-label\">File</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('List')\">\r\n <img src=\"../assets/icons/List.svg\">\r\n <div class=\"hover-label\">List</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('Tables')\">\r\n <img src=\"../assets/icons/Table.svg\">\r\n <div class=\"hover-label\">Tables</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('Text')\">\r\n <img src=\"../assets/icons/Text.svg\">\r\n <div class=\"hover-label\">Text Box</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('TextArea')\">\r\n <img src=\"../assets/icons/TextArea.svg\">\r\n <div class=\"hover-label\">Text Area</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('Numbers')\">\r\n <img src=\"../assets/icons/Number.svg\">\r\n <div class=\"hover-label\">Numbers</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('Dropdown')\">\r\n <img src=\"../assets/icons/Drop.svg\">\r\n <div class=\"hover-label\">Dropdown</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('Image')\">\r\n <img src=\"../assets/Image.svg\">\r\n <div class=\"hover-label\">Image</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('Radio')\">\r\n <img src=\"../assets/icons/Radio.svg\">\r\n <div class=\"hover-label\">Radio</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('Label')\">\r\n <img src=\"../assets/icons/Label.svg\">\r\n <div class=\"hover-label\">Label</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('Book')\">\r\n <img src=\"../assets/icons/Book.svg\">\r\n <div class=\"hover-label\">Book</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('Button')\">\r\n <img src=\"../assets/icons/Button.svg\">\r\n <div class=\"hover-label\">Button</div>\r\n </div>\r\n </div>\r\n\r\n </div>\r\n\r\n\r\n\r\n\r\n", styles: [".center-frame{width:71%;padding:26px;box-sizing:border-box;background-color:#edf1f5}.box{box-sizing:border-box}.form-builder{display:flex;flex-wrap:wrap;gap:3px;justify-content:center;position:sticky;bottom:91px;width:78%;margin:auto;box-shadow:0 2px 4px #888;border-top:none;border-radius:8px;background-color:#fff}.element{position:relative;text-align:center;cursor:pointer;padding:7px;color:#94a3b8;width:49px;height:44px;border-radius:6px;transition:background-color .3s,color .3s}.element:hover{background-color:#3374f2;color:#fff;border-radius:5px}.calendar-img{position:relative;top:-6px}.element img:hover{color:#fff}.hover-label{display:none;position:absolute;top:-30px;left:50%;transform:translate(-50%);background-color:#233859;color:#fff;padding:4px 8px;font-size:12px;border-radius:4px;white-space:nowrap}.element:hover .hover-label{display:block}.form-preview{padding:16px;height:37rem;overflow-y:auto;border-radius:8px;background-color:#fff;display:flex;flex-wrap:wrap;gap:10px}.form-preview[cdkDropListOrientation=vertical]{flex-direction:column}.form-preview[cdkDropListOrientation=horizontal]{flex-direction:row}.lab-conatiner{justify-content:space-between;display:flex}.all-dots{display:grid;gap:9px 0px;grid-template-columns:auto auto;width:18px;margin-top:15px;margin-right:10px}.all-dots>div{height:5px;width:4px;background-color:#bbb;border-radius:50%}.all-dots1{display:grid;gap:9px 0px;grid-template-columns:auto auto;width:18px;position:relative;top:93px;right:5px;margin-bottom:-19px}.all-dots1>div{height:5px;width:4px;background-color:#bbb;border-radius:50%}.textbox-container label{flex-grow:1}.trash-right{width:28px;position:relative;background-color:#f5ebea;height:27px;border-radius:50px}.trash-right img{position:relative;left:23%;top:3px}.table-container{overflow-x:auto}.textbox-container{display:flex;flex-direction:column;gap:10px;align-items:flex-start;margin:10px auto;background-color:#f6f6f6;padding:10px 15px;border-radius:5px;box-shadow:0 1px 3px #0000001a;position:relative}.textbox-container label{font-size:14px;width:100px;color:#15234b;margin-bottom:5px;display:block;position:relative;left:27px;top:-12px}.textbox-container input[type=text]{width:95%;height:40px;padding:0 0 0 10px;font-size:14px;border:none;border-radius:5px;background-color:#fff;color:#333;position:absolute;left:40px;top:39px}.textbox-container input[type=text]::placeholder{color:#b8bcca;font-style:italic}.textbox-container input[type=text]:hover,.textbox-container input[type=text]:focus{outline:none;border:1px solid #15234b;box-shadow:0 0 5px #15234b4d}.textbox-container .remove-icon{position:relative;top:-40px;right:-17px;font-size:18px;color:#ff4d4d;cursor:pointer;transition:transform .2s,color .2s}.textbox-container .remove-icon:hover{transform:scale(1.2);color:#d11a2a}.table-container{width:100%;max-width:600px;margin:20px auto;background-color:#d9d9d9;padding:15px;height:47%;border-radius:5px;box-shadow:0 1px 3px #0000001a}.table-container label{font-size:16px;font-weight:700;color:#15234b;margin-bottom:10px;display:block;width:200px;position:relative;top:-53px;left:21px}table{width:557px;height:90%;position:relative;left:20px;top:-58px;border-collapse:collapse;margin-top:10px;text-align:left}table th{background-color:#e4881e;color:#fff;padding:10px;font-size:14px;text-transform:uppercase}table thead{height:38px}table td{background-color:#fff;color:#333;padding:10px;font-size:14px;border:1px solid #ddd}table tbody tr:nth-child(2n) td{background-color:#f9f9f9}table tbody tr:hover td{background-color:#f1f1f1;transition:background-color .2s ease-in-out}.trash-right1{width:28px;position:relative;top:-233px;left:96%;background-color:#d7bbc3;height:27px;border-radius:50px}.trash-right1 img{position:relative;left:23%;top:4px}.file-field-container,.image-container{display:flex;flex-direction:column;align-items:flex-start;gap:10px;padding:11px;border:none;border-radius:8px;background-color:#f6f6f6;width:47%;height:98px;position:relative}.file-field-container label,.image-container label{font-size:14px;color:#333;margin-bottom:-1px;position:relative;left:26px}.file-field-container input[type=file],.image-container input[type=file]{width:95%;padding:10px;font-size:14px;position:relative;left:22px;border-radius:5px;background-color:#fff;cursor:pointer;box-shadow:0 2px 4px #0000001a;transition:border-color .3s ease,box-shadow .3s ease}.file-field-container input[type=file]:hover,.file-field-container input[type=file]:focus{border-color:#007bff;box-shadow:0 0 4px #007bff80;outline:none}.file-field-container img{width:20px;height:20px;cursor:pointer;position:absolute;top:10px;right:10px;opacity:.7;transition:opacity .3s ease}.file-field-container img:hover{opacity:1}.dropdown-container{display:flex;flex-direction:column;align-items:flex-start;gap:10px;padding:11px;border:none;border-radius:8px;background-color:#f6f6f6;width:47%;height:98px;position:relative}.dropdown-container img{width:20px;height:20px;cursor:pointer;position:absolute;top:10px;right:10px;opacity:.7;transition:opacity .3s ease}.dropdown-container label{font-size:14px;color:#333;margin-bottom:-1px;position:relative;left:26px}.dropdown-options{width:94%;position:relative;left:25px;height:100px;border-radius:5px;border:none}.CheckBox-options{display:flex;flex-direction:column;gap:10px;height:94px;width:45%;padding:10px;background-color:#f6f6f6;border-radius:8px;box-shadow:0 2px 4px #0000001a}.checkbox-container{display:flex;align-items:center;justify-content:space-between;padding:8px;border-radius:6px;background-color:#fff;position:relative;right:-25px;width:94%}.label-text{width:93px;position:relative;left:27px}.option-label{display:flex;align-items:center;gap:10px;position:relative;top:5px;left:10px;font-size:14px;font-weight:500;color:gray;width:83px}.option-label input[type=checkbox]{width:18px;height:18px;accent-color:#007bff;cursor:pointer}.label-text{margin-left:5px}.option-value{position:relative;left:113px;top:-19px}.add-option-btn{position:absolute;top:5px;left:273px;border:none}.remove-option-btn{position:absolute;top:4px;left:310px;border:none}.delete-btn1{position:relative;top:-39px;left:18px;background:none;border:none;cursor:pointer;padding:5px;display:flex;align-items:center;justify-content:center}.delete-btn1 img{width:18px;height:18px}.Radio-options{display:flex;flex-direction:column;padding:10px;background-color:#f6f6f6;height:94px;width:45%;border-radius:8px;box-shadow:0 2px 4px #0000001a}.radio-container{display:flex;flex-direction:column;position:relative;top:1px;right:-26px;width:94%;height:43px;padding:10px;border-radius:6px;background-color:#fff}.radio-label{font-size:14px;color:#000;margin-bottom:8px;width:104px;height:21px;position:relative;left:31px}.radio-group{display:flex;gap:20px}.radio-item{display:flex;align-items:center}.option-label{display:flex;align-items:center;gap:8px;font-size:14px;font-weight:500;color:#333}.option-label input[type=radio]{width:18px;height:18px;accent-color:#007bff;cursor:pointer}.radio-text{margin-left:5px}.delete-btn2{position:relative;top:-33px;left:374px;width:24px;background:none;border:none;cursor:pointer;padding:5px;display:flex;align-items:center;justify-content:center;transition:transform .2s ease-in-out}.delete-btn2 img{width:18px;height:18px}\n"], dependencies: [{ kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "directive", type: i3.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i4$2.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep", "cdkDropListElementContainer"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { kind: "directive", type: i4$2.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer", "cdkDragScale"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }] });
10532
+ }
10533
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: ElementComponent, decorators: [{
10534
+ type: Component,
10535
+ args: [{ selector: 'app-element', template: "<!-- AP 22JAN25 - form preview and All form elements -->\r\n<div class=\"center-frame\">\r\n <link href=\"https://fonts.googleapis.com/css?family=Roboto:300,400,500&display=swap\" rel=\"stylesheet\">\r\n <div class=\"form-preview\" cdkDropList [cdkDropListData]=\"formElements\" (cdkDropListDropped)=\"drop($event)\">\r\n <ng-container *ngFor=\"let field of formElements; let i = index\" getProperties().elementProps>\r\n\r\n <!-- TextBox -->\r\n <div *ngIf=\"field.type === 'Text'\" class=\"\" style=\"padding: 10px;\r\n background-color: whitesmoke;\" (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\" cdkDrag>\r\n <div class=\"flex\" style=\"display: flex;\">\r\n <div class=\"all-dots\"><div *ngFor=\"let _ of [1,2,3,4,5,6,7,8]\"></div></div>\r\n <div style=\"width: 97%;\">\r\n <div class=\"flex lab-conatiner\">\r\n <label [class.required]=\"field.required\">{{ field.questionText ? field.questionText : 'lable' }}</label>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n <input type=\"text\" [placeholder]=\"field.question || 'Enter text'\" [readonly]=\"field.isReadOnly\" [class.hidden]=\"field.isHidden\" [(ngModel)]=\"field.text\" />\r\n </div>\r\n </div>\r\n </div>\r\n\r\n <!-- CheckBox -->\r\n <div class=\"CheckBox-options\" *ngIf=\"field.type === 'CheckBox'\" cdkDrag (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\">\r\n <span class=\"label-text\">{{ field.questionText }}</span>\r\n <div class=\"checkbox-container\">\r\n <label class=\"option-label\">\r\n <!-- Options Section -->\r\n <div *ngIf=\"field.options?.length > 0\" class=\"options-container\">\r\n <div *ngFor=\"let option of field.options; let i = index\" class=\"option-item\">\r\n <!-- Option Input -->\r\n <input type=\"text\" [(ngModel)]=\"option.label\" placeholder=\"Label\" class=\"option-label\"/>\r\n <input type=\"text\" [(ngModel)]=\"option.value\" placeholder=\"Value\"class=\"option-value\"/>\r\n <!-- Remove Button -->\r\n <button class=\"remove-option-btn\" (click)=\"removeOption(field.options, i)\">\r\n <img src=\"../assets/icons/Trash.svg\" alt=\"Remove Option\" />\r\n </button>\r\n </div>\r\n <!-- Add Option Button -->\r\n <button type=\"button\" class=\"add-option-btn\" (click)=\"addOption(field.options)\">\r\n <span class=\"text-lg\">+</span>\r\n </button>\r\n </div>\r\n </label>\r\n <button class=\"trash-right\" (click)=\"removeElement(field, i)\">\r\n <img src=\"../assets/icons/Trash.svg\" alt=\"Delete\" />\r\n </button>\r\n </div>\r\n </div>\r\n\r\n <!-- Dropdown -->\r\n <div *ngIf=\"field.type === 'Dropdown'\" class=\"dropdown-container\" cdkDrag (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\">\r\n <label>{{ field.questionText }}</label>\r\n <select class=\"dropdown-options\"><option *ngFor=\"let option of field.options\" >{{ option }}</option></select>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n\r\n <!-- Calendar -->\r\n<div *ngIf=\"['Calendar'].includes(field.type)\" class=\"\" style=\"padding: 10px; background-color: whitesmoke;\" (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\" cdkDrag>\r\n <div class=\"flex\" style=\"display: flex;\">\r\n <div class=\"all-dots\"><div *ngFor=\"let _ of [1,2,3,4,5,6,7,8]\"></div></div>\r\n <div style=\"width: 97%;\">\r\n <div class=\"flex lab-conatiner\">\r\n <label [class.required]=\"field.required\">{{ field.questionText ? field.questionText : 'Select Date' }}</label>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n <input type=\"date\" [readonly]=\"field.isReadOnly\" [class.hidden]=\"field.isHidden\" [(ngModel)]=\"field.date\" />\r\n </div>\r\n </div>\r\n</div>\r\n\r\n <!-- Email -->\r\n<div *ngIf=\"field.type === 'Email'\" class=\"\" style=\"padding: 10px; background-color: whitesmoke;\" (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\" cdkDrag>\r\n <div class=\"flex\" style=\"display: flex;\">\r\n <div class=\"all-dots\"><div *ngFor=\"let _ of [1,2,3,4,5,6,7,8]\"></div></div>\r\n <div style=\"width: 97%;\">\r\n <div class=\"flex lab-conatiner\">\r\n <label [class.required]=\"field.required\">{{ field.questionText ? field.questionText : 'label' }}</label>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n <input type=\"email\" [placeholder]=\"field.question || 'Enter email'\" [readonly]=\"field.isReadOnly\" [class.hidden]=\"field.isHidden\" [(ngModel)]=\"field.email\" />\r\n </div>\r\n </div>\r\n</div>\r\n\r\n\r\n <!-- Numbers -->\r\n<div *ngIf=\"field.type === 'Numbers'\" class=\"\" style=\"padding: 10px; background-color: whitesmoke;\" (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\" cdkDrag>\r\n <div class=\"flex\" style=\"display: flex;\">\r\n <div class=\"all-dots\"><div *ngFor=\"let _ of [1,2,3,4,5,6,7,8]\"></div></div>\r\n <div style=\"width: 97%;\">\r\n <div class=\"flex lab-conatiner\">\r\n <label [class.required]=\"field.required\">{{ field.questionText ? field.questionText : 'label' }}</label>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n <input type=\"number\" [placeholder]=\"field.question || 'Enter number'\" [readonly]=\"field.isReadOnly\" [class.hidden]=\"field.isHidden\" [(ngModel)]=\"field.value\" />\r\n </div>\r\n </div>\r\n</div>\r\n\r\n,\r\n\r\n <!-- List -->\r\n <div *ngIf=\"field.type === 'List'\" class=\"list-container\" cdkDrag (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\">\r\n <label>{{ field.questionText }}</label>\r\n <ul><li *ngFor=\"let item of field.items\">{{ item }}</li></ul>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n\r\n <!-- TextArea -->\r\n<div *ngIf=\"field.type === 'TextArea'\" class=\"\" style=\"padding: 10px; background-color: whitesmoke;\" (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\" cdkDrag>\r\n <div class=\"flex\" style=\"display: flex;\">\r\n <div class=\"all-dots\"><div *ngFor=\"let _ of [1,2,3,4,5,6,7,8]\"></div></div>\r\n <div style=\"width: 97%;\">\r\n <div class=\"flex lab-conatiner\">\r\n <label [class.required]=\"field.required\">\r\n {{ field.questionText ? field.questionText : 'Enter your text' }}\r\n <span *ngIf=\"field.required\" class=\"text-red-500\">*</span>\r\n </label>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n <textarea\r\n [placeholder]=\"field.question || 'Enter detailed text here...'\"\r\n [style.height.px]=\"field.size || 100\"\r\n [style.width.%]=\"100\"\r\n [readonly]=\"field.readOnly\"\r\n [class.hidden]=\"field.isHide\"\r\n [(ngModel)]=\"field.text\">\r\n </textarea>\r\n </div>\r\n </div>\r\n</div>\r\n\r\n <!-- Radio -->\r\n <div *ngIf=\"field.type === 'Radio'\" class=\"Radio-options\" cdkDrag (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\">\r\n <label>{{ field.questionText }}</label>\r\n <div *ngFor=\"let option of field.options\" class=\"radio-item\">\r\n <label><input type=\"radio\" name=\"{{ field.questionText }}\" /><span>{{ option }}</span></label>\r\n </div>\r\n <button class=\"delete-btn2\" (click)=\"removeElement(field, i)\"><img src=\"../assets/icons/Trash.svg\" alt=\"Delete\" /></button>\r\n </div>\r\n\r\n <!-- Image -->\r\n <div *ngIf=\"field.type === 'Image'\" class=\"image-container\" cdkDrag (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\">\r\n <label>{{ field.questionText }}</label>\r\n <input type=\"file\" accept=\"image/*\" />\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n\r\n <!-- Button -->\r\n <div *ngIf=\"field.type === 'Button'\" class=\"button-container\" cdkDrag (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\">\r\n <button>{{ field.questionText }}</button>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n\r\n <!-- File -->\r\n <div *ngIf=\"field.type === 'File'\" class=\"file-field-container\" cdkDrag (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\" [ngStyle]=\"getFontStyles(field)\">\r\n <label>{{ field.questionText }}</label>\r\n <input type=\"file\" />\r\n <img class=\"trash-right\" src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n\r\n<!-- Tables -->\r\n<div *ngIf=\"field.type === 'Tables'\" class=\"table-container\" cdkDrag (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\">\r\n <label>{{ field.questionText }}</label>\r\n <table [style.width.px]=\"field.colWidth\" [style.height.%]=\"field.rowHeight\">\r\n <thead><tr><th *ngFor=\"let header of field.headers\" [style.width.px]=\"field.colWidth / field.colNos\">{{ header }}</th></tr></thead>\r\n <tbody><tr *ngFor=\"let row of field.rows\"><td *ngFor=\"let cell of row\">{{ cell }}</td></tr></tbody>\r\n </table>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n</div>\r\n\r\n\r\n <!-- Book -->\r\n<div *ngIf=\"field.type === 'Book'\" class=\"\" style=\"padding: 10px; background-color: whitesmoke;\" (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\" cdkDrag>\r\n <div class=\"flex\" style=\"display: flex;\">\r\n <div class=\"all-dots\"><div *ngFor=\"let _ of [1,2,3,4,5,6,7,8]\"></div></div>\r\n <div style=\"width: 97%;\">\r\n <div class=\"flex lab-conatiner\">\r\n <label [class.required]=\"field.required\">{{ field.questionText ? field.questionText : 'Book Title' }}</label>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n <!-- No input box here -->\r\n </div>\r\n </div>\r\n</div>\r\n\r\n <!-- Label -->\r\n<div *ngIf=\"field.type === 'Label'\" class=\"\" style=\"padding: 10px; background-color: whitesmoke;\" (click)=\"selectElement(i)\" [ngStyle]=\"getFontStyles(field)\" cdkDrag>\r\n <div class=\"flex\" style=\"display: flex;\">\r\n <div class=\"all-dots\"><div *ngFor=\"let _ of [1,2,3,4,5,6,7,8]\"></div></div>\r\n <div style=\"width: 97%;\">\r\n <div class=\"flex lab-conatiner\">\r\n <label [class.required]=\"field.required\">{{ field.questionText ? field.questionText : 'Label' }}</label>\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeElement(field, i)\" />\r\n </div>\r\n <!-- No input box here -->\r\n </div>\r\n </div>\r\n</div>\r\n</ng-container>\r\n </div>\r\n <!-- Form Builder Section All Elements -->\r\n <div class=\"form-builder\">\r\n <div class=\"element\" (click)=\"addElement('Calendar')\">\r\n <img class=\"calendar-img\" src=\"../assets/icons/Calendar.svg\">\r\n <div class=\"hover-label\">Calendar</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('CheckBox')\">\r\n <img src=\"../assets/icons/CheckBox.svg\">\r\n <div class=\"hover-label\">Check Box</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('Email')\">\r\n <img src=\"../assets/icons/Email.svg\">\r\n <div class=\"hover-label\">Email</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('File')\">\r\n <img src=\"../assets/icons/File.svg\">\r\n <div class=\"hover-label\">File</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('List')\">\r\n <img src=\"../assets/icons/List.svg\">\r\n <div class=\"hover-label\">List</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('Tables')\">\r\n <img src=\"../assets/icons/Table.svg\">\r\n <div class=\"hover-label\">Tables</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('Text')\">\r\n <img src=\"../assets/icons/Text.svg\">\r\n <div class=\"hover-label\">Text Box</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('TextArea')\">\r\n <img src=\"../assets/icons/TextArea.svg\">\r\n <div class=\"hover-label\">Text Area</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('Numbers')\">\r\n <img src=\"../assets/icons/Number.svg\">\r\n <div class=\"hover-label\">Numbers</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('Dropdown')\">\r\n <img src=\"../assets/icons/Drop.svg\">\r\n <div class=\"hover-label\">Dropdown</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('Image')\">\r\n <img src=\"../assets/Image.svg\">\r\n <div class=\"hover-label\">Image</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('Radio')\">\r\n <img src=\"../assets/icons/Radio.svg\">\r\n <div class=\"hover-label\">Radio</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('Label')\">\r\n <img src=\"../assets/icons/Label.svg\">\r\n <div class=\"hover-label\">Label</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('Book')\">\r\n <img src=\"../assets/icons/Book.svg\">\r\n <div class=\"hover-label\">Book</div>\r\n </div>\r\n\r\n <div class=\"element\" (click)=\"addElement('Button')\">\r\n <img src=\"../assets/icons/Button.svg\">\r\n <div class=\"hover-label\">Button</div>\r\n </div>\r\n </div>\r\n\r\n </div>\r\n\r\n\r\n\r\n\r\n", styles: [".center-frame{width:71%;padding:26px;box-sizing:border-box;background-color:#edf1f5}.box{box-sizing:border-box}.form-builder{display:flex;flex-wrap:wrap;gap:3px;justify-content:center;position:sticky;bottom:91px;width:78%;margin:auto;box-shadow:0 2px 4px #888;border-top:none;border-radius:8px;background-color:#fff}.element{position:relative;text-align:center;cursor:pointer;padding:7px;color:#94a3b8;width:49px;height:44px;border-radius:6px;transition:background-color .3s,color .3s}.element:hover{background-color:#3374f2;color:#fff;border-radius:5px}.calendar-img{position:relative;top:-6px}.element img:hover{color:#fff}.hover-label{display:none;position:absolute;top:-30px;left:50%;transform:translate(-50%);background-color:#233859;color:#fff;padding:4px 8px;font-size:12px;border-radius:4px;white-space:nowrap}.element:hover .hover-label{display:block}.form-preview{padding:16px;height:37rem;overflow-y:auto;border-radius:8px;background-color:#fff;display:flex;flex-wrap:wrap;gap:10px}.form-preview[cdkDropListOrientation=vertical]{flex-direction:column}.form-preview[cdkDropListOrientation=horizontal]{flex-direction:row}.lab-conatiner{justify-content:space-between;display:flex}.all-dots{display:grid;gap:9px 0px;grid-template-columns:auto auto;width:18px;margin-top:15px;margin-right:10px}.all-dots>div{height:5px;width:4px;background-color:#bbb;border-radius:50%}.all-dots1{display:grid;gap:9px 0px;grid-template-columns:auto auto;width:18px;position:relative;top:93px;right:5px;margin-bottom:-19px}.all-dots1>div{height:5px;width:4px;background-color:#bbb;border-radius:50%}.textbox-container label{flex-grow:1}.trash-right{width:28px;position:relative;background-color:#f5ebea;height:27px;border-radius:50px}.trash-right img{position:relative;left:23%;top:3px}.table-container{overflow-x:auto}.textbox-container{display:flex;flex-direction:column;gap:10px;align-items:flex-start;margin:10px auto;background-color:#f6f6f6;padding:10px 15px;border-radius:5px;box-shadow:0 1px 3px #0000001a;position:relative}.textbox-container label{font-size:14px;width:100px;color:#15234b;margin-bottom:5px;display:block;position:relative;left:27px;top:-12px}.textbox-container input[type=text]{width:95%;height:40px;padding:0 0 0 10px;font-size:14px;border:none;border-radius:5px;background-color:#fff;color:#333;position:absolute;left:40px;top:39px}.textbox-container input[type=text]::placeholder{color:#b8bcca;font-style:italic}.textbox-container input[type=text]:hover,.textbox-container input[type=text]:focus{outline:none;border:1px solid #15234b;box-shadow:0 0 5px #15234b4d}.textbox-container .remove-icon{position:relative;top:-40px;right:-17px;font-size:18px;color:#ff4d4d;cursor:pointer;transition:transform .2s,color .2s}.textbox-container .remove-icon:hover{transform:scale(1.2);color:#d11a2a}.table-container{width:100%;max-width:600px;margin:20px auto;background-color:#d9d9d9;padding:15px;height:47%;border-radius:5px;box-shadow:0 1px 3px #0000001a}.table-container label{font-size:16px;font-weight:700;color:#15234b;margin-bottom:10px;display:block;width:200px;position:relative;top:-53px;left:21px}table{width:557px;height:90%;position:relative;left:20px;top:-58px;border-collapse:collapse;margin-top:10px;text-align:left}table th{background-color:#e4881e;color:#fff;padding:10px;font-size:14px;text-transform:uppercase}table thead{height:38px}table td{background-color:#fff;color:#333;padding:10px;font-size:14px;border:1px solid #ddd}table tbody tr:nth-child(2n) td{background-color:#f9f9f9}table tbody tr:hover td{background-color:#f1f1f1;transition:background-color .2s ease-in-out}.trash-right1{width:28px;position:relative;top:-233px;left:96%;background-color:#d7bbc3;height:27px;border-radius:50px}.trash-right1 img{position:relative;left:23%;top:4px}.file-field-container,.image-container{display:flex;flex-direction:column;align-items:flex-start;gap:10px;padding:11px;border:none;border-radius:8px;background-color:#f6f6f6;width:47%;height:98px;position:relative}.file-field-container label,.image-container label{font-size:14px;color:#333;margin-bottom:-1px;position:relative;left:26px}.file-field-container input[type=file],.image-container input[type=file]{width:95%;padding:10px;font-size:14px;position:relative;left:22px;border-radius:5px;background-color:#fff;cursor:pointer;box-shadow:0 2px 4px #0000001a;transition:border-color .3s ease,box-shadow .3s ease}.file-field-container input[type=file]:hover,.file-field-container input[type=file]:focus{border-color:#007bff;box-shadow:0 0 4px #007bff80;outline:none}.file-field-container img{width:20px;height:20px;cursor:pointer;position:absolute;top:10px;right:10px;opacity:.7;transition:opacity .3s ease}.file-field-container img:hover{opacity:1}.dropdown-container{display:flex;flex-direction:column;align-items:flex-start;gap:10px;padding:11px;border:none;border-radius:8px;background-color:#f6f6f6;width:47%;height:98px;position:relative}.dropdown-container img{width:20px;height:20px;cursor:pointer;position:absolute;top:10px;right:10px;opacity:.7;transition:opacity .3s ease}.dropdown-container label{font-size:14px;color:#333;margin-bottom:-1px;position:relative;left:26px}.dropdown-options{width:94%;position:relative;left:25px;height:100px;border-radius:5px;border:none}.CheckBox-options{display:flex;flex-direction:column;gap:10px;height:94px;width:45%;padding:10px;background-color:#f6f6f6;border-radius:8px;box-shadow:0 2px 4px #0000001a}.checkbox-container{display:flex;align-items:center;justify-content:space-between;padding:8px;border-radius:6px;background-color:#fff;position:relative;right:-25px;width:94%}.label-text{width:93px;position:relative;left:27px}.option-label{display:flex;align-items:center;gap:10px;position:relative;top:5px;left:10px;font-size:14px;font-weight:500;color:gray;width:83px}.option-label input[type=checkbox]{width:18px;height:18px;accent-color:#007bff;cursor:pointer}.label-text{margin-left:5px}.option-value{position:relative;left:113px;top:-19px}.add-option-btn{position:absolute;top:5px;left:273px;border:none}.remove-option-btn{position:absolute;top:4px;left:310px;border:none}.delete-btn1{position:relative;top:-39px;left:18px;background:none;border:none;cursor:pointer;padding:5px;display:flex;align-items:center;justify-content:center}.delete-btn1 img{width:18px;height:18px}.Radio-options{display:flex;flex-direction:column;padding:10px;background-color:#f6f6f6;height:94px;width:45%;border-radius:8px;box-shadow:0 2px 4px #0000001a}.radio-container{display:flex;flex-direction:column;position:relative;top:1px;right:-26px;width:94%;height:43px;padding:10px;border-radius:6px;background-color:#fff}.radio-label{font-size:14px;color:#000;margin-bottom:8px;width:104px;height:21px;position:relative;left:31px}.radio-group{display:flex;gap:20px}.radio-item{display:flex;align-items:center}.option-label{display:flex;align-items:center;gap:8px;font-size:14px;font-weight:500;color:#333}.option-label input[type=radio]{width:18px;height:18px;accent-color:#007bff;cursor:pointer}.radio-text{margin-left:5px}.delete-btn2{position:relative;top:-33px;left:374px;width:24px;background:none;border:none;cursor:pointer;padding:5px;display:flex;align-items:center;justify-content:center;transition:transform .2s ease-in-out}.delete-btn2 img{width:18px;height:18px}\n"] }]
10536
+ }], ctorParameters: () => [{ type: FormBuilderService }], propDecorators: { elementButtonClicked: [{
10537
+ type: Output
10538
+ }], formContainer: [{
10539
+ type: ViewChild,
10540
+ args: ['formContainer']
10541
+ }], bookletJSON: [{
10542
+ type: Input
10543
+ }], bookletId: [{
10544
+ type: Input
10545
+ }] } });
10546
+
10547
+ class PropertiesComponent {
10548
+ http;
10549
+ formBuilderService;
10550
+ // selectedElement: any;
10551
+ colorWheel;
10552
+ ctx;
10553
+ selectedOption = '';
10554
+ selectedElementIndex = -1;
10555
+ // @Input() selectedElement: any;
10556
+ selectedElementType = '';
10557
+ selectedAlign = 'align-left'; // Add this property
10558
+ selectedStyles = []; // Using array since multiple styles can be selected
10559
+ errorMessage = '';
10560
+ selectedElement = null; // Receive the selected element
10561
+ onToggleChange(property, event) {
10562
+ const value = event.target.checked;
10563
+ if (this.selectedElement) {
10564
+ const update = { [property]: value };
10565
+ this.formBuilderService.updateElement(this.selectedElementIndex, update);
10566
+ // Update the selected element directly for immediate UI feedback
10567
+ this.selectedElement[property] = value;
10568
+ }
10569
+ }
10570
+ updateProperties(elementType) {
10571
+ // Reset alignment and styles if switching elements
10572
+ this.selectedAlign = 'align-left';
10573
+ this.selectedStyles = [];
10574
+ // Fetch the properties of the selected element type
10575
+ const properties = this.getProperties();
10576
+ if (properties) {
10577
+ // Make sure the properties are dynamically updated
10578
+ }
10579
+ }
10580
+ onAlignSelect(value) {
10581
+ if (this.selectedElement) {
10582
+ this.selectedElement.textAlign = value;
10583
+ console.log(`Selected alignment: ${value}`);
10584
+ }
10585
+ }
10586
+ onStyleSelect(value) {
10587
+ if (!this.selectedElement)
10588
+ return;
10589
+ // Initialize styles array if it doesn't exist
10590
+ this.selectedElement.styles = this.selectedElement.styles || [];
10591
+ // Ensure only one style is selected at a time
10592
+ this.selectedElement.styles = [value];
10593
+ console.log('Updated styles:', this.selectedElement.styles);
10594
+ }
10595
+ isStyleActive(value) {
10596
+ return this.selectedElement?.styles?.includes(value) || false;
10597
+ }
10598
+ elementProperties = {
10599
+ // Add other element types here similarly
10600
+ 'Text': {
10601
+ elementProps: [
10602
+ // questionText - Label-follow all element properties
10603
+ { label: 'Label', placeholder: 'Enter Text ', type: 'text', key: 'questionText' },
10604
+ // question - Placeholder-follow all element properties
10605
+ { label: 'placeholder', placeholder: 'Enter Text', type: 'text', key: 'question' },
10606
+ { label: 'Help Text', placeholder: 'Enter Text ', type: 'text', key: 'helpText' },
10607
+ { label: '', type: 'toggleGroup' },
10608
+ // errorMessage - Error Msg-follow all element properties
10609
+ { label: 'Error Msg', placeholder: 'Enter Text ', type: 'text', key: 'errorMsg' },
10610
+ { label: 'Font', type: 'select', key: 'font',
10611
+ options: ['Helvetica Neue', 'Arial', 'Times New Roman', 'Roboto'] },
10612
+ { label: 'Weight', type: 'select', key: 'fontWeight',
10613
+ options: [
10614
+ { value: '400', label: '400-Normal' },
10615
+ { value: '500', label: '500-Medium' },
10616
+ { value: '600', label: '600-Semi Bold' },
10617
+ { value: '700', label: '700-Bold' }
10618
+ ] },
10619
+ // { label: 'Size', unit: 'PX', type: 'number', key: 'size' },
10620
+ { label: 'Align', type: 'align', key: 'textAlign',
10621
+ options: [
10622
+ { value: 'left', icon: 'textalign-left' },
10623
+ { value: 'center', icon: 'align-center' },
10624
+ { value: 'right', icon: 'align-right' },
10625
+ { value: 'justifyleft', icon: 'align-justifyleft' },
10626
+ { value: 'justifyright', icon: 'align-justifyright' }
10627
+ ] },
10628
+ { label: 'Style', type: 'style', key: 'styles',
10629
+ options: [
10630
+ { value: 'italic', icon: 'italic' },
10631
+ { value: 'bold', icon: 'bold' },
10632
+ { value: 'underline', icon: 'underline' },
10633
+ { value: 'texticon', icon: 'texticon' },
10634
+ { value: 'capitalize', icon: 'capitalize' },
10635
+ { value: 'resize', icon: 'resize' }
10636
+ ] },
10637
+ { label: 'Field Size', type: 'fieldSize', key: 'fieldSize' }
10638
+ ],
10639
+ fieldProps: [
10640
+ { label: 'Field Required', type: 'radio' },
10641
+ { label: 'Default Value', placeholder: 'Enter Text ', type: 'text', key: 'defaultValue' },
10642
+ { label: 'Reference', placeholder: 'Reference Field', type: 'text' },
10643
+ { label: 'Style', placeholder: 'Style JSON', type: 'text' },
10644
+ { label: 'Sub Text', placeholder: 'Enter Text ', type: 'text' }
10645
+ ]
10646
+ },
10647
+ 'CheckBox': {
10648
+ elementProps: [
10649
+ { label: 'Label', placeholder: 'Enter Text ', type: 'text', key: 'questionText' },
10650
+ { label: 'Place Holder', placeholder: 'Enter Text ', type: 'text', key: 'question' },
10651
+ { label: 'Help Text', placeholder: 'Enter Text ', type: 'text', key: 'helpText' },
10652
+ { label: '', type: 'toggleGroup' },
10653
+ { label: 'Field Size', type: 'fieldSize', key: 'fieldSize' },
10654
+ { label: 'Error Msg', placeholder: 'Enter Text', type: 'text', key: 'errorMsg' },
10655
+ ],
10656
+ fieldProps: [
10657
+ { label: 'Field Required', type: 'radio' },
10658
+ { label: 'Default Value', placeholder: 'Enter Text', type: 'text' },
10659
+ {
10660
+ label: 'Chk Options',
10661
+ type: 'optionsGroup',
10662
+ key: 'chkOptions',
10663
+ options: [
10664
+ { label: 'Option 1', value: '', type: 'text', key: 'option1' },
10665
+ ],
10666
+ addOptionLabel: 'Add Variant', // Text for the plus icon
10667
+ icon: 'plus' // Icon for adding options
10668
+ },
10669
+ { label: 'Reference', placeholder: 'Reference Field', type: 'text' },
10670
+ { label: 'Style', placeholder: 'Style JSON', type: 'text' },
10671
+ { label: 'Sub Text', placeholder: 'Enter Text', type: 'text' }
10672
+ ]
10673
+ },
10674
+ 'Calendar': {
10675
+ elementProps: [
10676
+ { label: 'Label', placeholder: 'Enter Text', type: 'text', key: 'questionText' },
10677
+ { label: 'Place Holder', placeholder: 'Enter Text', type: 'text', key: 'question' },
10678
+ { label: 'Help Text', placeholder: 'Enter Text', type: 'text', key: 'helpText' },
10679
+ { label: '', type: 'toggleGroup' },
10680
+ { label: 'Field Size', type: 'fieldSize', key: 'fieldSize' },
10681
+ { label: 'Error Msg', placeholder: 'Enter Text', type: 'text', key: 'errorMsg' },
10682
+ ],
10683
+ fieldProps: [
10684
+ { label: 'Field Required', type: 'radio' },
10685
+ { label: 'Default Value', placeholder: 'Enter Text', type: 'text' },
10686
+ { label: 'Reference', placeholder: 'Reference Field', type: 'text' },
10687
+ { label: 'Style', placeholder: 'Style JSON', type: 'text' },
10688
+ { label: 'Sub Text', placeholder: 'Enter Text', type: 'text' }
10689
+ ]
10690
+ },
10691
+ 'Time': {
10692
+ elementProps: [
10693
+ { label: 'Label', placeholder: 'Enter Text', type: 'text', key: 'label' },
10694
+ { label: 'Place Holder', placeholder: 'Enter Text', type: 'text', key: 'placeholder' },
10695
+ { label: 'Help Text', placeholder: 'Enter Text', type: 'text', key: 'helpText' },
10696
+ { label: '', type: 'toggleGroup' },
10697
+ { label: 'Field Size', type: 'fieldSize', key: 'fieldSize' },
10698
+ { label: 'Error Msg', placeholder: 'Enter Text', type: 'text', key: 'errorMsg' },
10699
+ ],
10700
+ fieldProps: [
10701
+ { label: 'Field Required', type: 'radio' },
10702
+ { label: 'Default Value', placeholder: 'Enter Text', type: 'text' },
10703
+ { label: 'Reference', placeholder: 'Reference Field', type: 'text' },
10704
+ { label: 'Style', placeholder: 'Style JSON', type: 'text' },
10705
+ { label: 'Sub Text', placeholder: 'Enter Text', type: 'text' }
10706
+ ]
10707
+ },
10708
+ 'Email': {
10709
+ elementProps: [
10710
+ { label: 'Label', placeholder: 'Enter Text', type: 'text', key: 'questionText' },
10711
+ { label: 'Place Holder', placeholder: 'Enter Text', type: 'text', key: 'question' },
10712
+ { label: 'Help Text', placeholder: 'Enter Text', type: 'text', key: 'helpText' },
10713
+ { label: '', type: 'toggleGroup' },
10714
+ { label: 'Field Size', type: 'fieldSize', key: 'fieldSize' },
10715
+ { label: 'Error Msg', placeholder: 'Enter Text', type: 'text', key: 'errorMsg' },
10716
+ ],
10717
+ fieldProps: [
10718
+ { label: 'Field Required', type: 'radio' },
10719
+ { label: 'Default Value', placeholder: 'Enter Text', type: 'text' },
10720
+ { label: 'Reference', placeholder: 'Reference Field', type: 'text' },
10721
+ { label: 'Style', placeholder: 'Style JSON', type: 'text' },
10722
+ { label: 'Sub Text', placeholder: 'Enter Text', type: 'text' }
10723
+ ]
10724
+ },
10725
+ 'File': {
10726
+ elementProps: [
10727
+ { label: 'Label', placeholder: 'Enter Text', type: 'text', key: 'questionText' },
10728
+ { label: 'Place Holder', placeholder: 'Enter Text', type: 'text', key: 'question' },
10729
+ { label: 'Help Text', placeholder: 'Enter Text', type: 'text', key: 'helpText' },
10730
+ { label: 'Support Type', type: 'select', key: 'supportType', options: [
10731
+ { label: 'Images (JPEG, PNG, GIF)', value: 'image/*', extensions: ['.jpg', '.jpeg', '.png', '.gif'] },
10732
+ { label: 'Audio (MP3, WAV, AIFF)', value: 'audio/*', extensions: ['.mp3', '.wav', '.aiff'] },
10733
+ { label: 'Video (MP4, AVI, HEVC)', value: 'video/*', extensions: ['.mp4', '.avi', '.hevc'] },
10734
+ { label: 'Documents (DOC, DOCX, PPT, PDF)', value: 'application/pdf,application/msword,application/vnd.openxmlformats-officedocument.wordprocessingml.document,application/vnd.ms-powerpoint', extensions: ['.doc', '.docx', '.ppt', '.pdf'] },
10735
+ { label: 'Executables (EXE, BAD, SH)', value: 'application/x-msdownload,application/x-sh', extensions: ['.exe', '.bad', '.sh'] },
10736
+ { label: 'Archives (ZIP, RAR, Git-hub)', value: 'application/zip,application/x-rar-compressed,application/x-git', extensions: ['.zip', '.rar', '.git'] }
10737
+ ] },
10738
+ { label: '', type: 'toggleGroup' },
10739
+ { label: 'Field Size', type: 'fieldSize', key: 'fieldSize' },
10740
+ { label: 'Error Msg', placeholder: 'Enter Text', type: 'text', key: 'errorMsg' },
10741
+ ],
10742
+ fieldProps: [
10743
+ { label: 'Field Required', type: 'radio' },
10744
+ { label: 'Default Value', placeholder: 'Enter Text', type: 'text' },
10745
+ { label: 'Reference', placeholder: 'Reference Field', type: 'text' },
10746
+ { label: 'Style', placeholder: 'Style JSON', type: 'text' },
10747
+ { label: 'Sub Text', placeholder: 'Enter Text', type: 'text' }
10748
+ ]
10749
+ },
10750
+ 'List': {
10751
+ elementProps: [
10752
+ { label: 'Label', placeholder: 'Enter Text', type: 'text', key: 'questionText' },
10753
+ { label: 'Place Holder', placeholder: 'Enter Text', type: 'text', key: 'question' },
10754
+ { label: 'Help Text', placeholder: 'Enter Text', type: 'text', key: 'helpText' },
10755
+ { label: '', type: 'toggleGroup' },
10756
+ { label: 'Field Size', type: 'fieldSize', key: 'fieldSize' },
10757
+ { label: 'Error Msg', placeholder: 'Enter Text', type: 'text', key: 'errorMsg' },
10758
+ ],
10759
+ fieldProps: [
10760
+ { label: 'Field Required', type: 'radio' },
10761
+ { label: 'Default Value', placeholder: 'Enter Text', type: 'text' },
10762
+ { label: 'Reference', placeholder: 'Reference Field', type: 'text' },
10763
+ { label: 'Style', placeholder: 'Style JSON', type: 'text' },
10764
+ { label: 'Sub Text', placeholder: 'Enter Text', type: 'text' }
10765
+ ]
10766
+ }, 'TextArea': {
10767
+ elementProps: [
10768
+ { label: 'Label', placeholder: 'Enter Text', type: 'text', key: 'questionText' },
10769
+ { label: 'Place Holder', placeholder: 'Enter Text', type: 'text', key: 'question' },
10770
+ { label: 'Help Text', placeholder: 'Enter Text', type: 'text', key: 'helpText' },
10771
+ { label: '', type: 'toggleGroup' },
10772
+ { label: 'Field Size', type: 'fieldSize', key: 'fieldSize' },
10773
+ { label: 'Error Msg', placeholder: 'Enter Text', type: 'text', key: 'errorMsg' },
10774
+ ],
10775
+ fieldProps: [
10776
+ { label: 'Field Required', type: 'radio', key: 'required' },
10777
+ { label: 'Default Value', placeholder: 'Enter Text', type: 'text', key: 'defaultValue' },
10778
+ { label: 'Reference', placeholder: 'Reference Field', type: 'text' },
10779
+ { label: 'Style', placeholder: 'Style JSON', type: 'text' },
10780
+ { label: 'Sub Text', placeholder: 'Enter Text', type: 'text' }
10781
+ ]
10782
+ }, 'Numbers': {
10783
+ elementProps: [
10784
+ { label: 'Label', placeholder: 'Enter Text', type: 'text', key: 'questionText' },
10785
+ { label: 'Place Holder', placeholder: 'Enter Text', type: 'text', key: 'question' },
10786
+ { label: 'Help Text', placeholder: 'Enter Text', type: 'text', key: 'helpText' },
10787
+ { label: '', type: 'toggleGroup' },
10788
+ { label: 'Field Size', type: 'fieldSize', key: 'fieldSize' },
10789
+ { label: 'Error Msg', placeholder: 'Enter Text', type: 'text', key: 'errorMsg' },
10790
+ ],
10791
+ fieldProps: [
10792
+ { label: 'Field Required', type: 'radio' },
10793
+ { label: 'Default Value', placeholder: 'Enter Text', type: 'text' },
10794
+ { label: 'Reference', placeholder: 'Reference Field', type: 'text' },
10795
+ { label: 'Style', placeholder: 'Style JSON', type: 'text' },
10796
+ { label: 'Sub Text', placeholder: 'Enter Text', type: 'text' }
10797
+ ]
10798
+ }, 'Dropdown': {
10799
+ elementProps: [
10800
+ { label: 'Label', placeholder: 'Enter Text', type: 'text', key: 'questionText' },
10801
+ { label: 'Place Holder', placeholder: 'Enter Text', type: 'text', key: 'question' },
10802
+ { label: 'Help Text', placeholder: 'Enter Text', type: 'text', key: 'helpText' },
10803
+ { label: '', type: 'toggleGroup' },
10804
+ { label: 'Field Size', type: 'fieldSize', key: 'fieldSize' },
10805
+ { label: 'Error Msg', placeholder: 'Enter Text', type: 'text', key: 'errorMsg' },
10806
+ ],
10807
+ fieldProps: [
10808
+ { label: 'Field Required', type: 'radio' },
10809
+ { label: 'Default Value', placeholder: 'Enter Text', type: 'text' },
10810
+ {
10811
+ label: 'Chk Options',
10812
+ type: 'optionsGroup',
10813
+ key: 'chkOptions',
10814
+ options: [
10815
+ { label: 'Option 1', value: '', type: 'text', key: 'option1' },
10816
+ ],
10817
+ addOptionLabel: 'Add Variant', // Text for the plus icon
10818
+ icon: 'plus' // Icon for adding options
10819
+ },
10820
+ { label: 'Reference', placeholder: 'Reference Field', type: 'text' },
10821
+ { label: 'Style', placeholder: 'Style JSON', type: 'text' },
10822
+ { label: 'Sub Text', placeholder: 'Enter Text', type: 'text' },
10823
+ ]
10824
+ }, 'Image': {
10825
+ elementProps: [
10826
+ { label: 'Label', placeholder: 'Enter Text', type: 'text', key: 'questionText' },
10827
+ { label: 'Place Holder', placeholder: 'Enter Text', type: 'text', key: 'question' },
10828
+ { label: 'Help Text', placeholder: 'Enter Text', type: 'text', key: 'helpText' },
10829
+ { label: '', type: 'toggleGroup' },
10830
+ { label: 'Field Size', type: 'fieldSize', key: 'fieldSize' },
10831
+ { label: 'Error Msg', placeholder: 'Enter Text', type: 'text', key: 'errorMsg' },
10832
+ ],
10833
+ fieldProps: [
10834
+ { label: 'Field Required', type: 'radio' },
10835
+ { label: 'Default Value', placeholder: 'Enter Text', type: 'text' },
10836
+ { label: 'Reference', placeholder: 'Reference Field', type: 'text' },
10837
+ { label: 'Style', placeholder: 'Style JSON', type: 'text' },
10838
+ { label: 'Sub Text', placeholder: 'Enter Text', type: 'text' }
10839
+ ]
10840
+ }, 'Radio': {
10841
+ elementProps: [
10842
+ { label: 'Label', placeholder: 'Enter Text', type: 'text', key: 'questionText' },
10843
+ { label: 'Place Holder', placeholder: 'Enter Text', type: 'text', key: 'question' },
10844
+ { label: 'Help Text', placeholder: 'Enter Text', type: 'text', key: 'helpText' },
10845
+ { label: '', type: 'toggleGroup' },
10846
+ { label: 'Field Size', type: 'fieldSize', key: 'fieldSize' },
10847
+ { label: 'Error Msg', placeholder: 'Enter Text', type: 'text', key: 'errorMsg' },
10848
+ ],
10849
+ fieldProps: [
10850
+ { label: 'Field Required', type: 'radio' },
10851
+ { label: 'Default Value', placeholder: 'Enter Text', type: 'text' },
10852
+ {
10853
+ label: 'Radio Options', // Updated label to reflect radio context
10854
+ type: 'optionsGroup',
10855
+ key: 'radioOptions', // Updated key for radio context
10856
+ options: [
10857
+ { label: 'Option 1', value: '', type: 'text', key: 'option1' },
10858
+ { label: 'Option 2', value: '', type: 'text', key: 'option2' },
10859
+ ],
10860
+ addOptionLabel: 'Add Option', // Updated label for add button
10861
+ icon: 'plus', // Icon for adding options
10862
+ },
10863
+ { label: 'Reference', placeholder: 'Reference Field', type: 'text' },
10864
+ { label: 'Style', placeholder: 'Style JSON', type: 'text' },
10865
+ { label: 'Sub Text', placeholder: 'Enter Text', type: 'text' },
10866
+ ]
10867
+ },
10868
+ 'Book': {
10869
+ elementProps: [
10870
+ { label: 'Label', placeholder: 'Enter Text', type: 'text', key: 'questionText' },
10871
+ { label: 'Place Holder', placeholder: 'Enter Text', type: 'text', key: 'question' },
10872
+ { label: 'Help Text', placeholder: 'Enter Text', type: 'text', key: 'helpText' },
10873
+ { label: '', type: 'toggleGroup' },
10874
+ { label: 'Field Size', type: 'fieldSize', key: 'fieldSize' },
10875
+ { label: 'Error Msg', placeholder: 'Enter Text', type: 'text', key: 'errorMsg' },
10876
+ ],
10877
+ fieldProps: [
10878
+ { label: 'Field Required', type: 'radio' },
10879
+ { label: 'Default Value', placeholder: 'Enter Text', type: 'text' },
10880
+ { label: 'Reference', placeholder: 'Reference Field', type: 'text' },
10881
+ { label: 'Style', placeholder: 'Style JSON', type: 'text' },
10882
+ { label: 'Sub Text', placeholder: 'Enter Text', type: 'text' }
10883
+ ]
10884
+ }, 'Button': {
10885
+ elementProps: [
10886
+ { label: 'Label', placeholder: 'Enter Text', type: 'text', key: 'questionText' },
10887
+ { label: 'Place Holder', placeholder: 'Enter Text', type: 'text', key: 'question' },
10888
+ { label: 'Help Text', placeholder: 'Enter Text', type: 'text', key: 'helpText' },
10889
+ { label: '', type: 'toggleGroup' },
10890
+ { label: 'Field Size', type: 'fieldSize', key: 'fieldSize' },
10891
+ { label: 'Error Msg', placeholder: 'Enter Text', type: 'text', key: 'errorMsg' },
10892
+ ],
10893
+ fieldProps: [
10894
+ { label: 'Field Required', type: 'radio' },
10895
+ { label: 'Default Value', placeholder: 'Enter Text', type: 'text' },
10896
+ { label: 'Reference', placeholder: 'Reference Field', type: 'text' },
10897
+ { label: 'Style', placeholder: 'Style JSON', type: 'text' },
10898
+ { label: 'Sub Text', placeholder: 'Enter Text', type: 'text' }
10899
+ ]
10900
+ },
10901
+ };
10902
+ constructor(http, formBuilderService) {
10903
+ this.http = http;
10904
+ this.formBuilderService = formBuilderService;
10905
+ }
10906
+ ngOnInit() {
10907
+ this.formBuilderService.selectedElement$.subscribe(index => {
10908
+ this.selectedElementIndex = index;
10909
+ if (index >= 0) {
10910
+ const elements = this.formBuilderService.getElements();
10911
+ console.log('Selected element:', elements);
10912
+ this.selectedElement = elements[index];
10913
+ }
10914
+ });
10915
+ }
10916
+ validateInput(value, type) {
10917
+ if (type === 'label' || type === 'placeholder') {
10918
+ const regex = /^[a-zA-Z0-9\s]*$/;
10919
+ if (!regex.test(value)) {
10920
+ this.errorMessage = 'Only letters and numbers are allowed';
10921
+ return false;
10922
+ }
10923
+ }
10924
+ this.errorMessage = '';
10925
+ return true;
10926
+ }
10927
+ updateProperty(key, value) {
10928
+ if (this.selectedElementIndex >= 0) {
10929
+ if (key === 'questionText' || key === 'question') {
10930
+ if (!this.validateInput(value, key)) {
10931
+ return;
10932
+ }
10933
+ }
10934
+ if (key === 'fontWeight') {
10935
+ // Extract just the number value from the option
10936
+ value = value.split('-')[0];
10937
+ }
10938
+ if (key === 'styles') {
10939
+ const currentStyles = this.selectedElement.styles || [];
10940
+ if (value === 'capitalize' || value === 'lowercase') {
10941
+ // Remove the opposite case if it exists
10942
+ const oppositeStyle = value === 'capitalize' ? 'lowercase' : 'capitalize';
10943
+ const filteredStyles = currentStyles.filter(s => s !== oppositeStyle);
10944
+ value = currentStyles.includes(value)
10945
+ ? filteredStyles.filter(s => s !== value)
10946
+ : [...filteredStyles, value];
10947
+ }
10948
+ else {
10949
+ // Toggle other styles
10950
+ value = currentStyles.includes(value)
10951
+ ? currentStyles.filter(s => s !== value)
10952
+ : [...currentStyles, value];
10953
+ }
10954
+ }
10955
+ const update = { [key]: value };
10956
+ this.formBuilderService.updateElement(this.selectedElementIndex, update);
10957
+ // Special handling for font and font weight
10958
+ if (key === 'font') {
10959
+ this.selectedElement.font = value; // Directly update the selected element's font property
10960
+ }
10961
+ }
10962
+ }
10963
+ onRequiredChange(value) {
10964
+ if (this.selectedElement) {
10965
+ // Remove any existing asterisks first
10966
+ let label = this.selectedElement.label.replace(/\s*\*+$/, '');
10967
+ if (value) {
10968
+ label = `${label} *`; // Add single asterisk
10969
+ }
10970
+ this.updateProperty('label', label);
10971
+ this.updateProperty('required', value);
10972
+ }
10973
+ }
10974
+ getProperties() {
10975
+ if (!this.selectedElement)
10976
+ return null;
10977
+ return this.elementProperties[this.selectedElement.type];
10978
+ }
10979
+ // openColorPicker(propertyKey: string) {
10980
+ // // If you want to use the browser's native color picker:
10981
+ // const input = document.createElement('input');
10982
+ // input.type = 'color';
10983
+ // input.value = this.selectedElement[propertyKey];
10984
+ // input.addEventListener('change', (e: any) => {
10985
+ // this.updateProperty(propertyKey, e.target.value);
10986
+ // });
10987
+ // input.click();
10988
+ // }
10989
+ // Function to add a new option to prop options
10990
+ addOption(options) {
10991
+ options.push({ label: '', value: '' });
10992
+ }
10993
+ // Function to remove an option from prop options
10994
+ removeOption(options, index) {
10995
+ options.splice(index, 1);
10996
+ }
10997
+ download() {
10998
+ console.log('Question Book:', this.formBuilderService.downloadElement());
10999
+ }
11000
+ save() {
11001
+ const apiURL = 'https://dev-api.rangerfusion.com/nxt/';
11002
+ this.http.post(apiURL, this.formBuilderService.downloadElement()).subscribe((response) => {
11003
+ console.log('Response:', response);
11004
+ }, (error) => {
11005
+ console.error('Error:', error);
11006
+ });
11007
+ }
11008
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: PropertiesComponent, deps: [{ token: i1$1.HttpClient }, { token: FormBuilderService }], target: i0.ɵɵFactoryTarget.Component });
11009
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: PropertiesComponent, selector: "app-properties", inputs: { selectedElementType: "selectedElementType" }, viewQueries: [{ propertyName: "colorWheel", first: true, predicate: ["colorWheel"], descendants: true }], ngImport: i0, template: "<!-- AP 22JAN25 - Field and Element Properties -->\r\n<!-- properties.component.html -->\r\n<div class=\"container\">\r\n <link href=\"https://fonts.googleapis.com/css?family=Roboto:300,400,500&display=swap\" rel=\"stylesheet\">\r\n<!-- Design Header Section -->\r\n<div class=\"design-header\">\r\n <h1 class=\"header-title\">Element Properties</h1>\r\n <div class=\"menu-container\">\r\n <div class=\"menu-item\" (click)=\"download()\">\r\n <span >Download</span>\r\n </div>\r\n <div class=\"menu-item\">\r\n <span>Start</span>\r\n </div>\r\n <div class=\"menu-item\">\r\n <span>Path</span>\r\n </div>\r\n <div class=\"menu-item\">\r\n <span>Clone</span>\r\n </div>\r\n </div>\r\n</div>\r\n\r\n<!-- properties.component.html -->\r\n<div class=\"all-properties\">\r\n <div *ngIf=\"errorMessage\" class=\"error-message\">\r\n {{ errorMessage }}\r\n </div>\r\n <!-- Element Properties -->\r\n <details class=\"first-properties\" open>\r\n <summary class=\"text-sm \">Elements Properties</summary>\r\n <div class=\"inner-content\" *ngIf=\"getProperties()\">\r\n <ng-container *ngFor=\"let prop of getProperties().elementProps\">\r\n <div class=\"flex-items-center\">\r\n <label class=\"text-sm\">{{ prop.label }}</label>\r\n <div class=\"label-properties\">\r\n <!-- Text Input -->\r\n <input *ngIf=\"prop.type === 'text'\"\r\n type=\"text\"\r\n [placeholder]=\"prop.placeholder\"\r\n [value]=\"selectedElement[prop.key]\"\r\n (input)=\"updateProperty(prop.key, $event.target.value)\"\r\n [class.read-only]=\"selectedElement.readOnly\"\r\n [readonly]=\"selectedElement.readOnly\"\r\n class=\"text-sm1 \"\r\n />\r\n <div *ngIf=\"prop.key === 'helpText' && selectedElement.helpText\" class=\"help-text\">\r\n {{ selectedElement.helpText }}\r\n </div>\r\n\r\n\r\n <!-- Font Selection -->\r\n<div *ngIf=\"prop.key === 'font'\" class=\"font-selection\">\r\n <!-- <label>{{ prop.label }}</label> -->\r\n <select\r\n *ngIf=\"prop.type === 'select' && prop.key === 'font'\"\r\n class=\"font-selection1\"\r\n [value]=\"selectedElement?.font\"\r\n (change)=\"updateProperty('font', $event.target.value)\">\r\n <option *ngFor=\"let option of prop.options\" [value]=\"option\">\r\n {{ option }}\r\n </option>\r\n </select>\r\n</div>\r\n\r\n<!-- file -->\r\n<!-- Add this inside the elementProps loop where other inputs are rendered -->\r\n<select *ngIf=\"prop.type === 'select' && prop.key === 'supportType'\"\r\n class=\"file \"\r\n[value]=\"selectedElement[prop.key]\"\r\n(change)=\"updateProperty(prop.key, $event.target.value)\">\r\n<option value=\"\">Select file category</option>\r\n<option *ngFor=\"let option of prop.options\" [value]=\"option.value\">\r\n{{ option.label }}\r\n</option>\r\n</select>\r\n\r\n<!-- Font Weight Selection -->\r\n<div *ngIf=\"prop.key === 'fontWeight'\" class=\"font-weight\">\r\n <!-- <label>{{ prop.label }}</label> -->\r\n <select\r\n *ngIf=\"prop.type === 'select' && prop.key === 'fontWeight'\"\r\n class=\"font-weight1 \"\r\n [value]=\"selectedElement?.fontWeight\"\r\n (change)=\"updateProperty('fontWeight', $event.target.value)\">\r\n <option *ngFor=\"let option of prop.options\" [value]=\"option.value\">\r\n {{ option.label }}\r\n </option>\r\n </select>\r\n</div>\r\n\r\n <!-- Number Input with Unit -->\r\n <div *ngIf=\"prop.type === 'number'\" class=\"size-controls\">\r\n <div class=\"size-input-group\">\r\n <input\r\n type=\"number\"\r\n [value]=\"selectedElement[prop.key]\"\r\n (input)=\"updateProperty(prop.key, $event.target.value)\"\r\n [min]=\"prop.min || 1\"\r\n [max]=\"prop.max || 999999\"\r\n class=\"size-value\"\r\n />\r\n <span class=\"size-unit\">{{ prop.unit }}</span>\r\n </div>\r\n </div>\r\n\r\n <!-- Toggle Group -->\r\n<!-- Toggle Group -->\r\n<div *ngIf=\"prop.type === 'toggleGroup'\" class=\"toggle-group\">\r\n<div class=\"toggle-item1\">\r\n <span class=\"toggle-label\">Read Only</span>\r\n <label class=\"switch\">\r\n <input\r\n type=\"checkbox\"\r\n [checked]=\"selectedElement?.readOnly\"\r\n (change)=\"onToggleChange('readOnly', $event)\"\r\n />\r\n <span class=\"slider\"></span>\r\n </label>\r\n</div>\r\n\r\n<div class=\"toggle-item2\">\r\n <span class=\"toggle-label\">Is Hide</span>\r\n <label class=\"switch\">\r\n <input\r\n type=\"checkbox\"\r\n [checked]=\"selectedElement?.isHide\"\r\n (change)=\"onToggleChange('isHide', $event)\"\r\n />\r\n <span class=\"slider\"></span>\r\n </label>\r\n</div>\r\n</div>\r\n\r\n <!-- Text Align Buttons -->\r\n <div *ngIf=\"prop.type === 'align'\"class=\"font-align\">\r\n <button\r\n *ngFor=\"let option of prop.options\"\r\n (click)=\"onAlignSelect(option.value)\"\r\n [class.active]=\"selectedElement?.textAlign === option.value\"\r\n class=\"align-btn\"\r\n [title]=\"option.value\"\r\n >\r\n <img\r\n [src]=\"'../assets/icons/' + option.icon + '.svg'\"\r\n [alt]=\"option.value\"\r\n class=\"icon-size\"\r\n />\r\n </button>\r\n </div>\r\n\r\n\r\n <div *ngIf=\"prop.key === 'size'\" class=\"size-controls\">\r\n <label>{{ prop.label }}</label>\r\n <input\r\n type=\"number\"\r\n [value]=\"selectedElement[prop.key]\"\r\n (input)=\"updateProperty(prop.key, $event.target.value)\"\r\n class=\"size-input\"\r\n />\r\n <span class=\"size-unit\">{{ prop.unit }}</span>\r\n </div>\r\n\r\n\r\n <div *ngIf=\"prop.type === 'style'\" class=\"font-style\">\r\n <button\r\n *ngFor=\"let option of prop.options\"\r\n (click)=\"onStyleSelect(option.value)\"\r\n [class.active]=\"isStyleActive(option.value)\"\r\n class=\"style-btn\"\r\n [title]=\"option.value\"\r\n >\r\n <img\r\n [src]=\"'../assets/icons/' + option.icon + '.svg'\"\r\n [alt]=\"option.value\"\r\n class=\"icon-size\"\r\n />\r\n </button>\r\n </div>\r\n\r\n<!-- Field Size Controls -->\r\n<div *ngIf=\"prop.key === 'fieldSize'\" class=\"field-size-controls\">\r\n <div class=\"size-group\">\r\n <label class=\"size-label\">Width</label>\r\n <div class=\"value-container\">\r\n <input\r\n type=\"number\"\r\n [value]=\"selectedElement?.width\"\r\n (input)=\"updateProperty('width', $event.target.value)\"\r\n class=\"size-input\"\r\n\r\n />\r\n <span class=\"unit\">PX</span>\r\n </div>\r\n </div>\r\n\r\n <div *ngIf=\"prop.key === 'fieldSize'\" class=\"field-size-controls\">\r\n <div class=\"size-group\">\r\n <label class=\"size-label\">Height</label>\r\n <div class=\"value-container\">\r\n <input\r\n type=\"number\"\r\n [value]=\"selectedElement?.height\"\r\n (input)=\"updateProperty('height', $event.target.value)\"\r\n class=\"size-input\"\r\n />\r\n <span class=\"unit\">PX</span>\r\n </div>\r\n </div>\r\n </div>\r\n</div>\r\n</div>\r\n </div>\r\n </ng-container>\r\n </div>\r\n </details>\r\n\r\n <!-- Field Elements Properties -->\r\n<details class=\"second-property\">\r\n <summary class=\"text-font-medium\">Field Elements Properties</summary>\r\n <div class=\"space-y-4\" *ngIf=\"getProperties()\">\r\n <ng-container *ngFor=\"let prop of getProperties().fieldProps\">\r\n <div class=\"flex-items-center \">\r\n <label class=\"text-sm\">{{ prop.label }}</label>\r\n <div class=\"input-box-field\">\r\n <!-- Input Box -->\r\n <input\r\n *ngIf=\"prop.type === 'text'\"\r\n type=\"text\"\r\n [placeholder]=\"prop.placeholder\"\r\n class=\"field-input\"\r\n />\r\n <!-- Radio Group -->\r\n<div *ngIf=\"prop.type === 'radio'\" class=\"radio-item\">\r\n\r\n\r\n <div class=\"sizes\">\r\n <div class=\"flex-gap\">\r\n <div class=\"flex-items\">\r\n <input\r\n type=\"radio\"\r\n [checked]=\"selectedElement.required\"\r\n (change)=\"onRequiredChange(true)\"\r\n name=\"required\"\r\n class=\"radio-input\"\r\n />\r\n <label\r\n class=\"text-label\"\r\n >\r\n Required\r\n </label>\r\n </div>\r\n <div class=\"flex-items\">\r\n <input\r\n type=\"radio\"\r\n [checked]=\"!selectedElement.required\"\r\n (change)=\"onRequiredChange(false)\"\r\n name=\"required\"\r\n class=\"radio-input\"\r\n />\r\n <label\r\n class=\"text-sm text-gray-400\"\r\n >\r\n Not Required\r\n </label>\r\n </div>\r\n </div>\r\n</div>\r\n</div>\r\n <!-- Chk Options Group -->\r\n <div *ngIf=\"prop.type === 'optionsGroup'\" class=\"options-container\">\r\n <div\r\n *ngFor=\"let option of prop.options; let i = index\"\r\n class=\"option-items\"\r\n >\r\n <!-- Option Input -->\r\n <input\r\n type=\"text\"\r\n [(ngModel)]=\"prop.options[i].label\"\r\n placeholder=\"Option {{ i + 1 }}\"\r\n class=\"options\"\r\n />\r\n <input\r\n type=\"text\"\r\n [(ngModel)]=\"prop.options[i].value\"\r\n placeholder=\"Value\"\r\n class=\"values\"\r\n />\r\n <!-- Remove Button -->\r\n <div class=\"remove\">\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeOption(prop.options, i)\"></div>\r\n </div>\r\n <!-- Add Button -->\r\n <button\r\n type=\"button\"\r\n class=\"add-btn\"\r\n (click)=\"addOption(prop.options)\"\r\n >\r\n <div class=\"add-varient\">\r\n <span class=\"text-lg\">+</span>\r\n <span>Add Variants</span></div>\r\n </button>\r\n</div>\r\n </div>\r\n </div>\r\n </ng-container>\r\n </div>\r\n <div class=\"design-footer\">\r\n <button class=\"btn\">Cancel</button>\r\n <button class=\"btn\" (click)=\"save()\">Save</button>\r\n </div>\r\n</details>\r\n</div>\r\n\r\n\r\n</div>\r\n", styles: [".container{position:absolute;right:0;top:0;width:25%}.all-properties{padding:0;margin:-32px -13px 0 0;background-color:#f8fafc;position:relative;top:3px;max-height:549px;overflow-y:auto}.first-properties{padding-top:16px;padding-left:15px}details summary{font-weight:700;color:#1b1b43;cursor:pointer}details[open] summary{padding-bottom:5px;margin-bottom:1rem}label{flex:0 0 120px;color:#b8b8b8;font-size:.875rem;font-weight:500;margin:0;padding:0}input,select{flex:1;background-color:#eaedf1;color:#bebfbf;border-radius:.375rem;padding:.5rem;font-size:.875rem;width:100%;box-sizing:border-box;transition:border-color .2s}input:focus,select:focus{border-color:#1b1b43;outline:none}button{background-color:#eaedf1;color:#6b7280;border:1px solid #D1D5DB;border-radius:.375rem;padding:.5rem;cursor:pointer;transition:all .2s}button:hover{background-color:#e5e7eb}button.selected{background-color:#0b1f34;color:#fff;border-color:#1e90ff}.color-input{-webkit-appearance:none;-moz-appearance:none;appearance:none;width:50px;height:50px;background-color:transparent;border:none;cursor:pointer}.color-input::-webkit-color-swatch,.color-input::-moz-color-swatch{border-radius:5px;border:none}.inner-content{position:relative;left:30px;width:90%}.label-properties{position:relative;top:-12px;left:-37px}.required-indicator{color:red;margin-left:4px}.toggle-item1{position:relative;left:-94px;width:124px;color:#b8b8b8}.toggle-item2{width:100px;position:relative;top:-24px;left:84px;color:#b8b8b8}.flex-gap-1{display:flex;grid-template-columns:repeat(4,auto)}.help-text,.error-message{font-size:12px;margin-top:4px}.help-text{color:#666}.error-message{color:#ef4444}.read-only{background-color:#f5f5f5;cursor:not-allowed}.font-selection,.font-weight{width:190px}.design-header{padding:17px;background-color:#fff;margin-bottom:2rem}.header-title{font-size:16px;font-weight:500;text-align:center;margin:0 0 20px 5px}.menu-container{display:flex;justify-content:space-between;max-width:800px;margin:0 auto;background-color:#f8f9fa;border-radius:8px}.menu-item{flex:1;text-align:center;padding:7px;cursor:pointer;transition:all .3s ease;border-right:2px solid #e9ecef}.menu-item span{color:#656f7b;font-size:1rem}.menu-container{display:flex;justify-content:space-between;max-width:800px;margin:0 auto;background-color:#f8f9fa;border-radius:8px;padding:.5rem}.menu-item{flex:1;text-align:center;padding:m;cursor:pointer;transition:all .3s ease;border-right:1px solid #e9ecef}.menu-item:last-child{border-right:none}.menu-item:hover{background-color:#e9ecef;border-radius:4px}.menu-item span{color:#495057;font-size:1rem}.switch{position:relative;display:inline-block;width:40px;height:24px;right:-20px;margin:0 8px}.switch input{opacity:0;width:0;height:0}.slider{position:absolute;cursor:pointer;inset:0;background-color:#ccc;transition:.4s;border-radius:24px}.slider:before{position:absolute;content:\"\";height:16px;width:16px;left:4px;bottom:4px;background-color:#fff;transition:.4s;border-radius:50%}input:checked+.slider{background-color:#2196f3}input:checked+.slider:before{transform:translate(16px)}.font-align{display:flex;gap:2px}.align-btn,.style-btn{width:36px;height:36px;background:#f3f4f6;border:1px solid #e5e7eb;border-radius:4px;cursor:pointer;transition:all .2s}.align-btn:hover,.style-btn:hover{background:#e5e7eb}.align-btn.active,.style-btn.active{background:#202e3a;color:#fff;border-color:#4b5563}.align-btn.active img,.style-btn.active img{filter:brightness(0) invert(1)}.icon-size{width:16px;height:16px}.button-group{display:flex;gap:4px;padding:4px;background:#f9fafb;border-radius:6px}.field-size-controls{display:flex;flex-direction:row;position:relative;gap:13px;font-family:Arial,sans-serif}.size-group{display:flex;align-items:center}.size-label{font-size:15px;color:#000}.value-container{display:flex;height:43px;align-items:center;background-color:#f5f5f5;border-radius:11px;position:relative;right:74px}.font-style{display:flex;gap:1px}.size-input{font-size:15px;border:none;background:transparent;width:46px;text-align:center;outline:none}.size-input:focus{outline:none}.unit{font-size:13px;width:22px;color:#00000080}.file-upload-container{position:relative;margin-bottom:1rem}.file-upload-container input[type=file]{margin-top:.5rem}.text-font-medium{padding-left:15px;padding-bottom:20px}.options-container{display:flex;flex-direction:column;gap:.5rem}.option-item{display:flex;align-items:center;gap:1rem}.option-items{display:flex;gap:20px}.options{width:69px}.values{width:49px}.remove{width:34px;border-radius:50px;height:35px;background-color:#f7eff0}.remove img{position:relative;top:6px;left:9px}.add-btn{background:none;border:none;font-size:1rem;cursor:pointer;display:flex;align-items:center;width:328px;position:relative;right:123px;background-color:#f1f4f7}.add-btn:hover{color:#3182ce}.text-lg{border:1px solid gray;width:22px;border-radius:5px}.add-varient{display:flex;gap:13px;position:relative;left:101px}input{border:1px solid #ccc;padding:.5rem;border-radius:.25rem;width:100%}.space-y-4{position:relative;left:28px}.flex-items-center{display:flex;position:relative;top:2px;margin-bottom:28px}.input-box-field{width:207px}.text-sm{height:30px}.radio-item{position:relative;left:-5px}.flex-gap{display:flex;gap:18px}.design-footer{display:flex;justify-content:center;gap:30px;background-color:#f1f4f7}.btn{width:110px;color:#fff;margin-top:20px;margin-bottom:20px;background-color:#a5adbc}.btn:hover{background-color:#2196f3;color:#fff}\n"], dependencies: [{ kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }] });
11010
+ }
11011
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: PropertiesComponent, decorators: [{
11012
+ type: Component,
11013
+ args: [{ selector: 'app-properties', template: "<!-- AP 22JAN25 - Field and Element Properties -->\r\n<!-- properties.component.html -->\r\n<div class=\"container\">\r\n <link href=\"https://fonts.googleapis.com/css?family=Roboto:300,400,500&display=swap\" rel=\"stylesheet\">\r\n<!-- Design Header Section -->\r\n<div class=\"design-header\">\r\n <h1 class=\"header-title\">Element Properties</h1>\r\n <div class=\"menu-container\">\r\n <div class=\"menu-item\" (click)=\"download()\">\r\n <span >Download</span>\r\n </div>\r\n <div class=\"menu-item\">\r\n <span>Start</span>\r\n </div>\r\n <div class=\"menu-item\">\r\n <span>Path</span>\r\n </div>\r\n <div class=\"menu-item\">\r\n <span>Clone</span>\r\n </div>\r\n </div>\r\n</div>\r\n\r\n<!-- properties.component.html -->\r\n<div class=\"all-properties\">\r\n <div *ngIf=\"errorMessage\" class=\"error-message\">\r\n {{ errorMessage }}\r\n </div>\r\n <!-- Element Properties -->\r\n <details class=\"first-properties\" open>\r\n <summary class=\"text-sm \">Elements Properties</summary>\r\n <div class=\"inner-content\" *ngIf=\"getProperties()\">\r\n <ng-container *ngFor=\"let prop of getProperties().elementProps\">\r\n <div class=\"flex-items-center\">\r\n <label class=\"text-sm\">{{ prop.label }}</label>\r\n <div class=\"label-properties\">\r\n <!-- Text Input -->\r\n <input *ngIf=\"prop.type === 'text'\"\r\n type=\"text\"\r\n [placeholder]=\"prop.placeholder\"\r\n [value]=\"selectedElement[prop.key]\"\r\n (input)=\"updateProperty(prop.key, $event.target.value)\"\r\n [class.read-only]=\"selectedElement.readOnly\"\r\n [readonly]=\"selectedElement.readOnly\"\r\n class=\"text-sm1 \"\r\n />\r\n <div *ngIf=\"prop.key === 'helpText' && selectedElement.helpText\" class=\"help-text\">\r\n {{ selectedElement.helpText }}\r\n </div>\r\n\r\n\r\n <!-- Font Selection -->\r\n<div *ngIf=\"prop.key === 'font'\" class=\"font-selection\">\r\n <!-- <label>{{ prop.label }}</label> -->\r\n <select\r\n *ngIf=\"prop.type === 'select' && prop.key === 'font'\"\r\n class=\"font-selection1\"\r\n [value]=\"selectedElement?.font\"\r\n (change)=\"updateProperty('font', $event.target.value)\">\r\n <option *ngFor=\"let option of prop.options\" [value]=\"option\">\r\n {{ option }}\r\n </option>\r\n </select>\r\n</div>\r\n\r\n<!-- file -->\r\n<!-- Add this inside the elementProps loop where other inputs are rendered -->\r\n<select *ngIf=\"prop.type === 'select' && prop.key === 'supportType'\"\r\n class=\"file \"\r\n[value]=\"selectedElement[prop.key]\"\r\n(change)=\"updateProperty(prop.key, $event.target.value)\">\r\n<option value=\"\">Select file category</option>\r\n<option *ngFor=\"let option of prop.options\" [value]=\"option.value\">\r\n{{ option.label }}\r\n</option>\r\n</select>\r\n\r\n<!-- Font Weight Selection -->\r\n<div *ngIf=\"prop.key === 'fontWeight'\" class=\"font-weight\">\r\n <!-- <label>{{ prop.label }}</label> -->\r\n <select\r\n *ngIf=\"prop.type === 'select' && prop.key === 'fontWeight'\"\r\n class=\"font-weight1 \"\r\n [value]=\"selectedElement?.fontWeight\"\r\n (change)=\"updateProperty('fontWeight', $event.target.value)\">\r\n <option *ngFor=\"let option of prop.options\" [value]=\"option.value\">\r\n {{ option.label }}\r\n </option>\r\n </select>\r\n</div>\r\n\r\n <!-- Number Input with Unit -->\r\n <div *ngIf=\"prop.type === 'number'\" class=\"size-controls\">\r\n <div class=\"size-input-group\">\r\n <input\r\n type=\"number\"\r\n [value]=\"selectedElement[prop.key]\"\r\n (input)=\"updateProperty(prop.key, $event.target.value)\"\r\n [min]=\"prop.min || 1\"\r\n [max]=\"prop.max || 999999\"\r\n class=\"size-value\"\r\n />\r\n <span class=\"size-unit\">{{ prop.unit }}</span>\r\n </div>\r\n </div>\r\n\r\n <!-- Toggle Group -->\r\n<!-- Toggle Group -->\r\n<div *ngIf=\"prop.type === 'toggleGroup'\" class=\"toggle-group\">\r\n<div class=\"toggle-item1\">\r\n <span class=\"toggle-label\">Read Only</span>\r\n <label class=\"switch\">\r\n <input\r\n type=\"checkbox\"\r\n [checked]=\"selectedElement?.readOnly\"\r\n (change)=\"onToggleChange('readOnly', $event)\"\r\n />\r\n <span class=\"slider\"></span>\r\n </label>\r\n</div>\r\n\r\n<div class=\"toggle-item2\">\r\n <span class=\"toggle-label\">Is Hide</span>\r\n <label class=\"switch\">\r\n <input\r\n type=\"checkbox\"\r\n [checked]=\"selectedElement?.isHide\"\r\n (change)=\"onToggleChange('isHide', $event)\"\r\n />\r\n <span class=\"slider\"></span>\r\n </label>\r\n</div>\r\n</div>\r\n\r\n <!-- Text Align Buttons -->\r\n <div *ngIf=\"prop.type === 'align'\"class=\"font-align\">\r\n <button\r\n *ngFor=\"let option of prop.options\"\r\n (click)=\"onAlignSelect(option.value)\"\r\n [class.active]=\"selectedElement?.textAlign === option.value\"\r\n class=\"align-btn\"\r\n [title]=\"option.value\"\r\n >\r\n <img\r\n [src]=\"'../assets/icons/' + option.icon + '.svg'\"\r\n [alt]=\"option.value\"\r\n class=\"icon-size\"\r\n />\r\n </button>\r\n </div>\r\n\r\n\r\n <div *ngIf=\"prop.key === 'size'\" class=\"size-controls\">\r\n <label>{{ prop.label }}</label>\r\n <input\r\n type=\"number\"\r\n [value]=\"selectedElement[prop.key]\"\r\n (input)=\"updateProperty(prop.key, $event.target.value)\"\r\n class=\"size-input\"\r\n />\r\n <span class=\"size-unit\">{{ prop.unit }}</span>\r\n </div>\r\n\r\n\r\n <div *ngIf=\"prop.type === 'style'\" class=\"font-style\">\r\n <button\r\n *ngFor=\"let option of prop.options\"\r\n (click)=\"onStyleSelect(option.value)\"\r\n [class.active]=\"isStyleActive(option.value)\"\r\n class=\"style-btn\"\r\n [title]=\"option.value\"\r\n >\r\n <img\r\n [src]=\"'../assets/icons/' + option.icon + '.svg'\"\r\n [alt]=\"option.value\"\r\n class=\"icon-size\"\r\n />\r\n </button>\r\n </div>\r\n\r\n<!-- Field Size Controls -->\r\n<div *ngIf=\"prop.key === 'fieldSize'\" class=\"field-size-controls\">\r\n <div class=\"size-group\">\r\n <label class=\"size-label\">Width</label>\r\n <div class=\"value-container\">\r\n <input\r\n type=\"number\"\r\n [value]=\"selectedElement?.width\"\r\n (input)=\"updateProperty('width', $event.target.value)\"\r\n class=\"size-input\"\r\n\r\n />\r\n <span class=\"unit\">PX</span>\r\n </div>\r\n </div>\r\n\r\n <div *ngIf=\"prop.key === 'fieldSize'\" class=\"field-size-controls\">\r\n <div class=\"size-group\">\r\n <label class=\"size-label\">Height</label>\r\n <div class=\"value-container\">\r\n <input\r\n type=\"number\"\r\n [value]=\"selectedElement?.height\"\r\n (input)=\"updateProperty('height', $event.target.value)\"\r\n class=\"size-input\"\r\n />\r\n <span class=\"unit\">PX</span>\r\n </div>\r\n </div>\r\n </div>\r\n</div>\r\n</div>\r\n </div>\r\n </ng-container>\r\n </div>\r\n </details>\r\n\r\n <!-- Field Elements Properties -->\r\n<details class=\"second-property\">\r\n <summary class=\"text-font-medium\">Field Elements Properties</summary>\r\n <div class=\"space-y-4\" *ngIf=\"getProperties()\">\r\n <ng-container *ngFor=\"let prop of getProperties().fieldProps\">\r\n <div class=\"flex-items-center \">\r\n <label class=\"text-sm\">{{ prop.label }}</label>\r\n <div class=\"input-box-field\">\r\n <!-- Input Box -->\r\n <input\r\n *ngIf=\"prop.type === 'text'\"\r\n type=\"text\"\r\n [placeholder]=\"prop.placeholder\"\r\n class=\"field-input\"\r\n />\r\n <!-- Radio Group -->\r\n<div *ngIf=\"prop.type === 'radio'\" class=\"radio-item\">\r\n\r\n\r\n <div class=\"sizes\">\r\n <div class=\"flex-gap\">\r\n <div class=\"flex-items\">\r\n <input\r\n type=\"radio\"\r\n [checked]=\"selectedElement.required\"\r\n (change)=\"onRequiredChange(true)\"\r\n name=\"required\"\r\n class=\"radio-input\"\r\n />\r\n <label\r\n class=\"text-label\"\r\n >\r\n Required\r\n </label>\r\n </div>\r\n <div class=\"flex-items\">\r\n <input\r\n type=\"radio\"\r\n [checked]=\"!selectedElement.required\"\r\n (change)=\"onRequiredChange(false)\"\r\n name=\"required\"\r\n class=\"radio-input\"\r\n />\r\n <label\r\n class=\"text-sm text-gray-400\"\r\n >\r\n Not Required\r\n </label>\r\n </div>\r\n </div>\r\n</div>\r\n</div>\r\n <!-- Chk Options Group -->\r\n <div *ngIf=\"prop.type === 'optionsGroup'\" class=\"options-container\">\r\n <div\r\n *ngFor=\"let option of prop.options; let i = index\"\r\n class=\"option-items\"\r\n >\r\n <!-- Option Input -->\r\n <input\r\n type=\"text\"\r\n [(ngModel)]=\"prop.options[i].label\"\r\n placeholder=\"Option {{ i + 1 }}\"\r\n class=\"options\"\r\n />\r\n <input\r\n type=\"text\"\r\n [(ngModel)]=\"prop.options[i].value\"\r\n placeholder=\"Value\"\r\n class=\"values\"\r\n />\r\n <!-- Remove Button -->\r\n <div class=\"remove\">\r\n <img src=\"../assets/icons/Trash.svg\" (click)=\"removeOption(prop.options, i)\"></div>\r\n </div>\r\n <!-- Add Button -->\r\n <button\r\n type=\"button\"\r\n class=\"add-btn\"\r\n (click)=\"addOption(prop.options)\"\r\n >\r\n <div class=\"add-varient\">\r\n <span class=\"text-lg\">+</span>\r\n <span>Add Variants</span></div>\r\n </button>\r\n</div>\r\n </div>\r\n </div>\r\n </ng-container>\r\n </div>\r\n <div class=\"design-footer\">\r\n <button class=\"btn\">Cancel</button>\r\n <button class=\"btn\" (click)=\"save()\">Save</button>\r\n </div>\r\n</details>\r\n</div>\r\n\r\n\r\n</div>\r\n", styles: [".container{position:absolute;right:0;top:0;width:25%}.all-properties{padding:0;margin:-32px -13px 0 0;background-color:#f8fafc;position:relative;top:3px;max-height:549px;overflow-y:auto}.first-properties{padding-top:16px;padding-left:15px}details summary{font-weight:700;color:#1b1b43;cursor:pointer}details[open] summary{padding-bottom:5px;margin-bottom:1rem}label{flex:0 0 120px;color:#b8b8b8;font-size:.875rem;font-weight:500;margin:0;padding:0}input,select{flex:1;background-color:#eaedf1;color:#bebfbf;border-radius:.375rem;padding:.5rem;font-size:.875rem;width:100%;box-sizing:border-box;transition:border-color .2s}input:focus,select:focus{border-color:#1b1b43;outline:none}button{background-color:#eaedf1;color:#6b7280;border:1px solid #D1D5DB;border-radius:.375rem;padding:.5rem;cursor:pointer;transition:all .2s}button:hover{background-color:#e5e7eb}button.selected{background-color:#0b1f34;color:#fff;border-color:#1e90ff}.color-input{-webkit-appearance:none;-moz-appearance:none;appearance:none;width:50px;height:50px;background-color:transparent;border:none;cursor:pointer}.color-input::-webkit-color-swatch,.color-input::-moz-color-swatch{border-radius:5px;border:none}.inner-content{position:relative;left:30px;width:90%}.label-properties{position:relative;top:-12px;left:-37px}.required-indicator{color:red;margin-left:4px}.toggle-item1{position:relative;left:-94px;width:124px;color:#b8b8b8}.toggle-item2{width:100px;position:relative;top:-24px;left:84px;color:#b8b8b8}.flex-gap-1{display:flex;grid-template-columns:repeat(4,auto)}.help-text,.error-message{font-size:12px;margin-top:4px}.help-text{color:#666}.error-message{color:#ef4444}.read-only{background-color:#f5f5f5;cursor:not-allowed}.font-selection,.font-weight{width:190px}.design-header{padding:17px;background-color:#fff;margin-bottom:2rem}.header-title{font-size:16px;font-weight:500;text-align:center;margin:0 0 20px 5px}.menu-container{display:flex;justify-content:space-between;max-width:800px;margin:0 auto;background-color:#f8f9fa;border-radius:8px}.menu-item{flex:1;text-align:center;padding:7px;cursor:pointer;transition:all .3s ease;border-right:2px solid #e9ecef}.menu-item span{color:#656f7b;font-size:1rem}.menu-container{display:flex;justify-content:space-between;max-width:800px;margin:0 auto;background-color:#f8f9fa;border-radius:8px;padding:.5rem}.menu-item{flex:1;text-align:center;padding:m;cursor:pointer;transition:all .3s ease;border-right:1px solid #e9ecef}.menu-item:last-child{border-right:none}.menu-item:hover{background-color:#e9ecef;border-radius:4px}.menu-item span{color:#495057;font-size:1rem}.switch{position:relative;display:inline-block;width:40px;height:24px;right:-20px;margin:0 8px}.switch input{opacity:0;width:0;height:0}.slider{position:absolute;cursor:pointer;inset:0;background-color:#ccc;transition:.4s;border-radius:24px}.slider:before{position:absolute;content:\"\";height:16px;width:16px;left:4px;bottom:4px;background-color:#fff;transition:.4s;border-radius:50%}input:checked+.slider{background-color:#2196f3}input:checked+.slider:before{transform:translate(16px)}.font-align{display:flex;gap:2px}.align-btn,.style-btn{width:36px;height:36px;background:#f3f4f6;border:1px solid #e5e7eb;border-radius:4px;cursor:pointer;transition:all .2s}.align-btn:hover,.style-btn:hover{background:#e5e7eb}.align-btn.active,.style-btn.active{background:#202e3a;color:#fff;border-color:#4b5563}.align-btn.active img,.style-btn.active img{filter:brightness(0) invert(1)}.icon-size{width:16px;height:16px}.button-group{display:flex;gap:4px;padding:4px;background:#f9fafb;border-radius:6px}.field-size-controls{display:flex;flex-direction:row;position:relative;gap:13px;font-family:Arial,sans-serif}.size-group{display:flex;align-items:center}.size-label{font-size:15px;color:#000}.value-container{display:flex;height:43px;align-items:center;background-color:#f5f5f5;border-radius:11px;position:relative;right:74px}.font-style{display:flex;gap:1px}.size-input{font-size:15px;border:none;background:transparent;width:46px;text-align:center;outline:none}.size-input:focus{outline:none}.unit{font-size:13px;width:22px;color:#00000080}.file-upload-container{position:relative;margin-bottom:1rem}.file-upload-container input[type=file]{margin-top:.5rem}.text-font-medium{padding-left:15px;padding-bottom:20px}.options-container{display:flex;flex-direction:column;gap:.5rem}.option-item{display:flex;align-items:center;gap:1rem}.option-items{display:flex;gap:20px}.options{width:69px}.values{width:49px}.remove{width:34px;border-radius:50px;height:35px;background-color:#f7eff0}.remove img{position:relative;top:6px;left:9px}.add-btn{background:none;border:none;font-size:1rem;cursor:pointer;display:flex;align-items:center;width:328px;position:relative;right:123px;background-color:#f1f4f7}.add-btn:hover{color:#3182ce}.text-lg{border:1px solid gray;width:22px;border-radius:5px}.add-varient{display:flex;gap:13px;position:relative;left:101px}input{border:1px solid #ccc;padding:.5rem;border-radius:.25rem;width:100%}.space-y-4{position:relative;left:28px}.flex-items-center{display:flex;position:relative;top:2px;margin-bottom:28px}.input-box-field{width:207px}.text-sm{height:30px}.radio-item{position:relative;left:-5px}.flex-gap{display:flex;gap:18px}.design-footer{display:flex;justify-content:center;gap:30px;background-color:#f1f4f7}.btn{width:110px;color:#fff;margin-top:20px;margin-bottom:20px;background-color:#a5adbc}.btn:hover{background-color:#2196f3;color:#fff}\n"] }]
11014
+ }], ctorParameters: () => [{ type: i1$1.HttpClient }, { type: FormBuilderService }], propDecorators: { colorWheel: [{
11015
+ type: ViewChild,
11016
+ args: ['colorWheel']
11017
+ }], selectedElementType: [{
11018
+ type: Input
11019
+ }] } });
11020
+
11021
+ // AP 22JAN25
11022
+ class MenuComponent {
11023
+ activeIndex = 0;
11024
+ menuItems = [
11025
+ { icon: '../assets/icons/Related.svg' },
11026
+ { icon: '../assets/icons/TextColumns.svg' },
11027
+ { icon: '../assets/icons/Monotone.svg' },
11028
+ { icon: '../assets/icons/Preview1.svg' },
11029
+ { icon: '../assets/icons/Website.svg' },
11030
+ { icon: '../assets/icons/Preview2.svg' },
11031
+ { icon: '../assets/icons/pdf.svg' },
11032
+ { icon: '../assets/icons/Setting.svg' }
11033
+ // { icon: '../assets/icons/ProfileImage.svg' }
11034
+ ];
11035
+ setActiveMenu(index) {
11036
+ this.activeIndex = index;
11037
+ }
11038
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: MenuComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
11039
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: MenuComponent, selector: "app-menu", ngImport: i0, template: "<!-- AP 22JAN25 - Top menu ,Left side menu -->\r\n<!-- menu.component.html -->\r\n<div class=\"top-bar\">\r\n <button class=\"button share-button\">Share</button>\r\n <button class=\"button publish-button\">Publish</button>\r\n</div>\r\n<div class=\"menu-sidebar\">\r\n <!-- Logo Section -->\r\n <div class=\"menu-logo\">\r\n <img src=\"../assets/Nxt.png\">\r\n </div>\r\n\r\n <!-- Menu Items -->\r\n <ul class=\"menu-list\">\r\n <li\r\n *ngFor=\"let item of menuItems; let i = index\"\r\n class=\"menu-item\"\r\n [class.active]=\"activeIndex === i\"\r\n (click)=\"setActiveMenu(i)\"\r\n [attr.aria-label]=\"item.label\"\r\n >\r\n <!-- Dynamic Icon -->\r\n <img [src]=\"item.icon\" alt=\"Menu Icon\" class=\"menu-icon\" />\r\n </li>\r\n </ul>\r\n\r\n <!-- Profile Section -->\r\n <div class=\"menu-profile\">\r\n <img src=\"../assets/icons/ProfileImage.svg\" />\r\n </div>\r\n</div>\r\n\r\n", styles: [".top-bar{display:flex;justify-content:flex-end;padding:15px;background-color:#fff;border-bottom:1px solid #ccc;width:100%;position:absolute;top:-3px}.button{padding:10px 20px;margin-left:10px;font-size:1rem;border:none;border-radius:5px;cursor:pointer;transition:background-color .3s ease}.share-button{background-color:#e5e8ed;color:#384652}.share-button:hover,.publish-button{background-color:#3374f2;color:#fff}.publish-button:hover{background-color:#005f73}.menu-sidebar{width:74px;height:100vh;background-color:#fff;color:#94a3b8;display:flex;flex-direction:column;align-items:center;position:absolute;top:0;box-shadow:2px 0 5px #0000001a}.menu-logo img{width:40px;margin:20px 0}.menu-list{list-style-type:none;padding:0;margin-top:48px;flex:1}.menu-item{width:50px;height:50px;display:flex;justify-content:center;align-items:center;margin:10px 0;cursor:pointer;border-radius:8px;transition:background .3s ease}.menu-item.active,.menu-item:hover{background-color:#ffb300;border-radius:50px;color:#fff}.icon{font-size:20px}.menu-profile img{width:40px;border-radius:50%;margin-bottom:20px}\n"], dependencies: [{ kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }] });
11040
+ }
11041
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: MenuComponent, decorators: [{
11042
+ type: Component,
11043
+ args: [{ selector: 'app-menu', template: "<!-- AP 22JAN25 - Top menu ,Left side menu -->\r\n<!-- menu.component.html -->\r\n<div class=\"top-bar\">\r\n <button class=\"button share-button\">Share</button>\r\n <button class=\"button publish-button\">Publish</button>\r\n</div>\r\n<div class=\"menu-sidebar\">\r\n <!-- Logo Section -->\r\n <div class=\"menu-logo\">\r\n <img src=\"../assets/Nxt.png\">\r\n </div>\r\n\r\n <!-- Menu Items -->\r\n <ul class=\"menu-list\">\r\n <li\r\n *ngFor=\"let item of menuItems; let i = index\"\r\n class=\"menu-item\"\r\n [class.active]=\"activeIndex === i\"\r\n (click)=\"setActiveMenu(i)\"\r\n [attr.aria-label]=\"item.label\"\r\n >\r\n <!-- Dynamic Icon -->\r\n <img [src]=\"item.icon\" alt=\"Menu Icon\" class=\"menu-icon\" />\r\n </li>\r\n </ul>\r\n\r\n <!-- Profile Section -->\r\n <div class=\"menu-profile\">\r\n <img src=\"../assets/icons/ProfileImage.svg\" />\r\n </div>\r\n</div>\r\n\r\n", styles: [".top-bar{display:flex;justify-content:flex-end;padding:15px;background-color:#fff;border-bottom:1px solid #ccc;width:100%;position:absolute;top:-3px}.button{padding:10px 20px;margin-left:10px;font-size:1rem;border:none;border-radius:5px;cursor:pointer;transition:background-color .3s ease}.share-button{background-color:#e5e8ed;color:#384652}.share-button:hover,.publish-button{background-color:#3374f2;color:#fff}.publish-button:hover{background-color:#005f73}.menu-sidebar{width:74px;height:100vh;background-color:#fff;color:#94a3b8;display:flex;flex-direction:column;align-items:center;position:absolute;top:0;box-shadow:2px 0 5px #0000001a}.menu-logo img{width:40px;margin:20px 0}.menu-list{list-style-type:none;padding:0;margin-top:48px;flex:1}.menu-item{width:50px;height:50px;display:flex;justify-content:center;align-items:center;margin:10px 0;cursor:pointer;border-radius:8px;transition:background .3s ease}.menu-item.active,.menu-item:hover{background-color:#ffb300;border-radius:50px;color:#fff}.icon{font-size:20px}.menu-profile img{width:40px;border-radius:50%;margin-bottom:20px}\n"] }]
11044
+ }] });
11045
+
10195
11046
  // export const MY_CUSTOM_FORMATS = {
10196
11047
  // fullPickerInput: 'DD/MM/YYYY HH:mm:ss',
10197
11048
  // useUtc: true,
@@ -10205,7 +11056,7 @@ const languages = [
10205
11056
  ];
10206
11057
  class NxtAppModule {
10207
11058
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NxtAppModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
10208
- static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.13", ngImport: i0, type: NxtAppModule, declarations: [NxtAppComponent,
11059
+ static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.13", ngImport: i0, type: NxtAppModule, bootstrap: [NxtAppComponent], declarations: [NxtAppComponent,
10209
11060
  QuestionnaireComponent,
10210
11061
  PickLocationComponent,
10211
11062
  CustomInputComponent,
@@ -10232,7 +11083,11 @@ class NxtAppModule {
10232
11083
  I18nComponent,
10233
11084
  I18nPipe,
10234
11085
  CustomImageComponent,
10235
- CustomRadioComponent], imports: [i1$2.QuillModule, // RS 06JAN2025 Initializes the QuillModule with default settings for integrating the Quill editor.
11086
+ CustomRadioComponent,
11087
+ //AP 22JAN2025 Added the below components
11088
+ ElementComponent,
11089
+ PropertiesComponent,
11090
+ MenuComponent], imports: [i1$2.QuillModule, // RS 06JAN2025 Initializes the QuillModule with default settings for integrating the Quill editor.
10236
11091
  CustomRichTextComponent,
10237
11092
  CommonModule, FormsModule,
10238
11093
  // BrowserModule,
@@ -10245,6 +11100,7 @@ class NxtAppModule {
10245
11100
  NgSelectModule,
10246
11101
  GoogleMapsModule,
10247
11102
  MatTooltipModule,
11103
+ DragDropModule, //AP 22JAN25 Added the DragDropModule
10248
11104
  //AgmCoreModule.forRoot({
10249
11105
  // apiKey: GOOGLE_MAP_API_KEY,
10250
11106
  // libraries: ['geometry', 'places', 'visualization', 'drawing']
@@ -10254,10 +11110,16 @@ class NxtAppModule {
10254
11110
  BookletComponent,
10255
11111
  SummaryPageComponent,
10256
11112
  I18nPipe,
10257
- I18nComponent] });
11113
+ I18nComponent,
11114
+ ElementComponent,
11115
+ PropertiesComponent,
11116
+ MenuComponent
11117
+ // CustomRichTextComponent
11118
+ ] });
10258
11119
  static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NxtAppModule, providers: [
10259
11120
  I18nService,
10260
- I18nPipe
11121
+ I18nPipe,
11122
+ FormBuilderService //AP 22JAN2025 Added the FormBuilderService
10261
11123
  ], imports: [QuillModule.forRoot(), // RS 06JAN2025 Initializes the QuillModule with default settings for integrating the Quill editor.
10262
11124
  CustomRichTextComponent,
10263
11125
  CommonModule, FormsModule,
@@ -10269,6 +11131,7 @@ class NxtAppModule {
10269
11131
  NgSelectModule,
10270
11132
  GoogleMapsModule,
10271
11133
  MatTooltipModule,
11134
+ DragDropModule, //AP 22JAN25 Added the DragDropModule
10272
11135
  //AgmCoreModule.forRoot({
10273
11136
  // apiKey: GOOGLE_MAP_API_KEY,
10274
11137
  // libraries: ['geometry', 'places', 'visualization', 'drawing']
@@ -10288,7 +11151,7 @@ class NxtAppModule {
10288
11151
  "backgroundGradientStopColor": "#dd2e13",
10289
11152
  "backgroundStroke": "#d3cfcf",
10290
11153
  "title": [
10291
-
11154
+
10292
11155
  "%"
10293
11156
  ],
10294
11157
  // titleFontSize: 12,
@@ -10313,7 +11176,7 @@ class NxtAppModule {
10313
11176
  "outerStrokeLinecap": "inherit",
10314
11177
  "innerStrokeColor": "#f6dfdf",
10315
11178
  "title": [
10316
-
11179
+
10317
11180
  "%"
10318
11181
  ],
10319
11182
  "titleColor": "#e7d9d9",
@@ -10383,7 +11246,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
10383
11246
  I18nComponent,
10384
11247
  I18nPipe,
10385
11248
  CustomImageComponent,
10386
- CustomRadioComponent
11249
+ CustomRadioComponent,
11250
+ //AP 22JAN2025 Added the below components
11251
+ ElementComponent,
11252
+ PropertiesComponent,
11253
+ MenuComponent
10387
11254
  ],
10388
11255
  imports: [
10389
11256
  QuillModule.forRoot(), // RS 06JAN2025 Initializes the QuillModule with default settings for integrating the Quill editor.
@@ -10399,6 +11266,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
10399
11266
  NgSelectModule,
10400
11267
  GoogleMapsModule,
10401
11268
  MatTooltipModule,
11269
+ DragDropModule, //AP 22JAN25 Added the DragDropModule
10402
11270
  //AgmCoreModule.forRoot({
10403
11271
  // apiKey: GOOGLE_MAP_API_KEY,
10404
11272
  // libraries: ['geometry', 'places', 'visualization', 'drawing']
@@ -10418,7 +11286,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
10418
11286
  "backgroundGradientStopColor": "#dd2e13",
10419
11287
  "backgroundStroke": "#d3cfcf",
10420
11288
  "title": [
10421
-
11289
+
10422
11290
  "%"
10423
11291
  ],
10424
11292
  // titleFontSize: 12,
@@ -10443,7 +11311,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
10443
11311
  "outerStrokeLinecap": "inherit",
10444
11312
  "innerStrokeColor": "#f6dfdf",
10445
11313
  "title": [
10446
-
11314
+
10447
11315
  "%"
10448
11316
  ],
10449
11317
  "titleColor": "#e7d9d9",
@@ -10483,6 +11351,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
10483
11351
  "showSubtitle": false
10484
11352
  })
10485
11353
  ],
11354
+ bootstrap: [NxtAppComponent],
10486
11355
  schemas: [CUSTOM_ELEMENTS_SCHEMA],
10487
11356
  exports: [NxtAppComponent,
10488
11357
  QuestionnaireComponent,
@@ -10490,11 +11359,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
10490
11359
  SummaryPageComponent,
10491
11360
  I18nPipe,
10492
11361
  I18nComponent,
11362
+ ElementComponent,
11363
+ PropertiesComponent,
11364
+ MenuComponent
10493
11365
  // CustomRichTextComponent
10494
11366
  ],
10495
11367
  providers: [
10496
11368
  I18nService,
10497
- I18nPipe
11369
+ I18nPipe,
11370
+ FormBuilderService //AP 22JAN2025 Added the FormBuilderService
10498
11371
  ]
10499
11372
  // providers: [
10500
11373
  // { provide: OWL_MOMENT_DATE_TIME_ADAPTER_OPTIONS, useValue: { useUtc: false } },
@@ -10511,5 +11384,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
10511
11384
  * Generated bundle index. Do not edit.
10512
11385
  */
10513
11386
 
10514
- export { BookletComponent, I18nComponent, I18nPipe, NxtAppComponent, NxtAppModule, NxtAppService, QuestionbookComponent, QuestionnaireComponent, SalesforceService, SummaryPageComponent };
11387
+ export { BookletComponent, ElementComponent, I18nComponent, I18nPipe, MenuComponent, NxtAppComponent, NxtAppModule, NxtAppService, PropertiesComponent, QuestionbookComponent, QuestionnaireComponent, SalesforceService, SummaryPageComponent };
10515
11388
  //# sourceMappingURL=rangertechnologies-ngnxt.mjs.map