cats-ui-lib 2.0.42 → 2.2.0

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.
Files changed (40) hide show
  1. package/README.md +749 -32
  2. package/assets/images/Waffle.svg +11 -0
  3. package/assets/images/brand-Logo.svg +46 -0
  4. package/assets/images/building-07.svg +3 -0
  5. package/assets/images/check-disabled.svg +3 -0
  6. package/assets/images/check-white.svg +3 -0
  7. package/assets/images/chevron-down-white.svg +3 -0
  8. package/assets/images/chevron-down.svg +3 -1
  9. package/assets/images/chevron-right-blue.svg +3 -0
  10. package/assets/images/chevron-right-red.svg +3 -0
  11. package/assets/images/chevron-up.svg +3 -1
  12. package/assets/images/clock-refresh.svg +3 -0
  13. package/assets/images/error-info.svg +10 -0
  14. package/assets/images/expand.svg +4 -0
  15. package/assets/images/file-check-02.svg +3 -0
  16. package/assets/images/filled-dropdown.svg +3 -0
  17. package/assets/images/global-logo.svg +8 -0
  18. package/assets/images/key-01.svg +3 -0
  19. package/assets/images/log-out-04.svg +3 -0
  20. package/assets/images/menu-collapsed.svg +4 -0
  21. package/assets/images/menu-expand.svg +4 -0
  22. package/assets/images/message-smile-square.svg +3 -0
  23. package/assets/images/minimize-expand.svg +4 -0
  24. package/assets/images/nodification.svg +4 -0
  25. package/assets/images/product-logo.svg +36 -0
  26. package/assets/images/settings-04.svg +3 -0
  27. package/assets/images/shuffle-01.svg +3 -0
  28. package/assets/images/spanish-flag.svg +72 -0
  29. package/assets/images/star-yellow.svg +3 -0
  30. package/assets/images/user-active.svg +10 -0
  31. package/assets/images/user-image.svg +9 -0
  32. package/assets/images/users-01.svg +3 -0
  33. package/assets/images/x-cancel-btn.svg +3 -0
  34. package/fesm2022/cats-ui-lib.mjs +2609 -643
  35. package/fesm2022/cats-ui-lib.mjs.map +1 -1
  36. package/index.d.ts +510 -226
  37. package/package.json +1 -1
  38. package/styles/_mixins.scss +1 -1
  39. package/styles/_utilities.scss +787 -1
  40. package/styles/_variables.scss +121 -1
package/index.d.ts CHANGED
@@ -1,7 +1,9 @@
1
1
  import * as i0 from '@angular/core';
2
- import { EventEmitter, OnInit, OnChanges, TemplateRef, ChangeDetectorRef, ElementRef, SimpleChanges, OnDestroy, Renderer2, QueryList } from '@angular/core';
3
- import { ControlValueAccessor, Validator, FormControl, AbstractControl, ValidationErrors } from '@angular/forms';
4
- import { DatePipe } from '@angular/common';
2
+ import { EventEmitter, OnInit, OnChanges, TemplateRef, ChangeDetectorRef, ElementRef, SimpleChanges, OnDestroy, Renderer2, QueryList, ViewContainerRef, ApplicationRef, EnvironmentInjector } from '@angular/core';
3
+ import { ControlValueAccessor, Validator, FormControl } from '@angular/forms';
4
+ import { SafeHtml, DomSanitizer } from '@angular/platform-browser';
5
+ import { Observable } from 'rxjs';
6
+ import { Router } from '@angular/router';
5
7
 
6
8
  declare class CatsUiService {
7
9
  constructor();
@@ -13,18 +15,24 @@ declare class SingleSelectConfig {
13
15
  idField: string;
14
16
  textField: string;
15
17
  disabledField?: string;
18
+ colorField?: string;
19
+ iconField?: string;
16
20
  placeholder?: string;
17
21
  prefixLabel?: string;
18
22
  enableSearch?: boolean;
23
+ searchPlaceholder?: string;
19
24
  required?: boolean;
20
25
  }
21
26
  declare class MultiSelectConfig {
22
27
  idField: string;
23
28
  textField: string;
24
29
  disabledField?: string;
30
+ colorField?: string;
31
+ iconField?: string;
25
32
  placeholder?: string;
26
33
  prefixLabel?: string;
27
34
  enableSearch?: boolean;
35
+ searchPlaceholder?: string;
28
36
  chipLimit: number;
29
37
  selectAll?: boolean;
30
38
  required?: boolean;
@@ -41,6 +49,8 @@ declare class InputConfig {
41
49
  declare class AutoCompleteSingleSelectConfig {
42
50
  idField: string;
43
51
  textField: string;
52
+ colorField?: string;
53
+ iconField?: string;
44
54
  disabledField?: string;
45
55
  placeholder?: string;
46
56
  required?: boolean;
@@ -50,12 +60,16 @@ declare class AutoCompleteMultiSelectConfig {
50
60
  idField: string;
51
61
  textField: string;
52
62
  disabledField?: string;
63
+ colorField?: string;
64
+ iconField?: string;
53
65
  selectAll?: boolean;
54
66
  placeholder?: string;
55
67
  required?: boolean;
56
68
  chipLimit: number;
57
- customInput: boolean;
69
+ customInput?: boolean;
58
70
  pattern?: string;
71
+ infoText?: string;
72
+ selectionLimit?: number;
59
73
  }
60
74
  declare class ToggleConfig {
61
75
  checked: boolean;
@@ -82,9 +96,13 @@ interface RadioButtonConfig {
82
96
  name: string;
83
97
  layout?: 'horizontal' | 'vertical';
84
98
  }
85
- interface DateConfig {
86
- selectionMode: 'single' | 'range';
87
- enableTime?: boolean;
99
+ interface DialogConfig {
100
+ id?: string;
101
+ title?: string;
102
+ closeOnBackdropClick?: boolean;
103
+ showBackdrop?: boolean;
104
+ class?: string;
105
+ showHeader?: boolean;
88
106
  }
89
107
 
90
108
  declare class InputComponent implements ControlValueAccessor, Validator {
@@ -98,7 +116,7 @@ declare class InputComponent implements ControlValueAccessor, Validator {
98
116
  value: string;
99
117
  disabled: boolean;
100
118
  touched: boolean;
101
- control: FormControl | null;
119
+ control: FormControl<any> | null;
102
120
  showPassword: boolean;
103
121
  private onChange;
104
122
  private onTouched;
@@ -239,7 +257,7 @@ declare class MultiSelectComponent implements OnChanges, OnInit, ControlValueAcc
239
257
  multiSelectConfig: MultiSelectConfig;
240
258
  selectedOptions: any[];
241
259
  onSelection: EventEmitter<any>;
242
- control: FormControl<any>;
260
+ control: FormControl<any> | null;
243
261
  showDropdown: boolean;
244
262
  isListArrayOfObject: boolean;
245
263
  isSelectedAll: boolean;
@@ -352,7 +370,7 @@ declare class AutoCompleteSingleSelectComponent implements OnInit {
352
370
  selectedOption: any;
353
371
  constructor();
354
372
  inValid: boolean;
355
- control: FormControl<any>;
373
+ control: FormControl<any> | null;
356
374
  disableControl: boolean;
357
375
  ngOnInit(): void;
358
376
  private onTouchedCallback;
@@ -375,7 +393,7 @@ declare class AutoCompleteSingleSelectComponent implements OnInit {
375
393
  registerOnChange(fn: any): void;
376
394
  registerOnTouched(fn: any): void;
377
395
  setDisabledState(isDisabled: boolean): void;
378
- validate(control: AbstractControl): ValidationErrors | null;
396
+ validate(control: FormControl): void;
379
397
  private syncSelectionWithValue;
380
398
  /**
381
399
  * @description this method is use to update input value
@@ -423,7 +441,8 @@ declare class OutsideClickDirective {
423
441
  static ɵdir: i0.ɵɵDirectiveDeclaration<OutsideClickDirective, "[catsOutsideClick]", never, {}, { "clickOutSide": "clickOutSide"; }, never, never, true, never>;
424
442
  }
425
443
 
426
- declare class AutoCompleteMultiSelectComponent implements OnInit, ControlValueAccessor, Validator {
444
+ declare class AutoCompleteMultiSelectComponent implements OnInit, ControlValueAccessor {
445
+ private sanitizer;
427
446
  autoCompleteMultiSelectConfig: AutoCompleteMultiSelectConfig;
428
447
  selectedItem: any;
429
448
  optionsList: any[];
@@ -435,14 +454,14 @@ declare class AutoCompleteMultiSelectComponent implements OnInit, ControlValueAc
435
454
  selectedOptions: any[];
436
455
  isSelectedAll: boolean;
437
456
  inValid: boolean;
438
- control: FormControl<any>;
457
+ control: FormControl<any> | null;
439
458
  isDisabled: boolean;
440
- constructor();
459
+ safePlaceholder: SafeHtml;
460
+ constructor(sanitizer: DomSanitizer);
441
461
  ngOnInit(): void;
442
462
  ngOnChanges(_changes: SimpleChanges): void;
443
463
  private onChange;
444
464
  private onTouched;
445
- private applyDefaultConfig;
446
465
  /**
447
466
  * @description Method to toggle dropdown list
448
467
  * @author Shiva Kant
@@ -452,8 +471,9 @@ declare class AutoCompleteMultiSelectComponent implements OnInit, ControlValueAc
452
471
  registerOnChange(fn: any): void;
453
472
  registerOnTouched(fn: any): void;
454
473
  setDisabledState(isDisabled: boolean): void;
455
- validate(control: AbstractControl): ValidationErrors | null;
474
+ validate(control: FormControl): void;
456
475
  onInput(event: Event): void;
476
+ handleBlur(): void;
457
477
  /**
458
478
  * @description method to update selected item
459
479
  * @author Shiva Kant
@@ -597,197 +617,141 @@ declare class RadioButtonComponent implements ControlValueAccessor {
597
617
  static ɵcmp: i0.ɵɵComponentDeclaration<RadioButtonComponent, "cats-ui-radio-button", never, { "config": { "alias": "config"; "required": false; }; "optionList": { "alias": "optionList"; "required": false; }; "selectedRadio": { "alias": "selectedRadio"; "required": false; }; }, { "selectionChange": "selectionChange"; }, never, never, true, never>;
598
618
  }
599
619
 
600
- interface IRange {
601
- value: Date;
602
- label: string;
620
+ type DatePickerMode = 'single' | 'range' | 'dual';
621
+ interface DatePickerConfig {
622
+ mode?: DatePickerMode;
623
+ time?: boolean;
624
+ minDate?: Date;
625
+ maxDate?: Date;
626
+ placeholder?: string;
627
+ fromPlaceholder?: string;
628
+ toPlaceholder?: string;
629
+ dateFormat?: 'dd MMM yyyy' | 'MM/dd/yyyy' | 'yyyy-MM-dd';
630
+ parentDateFormat?: 'dd MMM yyyy' | 'MM/dd/yyyy' | 'yyyy-MM-dd';
631
+ disabledDates?: Date[];
632
+ disablePastDays?: number;
633
+ showDateLabel?: boolean;
634
+ showTimeLabel?: boolean;
603
635
  }
604
- declare class DateTimePickerComponent implements OnInit, OnChanges, ControlValueAccessor {
605
- private locale;
606
- private cd;
607
- private datePipe;
608
- dateTimeSelected: EventEmitter<any>;
609
- dateConfig: DateConfig;
610
- minDate?: string;
611
- maxDate?: string;
612
- preSelectedValue: any;
613
- selectedDateTime: any;
614
- currentDate: Date;
636
+ interface DateRange {
637
+ from: string | null;
638
+ fromTime: string;
639
+ to: string | null;
640
+ toTime: string;
641
+ }
642
+ interface DateTimeResult {
643
+ date: string | null;
644
+ time: string;
645
+ meridiem: 'AM' | 'PM';
646
+ }
647
+ type CalenderView = 'day' | 'year' | 'month';
648
+ declare class CustomDatePickerComponent implements OnInit, ControlValueAccessor, OnChanges {
649
+ private elRef;
650
+ config: DatePickerConfig;
651
+ label: string;
652
+ showHeader: boolean;
653
+ showTrigger: boolean;
654
+ applied: EventEmitter<string | Date | DateRange | DateTimeResult>;
655
+ cancelled: EventEmitter<void>;
656
+ rangeSelected: EventEmitter<DateRange>;
657
+ private onChange;
658
+ private onTouched;
659
+ isOpen: boolean;
660
+ selectedDate: Date | null;
661
+ tempDate: Date | null;
662
+ rangeFrom: Date | null;
663
+ rangeTo: Date | null;
664
+ tempFrom: Date | null;
665
+ tempTo: Date | null;
666
+ timeValue: string;
667
+ timeMeridiem: 'AM' | 'PM';
668
+ fromTimeValue: string;
669
+ fromTimeMeridiem: 'AM' | 'PM';
670
+ toTimeValue: string;
671
+ toTimeMeridiem: 'AM' | 'PM';
615
672
  currentMonth: number;
616
673
  currentYear: number;
617
- selectedDate: number | null;
618
- selectedTime: string | null;
619
- calendar: number[][];
620
- timeSlots: IRange[];
621
- rangeStart: number | null;
622
- rangeEnd: number | null;
623
- selectedMonth: any;
624
- selectedYear: any;
625
- control: AbstractControl<any, any>;
626
- disableControl: boolean;
627
- date: any;
628
- calendarView: string;
674
+ weekDays: string[];
675
+ calendarDays: (number | null)[];
676
+ currentMonth2: number;
677
+ currentYear2: number;
678
+ calendarDays2: (number | null)[];
629
679
  yearRange: number[];
630
- daysInMonth: any[];
631
- selectedDay: number;
632
- selectedStartDate: any;
633
- selectedEndDate: any;
634
- isOpen: boolean;
635
- showYearSelector: boolean;
636
- monthRange: any;
637
- constructor(locale: string, cd: ChangeDetectorRef, datePipe: DatePipe);
638
- ngOnChanges(_changes: SimpleChanges): void;
680
+ calenderView: CalenderView;
681
+ activeCalendar: 'primary' | 'secondary';
682
+ monthNames: string[];
683
+ constructor(elRef: ElementRef);
684
+ ngOnChanges(changes: SimpleChanges): void;
639
685
  ngOnInit(): void;
640
- private onTouchedCallback;
641
- private onChangeCallback;
642
- writeValue(value: any): void;
686
+ get mode(): DatePickerMode;
687
+ get showDateLabel(): boolean;
688
+ get time(): boolean;
689
+ get currentMonthYear(): string;
690
+ get currentMonthName(): string;
691
+ get activeMonthName(): string;
692
+ get activeYearValue(): number;
693
+ get displayValue(): string;
694
+ get tempDisplayValue(): string;
695
+ get tempFromDisplay(): string;
696
+ get tempToDisplay(): string;
697
+ writeValue(val: any): void;
643
698
  registerOnChange(fn: any): void;
644
699
  registerOnTouched(fn: any): void;
645
- setDisabledState(isDisabled: boolean): void;
646
- /**
647
- * @description Validates date time picker component
648
- * @author Shiva Kant
649
- * @param control
650
- * @returns validate
651
- */
652
- validate(control: AbstractControl): ValidationErrors | null;
653
- /**
654
- * @description method to toggleCalendar
655
- * @author Shiva Kant
656
- */
657
700
  toggleCalendar(): void;
658
- /**
659
- * @description Closes calendar
660
- * @author Shiva Kant
661
- */
662
- closeCalendar(): void;
663
- /**
664
- * @description Method to Gets month year
665
- * @author Shiva Kant
666
- * @returns month year
667
- */
668
- getMonthYear(): {
669
- month: string;
670
- year: string;
671
- };
672
- /**
673
- * @description Method to Updates current year month
674
- * @author Shiva Kant
675
- */
676
- updateCurrentYearMonth(): void;
677
- /**
678
- * @description Method to Selects year
679
- * @author Shiva Kant
680
- * @param year
681
- */
682
- selectYear(year: number): void;
683
- /**
684
- * @description Method to Selects month
685
- * @author Shiva Kant
686
- * @param month
687
- */
688
- selectMonth(month: any): void;
689
- /**
690
- * @description Method to Previous year range
691
- * @author Shiva Kant
692
- */
701
+ initializeCurrentMonthYear(): void;
702
+ onDocumentClick(event: MouseEvent): void;
703
+ buildCalendar(): void;
704
+ private buildCalendarDays;
705
+ private getNextMonthYear;
706
+ private getPrevMonthYear;
707
+ generateYearRange(year?: number): void;
708
+ openView(calendar: 'primary' | 'secondary', view: CalenderView): void;
709
+ getDayDisplay(day: number | null): string;
710
+ isOtherMonth(day: number | null): boolean;
711
+ getActualDay(day: number | null): number | null;
712
+ prevMonth(): void;
713
+ nextMonth(): void;
714
+ selectMonth(month: string): void;
693
715
  previousYearRange(): void;
694
- /**
695
- * @description Method to Next year range
696
- * @author Shiva Kant
697
- */
698
716
  nextYearRange(): void;
699
- /**
700
- * @description Method to Toggles year selector
701
- * @author Shiva Kant
702
- */
703
- toggleYearSelector(): void;
704
- /**
705
- * @description Method to Generates year range
706
- * @author Shiva Kant
707
- */
708
- generateYearRange(): void;
709
- /**
710
- * @description Method to Determines whether date selectable is
711
- * @author Shiva Kant
712
- * @param date
713
- * @returns true if date selectable
714
- */
715
- isDateSelectable(date: Date): boolean;
716
- /**
717
- * @description Method to Determines whether day disabled is
718
- * @author Shiva Kant
719
- * @param day
720
- * @returns true if day disabled
721
- */
722
- isDayDisabled(day: number): boolean;
723
- /**
724
- * @description Method to Generates calendar
725
- * @author Shiva Kant
726
- */
727
- generateCalendar(): void;
728
- /**
729
- * @description Method to Previous month
730
- * @author Shiva Kant
731
- */
732
- previousMonth(): void;
733
- /**
734
- * @description Method to Next month
735
- * @author Shiva Kant
736
- */
737
- nextMonth(): void;
738
- /**
739
- * @description Method to Initializes calendar when preSelectedValue date
740
- * @author Shiva Kant
741
- * @returns calendar
742
- */
743
- initializeCalendar(): void;
744
- /**
745
- * @description Method to Selects date
746
- * @author Shiva Kant
747
- * @param date
748
- */
749
- selectDate(date: number): void;
750
- /**
751
- * @description Method to Selects time
752
- * @author Shiva Kant
753
- * @param time
754
- */
755
- selectTime(time: string): void;
756
- /**
757
- * @description Method to Determines whether selected date is
758
- * @author Shiva Kant
759
- * @param date
760
- * @returns
761
- */
762
- isSelectedDate(date: number, month: number, year: number): boolean;
763
- /**
764
- * @description Method to Generates time ranges
765
- * @author Shiva Kant
766
- */
767
- generateTimeRanges(): void;
768
- /**
769
- * @description Method to Formats time
770
- * @author Shiva Kant
771
- * @param date
772
- * @returns time
773
- */
774
- formatTime(date: Date): string;
775
- /**
776
- * @description Method to Formats date time
777
- * @author Shiva Kant
778
- * @param fullDate
779
- * @param selectedTime
780
- * @returns date time
781
- */
782
- formatDateTime(fullDate: Date, selectedTime: string | null): string;
783
- /**
784
- * @description Method to Emits date time
785
- * @author Shiva Kant
786
- * @returns date time
787
- */
788
- emitDateTime(): void;
789
- static ɵfac: i0.ɵɵFactoryDeclaration<DateTimePickerComponent, never>;
790
- static ɵcmp: i0.ɵɵComponentDeclaration<DateTimePickerComponent, "cats-ui-date-time-picker", never, { "dateConfig": { "alias": "dateConfig"; "required": false; }; "minDate": { "alias": "minDate"; "required": false; }; "maxDate": { "alias": "maxDate"; "required": false; }; "preSelectedValue": { "alias": "preSelectedValue"; "required": false; }; }, { "dateTimeSelected": "dateTimeSelected"; }, never, never, true, never>;
717
+ selectYear(year: number): void;
718
+ selectDay(day: number | null, calendar?: 'primary' | 'secondary'): void;
719
+ isSelected(day: number | null, month?: number, year?: number): boolean;
720
+ isInRange(day: number | null, month?: number, year?: number): boolean;
721
+ isRangeStart(day: number | null, month?: number, year?: number): boolean;
722
+ isRangeEnd(day: number | null, month?: number, year?: number): boolean;
723
+ isToday(day: number | null, month?: number, year?: number): boolean;
724
+ isDayDisabled(day: number | null, month?: number, year?: number): boolean;
725
+ setTime(event: any): void;
726
+ singleTimeInSeconds: number | null;
727
+ fromTimeInSeconds: number | null;
728
+ toTimeInSeconds: number | null;
729
+ private convertToSeconds;
730
+ onSingleTimeChange(event: {
731
+ time: string;
732
+ meridiem: 'AM' | 'PM';
733
+ }): void;
734
+ onFromTimeChange(event: {
735
+ time: string;
736
+ meridiem: 'AM' | 'PM';
737
+ }): void;
738
+ onToTimeChange(event: {
739
+ time: string;
740
+ meridiem: 'AM' | 'PM';
741
+ }): void;
742
+ onApply(): void;
743
+ private normalizeTime;
744
+ appendTimeInDate(time: string, date: Date, timeMeridiem: string): Date;
745
+ onCancel(): void;
746
+ clearDate(): void;
747
+ cancelDate(source: string): void;
748
+ onDaySelected(day: number | null, calendar: 'primary' | 'secondary'): void;
749
+ isSameDay(a: Date | null, b: Date | null): boolean;
750
+ formatDate(date: Date, dateFormat?: string): string;
751
+ get canApply(): boolean;
752
+ private isValidTime;
753
+ static ɵfac: i0.ɵɵFactoryDeclaration<CustomDatePickerComponent, never>;
754
+ static ɵcmp: i0.ɵɵComponentDeclaration<CustomDatePickerComponent, "cats-ui-custom-date-picker", never, { "config": { "alias": "config"; "required": false; }; "label": { "alias": "label"; "required": false; }; "showHeader": { "alias": "showHeader"; "required": false; }; "showTrigger": { "alias": "showTrigger"; "required": false; }; }, { "applied": "applied"; "cancelled": "cancelled"; "rangeSelected": "rangeSelected"; }, never, never, true, never>;
791
755
  }
792
756
 
793
757
  declare class CatsUiTooltipDirective implements OnInit, OnDestroy {
@@ -867,41 +831,361 @@ declare class AccordionItemComponent {
867
831
  static ɵcmp: i0.ɵɵComponentDeclaration<AccordionItemComponent, "cats-ui-accordion-item", never, { "title": { "alias": "title"; "required": false; }; "index": { "alias": "index"; "required": false; }; }, {}, ["contentTemplate"], never, true, never>;
868
832
  }
869
833
 
870
- declare class TabContentDirective {
871
- template: TemplateRef<any>;
872
- constructor(template: TemplateRef<any>);
873
- static ɵfac: i0.ɵɵFactoryDeclaration<TabContentDirective, never>;
874
- static ɵdir: i0.ɵɵDirectiveDeclaration<TabContentDirective, "[tabContent]", never, {}, {}, never, never, true, never>;
834
+ declare class TabContentComponent {
835
+ active: boolean;
836
+ tabId: number;
837
+ static ɵfac: i0.ɵɵFactoryDeclaration<TabContentComponent, never>;
838
+ static ɵcmp: i0.ɵɵComponentDeclaration<TabContentComponent, "cats-ui-tab-content", never, { "active": { "alias": "active"; "required": false; }; "tabId": { "alias": "tabId"; "required": false; }; }, {}, never, ["*"], true, never>;
839
+ }
840
+
841
+ interface TabConfig {
842
+ type?: 'Default' | 'Stroke' | string;
843
+ addTab?: boolean;
844
+ closeTab?: boolean;
845
+ homeTab?: boolean;
846
+ }
847
+ interface TabItem {
848
+ id: number;
849
+ title: string;
850
+ leadingIcon?: string;
851
+ tralingIocn?: string;
852
+ count?: number | string;
853
+ isDisable?: boolean;
854
+ isHome?: boolean;
855
+ }
856
+ declare class TabsetComponent {
857
+ tabs: TabItem[];
858
+ activeTab: number | null;
859
+ activeTabChange: EventEmitter<number | null>;
860
+ tabConfig: TabConfig;
861
+ tabAdded: EventEmitter<TabItem>;
862
+ tabClosed: EventEmitter<number>;
863
+ contents: QueryList<TabContentComponent>;
864
+ counter: number;
865
+ ngAfterContentInit(): void;
866
+ ngOnChanges(changes: SimpleChanges): void;
867
+ addHomeTabIfNeeded(): void;
868
+ setActive(id: number): void;
869
+ closeTab(event: Event, id: number, index: number): void;
870
+ addTab(event: Event): void;
871
+ updateContentActivation(): void;
872
+ static ɵfac: i0.ɵɵFactoryDeclaration<TabsetComponent, never>;
873
+ static ɵcmp: i0.ɵɵComponentDeclaration<TabsetComponent, "cats-ui-tabset", never, { "tabs": { "alias": "tabs"; "required": false; }; "activeTab": { "alias": "activeTab"; "required": false; }; "tabConfig": { "alias": "tabConfig"; "required": false; }; }, { "activeTabChange": "activeTabChange"; "tabAdded": "tabAdded"; "tabClosed": "tabClosed"; }, ["contents"], ["*"], true, never>;
874
+ }
875
+
876
+ type FilterType = 'live' | 'today' | 'week' | 'month' | 'fy' | 'last' | 'customRange' | 'customDate';
877
+ interface TimeFilterOption {
878
+ label: string;
879
+ value: string;
880
+ type?: 'radio' | 'input' | 'submenu';
881
+ children?: TimeFilterOption[];
882
+ default?: boolean;
883
+ custom?: boolean;
884
+ parentDateFormat?: 'dd MMM yyyy' | 'MM/dd/yyyy' | 'yyyy-MM-dd';
885
+ pickerMode?: DatePickerMode;
886
+ time?: boolean;
887
+ extraConfig?: Partial<DatePickerConfig>;
888
+ }
889
+ interface TimeFilterConfig {
890
+ title?: string;
891
+ showReset?: boolean;
892
+ options: TimeFilterOption[];
893
+ }
894
+ interface TimeFilterOutput {
895
+ type: FilterType;
896
+ label?: string;
897
+ startDate?: string;
898
+ endDate?: string;
899
+ value?: number;
900
+ unit?: 'Hours' | 'Days';
901
+ key?: string;
902
+ dates?: any;
903
+ }
904
+ interface TimeFilterValue {
905
+ type: string;
906
+ dates?: any;
907
+ lastValue?: number;
908
+ lastUnit?: 'seconds' | 'minutes' | 'hours' | 'days';
909
+ }
910
+ declare class TimestampFilterComponent implements OnInit {
911
+ private cdr;
912
+ config: TimeFilterConfig;
913
+ selectionChange: EventEmitter<TimeFilterOutput>;
914
+ selectedValue: TimeFilterValue | null;
915
+ radioValue: string | null;
916
+ previousRadioValue: string | null;
917
+ activePicker: TimeFilterOption | null;
918
+ lastValue: number;
919
+ lastUnit: 'seconds' | 'minutes' | 'hours' | 'days';
920
+ selectedDateLabels: Record<string, string>;
921
+ dateControls: Record<string, FormControl>;
922
+ get normalOptions(): TimeFilterOption[];
923
+ get customOptions(): TimeFilterOption[];
924
+ /** Returns the FormControl for the currently active picker. */
925
+ get activePickerControl(): FormControl | null;
926
+ constructor(cdr: ChangeDetectorRef);
927
+ ngOnInit(): void;
928
+ private applyPreset;
929
+ getPickerConfig(option: TimeFilterOption): DatePickerConfig;
930
+ selectOption(option: TimeFilterOption): void;
931
+ onDateApplied(event: any): void;
932
+ /**
933
+ * Cancel: restore radio to whatever was selected before picker opened.
934
+ */
935
+ onCancel(_event: any): void;
936
+ emitLast(): void;
937
+ onLastChange(): void;
938
+ reset(): void;
939
+ private extractStartDate;
940
+ private extractEndDate;
941
+ private buildDateLabel;
942
+ private emit;
943
+ private startOfDay;
944
+ private startOfWeek;
945
+ private startOfFinancialYear;
946
+ private subtractTime;
947
+ static ɵfac: i0.ɵɵFactoryDeclaration<TimestampFilterComponent, never>;
948
+ static ɵcmp: i0.ɵɵComponentDeclaration<TimestampFilterComponent, "cats-ui-timestamp-filter", never, { "config": { "alias": "config"; "required": true; }; "selectedValue": { "alias": "selectedValue"; "required": false; }; }, { "selectionChange": "selectionChange"; }, never, never, true, never>;
949
+ }
950
+
951
+ declare class WizardService {
952
+ private wizards;
953
+ activeStep: i0.WritableSignal<any>;
954
+ stepConfig: i0.WritableSignal<any>;
955
+ open(wizardId: string, config: any): void;
956
+ close(wizardId: string): void;
957
+ nextStep(wizardId: string): void;
958
+ previousStep(wizardId: string): void;
959
+ gotoStep(step: number, wizardId: string): void;
960
+ isOpen(wizardId: string): i0.Signal<any>;
961
+ getConfig(wizardId: string): i0.Signal<any>;
962
+ getCurrentStepIndex(wizardId: string): i0.Signal<any>;
963
+ getCurrentStep(wizardId: string): i0.Signal<any>;
964
+ getProgress(wizardId: string): i0.Signal<number>;
965
+ static ɵfac: i0.ɵɵFactoryDeclaration<WizardService, never>;
966
+ static ɵprov: i0.ɵɵInjectableDeclaration<WizardService>;
875
967
  }
876
968
 
877
- declare class TabHeadingDirective {
878
- template: TemplateRef<any>;
879
- constructor(template: TemplateRef<any>);
880
- static ɵfac: i0.ɵɵFactoryDeclaration<TabHeadingDirective, never>;
881
- static ɵdir: i0.ɵɵDirectiveDeclaration<TabHeadingDirective, "[tabHeading]", never, {}, {}, never, never, true, never>;
969
+ declare class WizardStepDirective {
970
+ templateRef: TemplateRef<any>;
971
+ constructor(templateRef: TemplateRef<any>);
972
+ static ɵfac: i0.ɵɵFactoryDeclaration<WizardStepDirective, never>;
973
+ static ɵdir: i0.ɵɵDirectiveDeclaration<WizardStepDirective, "[wizardStep]", never, {}, {}, never, never, true, never>;
882
974
  }
883
975
 
884
- declare class TabItemComponent {
885
- heading: TabHeadingDirective;
886
- content: TabContentDirective;
887
- static ɵfac: i0.ɵɵFactoryDeclaration<TabItemComponent, never>;
888
- static ɵcmp: i0.ɵɵComponentDeclaration<TabItemComponent, "cats-ui-tab-item", never, {}, {}, ["heading", "content"], never, true, never>;
976
+ declare class WizardComponent {
977
+ private commonService;
978
+ wizardId: string;
979
+ title: string;
980
+ closed: EventEmitter<void>;
981
+ stepTemplates: QueryList<WizardStepDirective>;
982
+ showProgressBar: boolean;
983
+ showStepBadge: boolean;
984
+ expandable: boolean;
985
+ isExpanded: boolean;
986
+ steps: any;
987
+ activeStep: any;
988
+ templates: WizardStepDirective[];
989
+ constructor(commonService: WizardService);
990
+ ngAfterContentInit(): void;
991
+ toggleExpand(): void;
992
+ onEscPressed(): void;
993
+ get currentStepIndex(): number;
994
+ get wizardSteps(): any[];
995
+ get currentTemplate(): i0.TemplateRef<any>;
996
+ get currentStepLabel(): string;
997
+ get currentStepNumber(): number;
998
+ goToStep(step: number): void;
999
+ closeModal(): void;
1000
+ static ɵfac: i0.ɵɵFactoryDeclaration<WizardComponent, never>;
1001
+ static ɵcmp: i0.ɵɵComponentDeclaration<WizardComponent, "cats-ui-wizard", never, { "wizardId": { "alias": "wizardId"; "required": false; }; "title": { "alias": "title"; "required": false; }; "showProgressBar": { "alias": "showProgressBar"; "required": false; }; "showStepBadge": { "alias": "showStepBadge"; "required": false; }; }, { "closed": "closed"; }, ["stepTemplates"], never, true, never>;
889
1002
  }
890
1003
 
891
- declare class TabComponent {
892
- activeTab: number;
893
- disabledTabs: number[];
894
- selectTab: EventEmitter<number>;
895
- items: QueryList<TabItemComponent>;
1004
+ declare class FileUploadComponent implements ControlValueAccessor {
1005
+ placeholder: string;
1006
+ errorMessage: string;
1007
+ disabled: boolean;
1008
+ multiple: boolean;
1009
+ /** Button position: 'left' (prefix) | 'right' (suffix) */
1010
+ buttonPosition: 'left' | 'right';
1011
+ maxSize: number | null;
1012
+ minSize: number | null;
1013
+ helperText: string;
1014
+ onfileChange: EventEmitter<any>;
1015
+ onfileRemove: EventEmitter<any>;
1016
+ /**
1017
+ * Accepted MIME types or extensions, comma-separated.
1018
+ * e.g. 'image/png,image/jpeg' or '.png,.jpg,.pdf'
1019
+ * Passed directly to the hidden <input accept="..."> attribute.
1020
+ * Also used for runtime validation.
1021
+ * null = accept all
1022
+ */
1023
+ accept: string | null;
1024
+ value: File[];
1025
+ isFocused: boolean;
1026
+ validationError: string;
1027
+ control: FormControl<any> | null;
1028
+ onChange: (value: File[]) => void;
1029
+ onTouched: () => void;
1030
+ writeValue(files: File[] | null | undefined): void;
1031
+ registerOnChange(fn: (value: File[]) => void): void;
1032
+ registerOnTouched(fn: () => void): void;
1033
+ setDisabledState(isDisabled: boolean): void;
1034
+ validate(control: FormControl): any;
896
1035
  /**
897
- * @description Sets active
898
- * @author Shiva Kant
899
- * @param index
900
- */
901
- setActive(index: number): void;
902
- static ɵfac: i0.ɵɵFactoryDeclaration<TabComponent, never>;
903
- static ɵcmp: i0.ɵɵComponentDeclaration<TabComponent, "cats-ui-tab", never, { "activeTab": { "alias": "activeTab"; "required": false; }; "disabledTabs": { "alias": "disabledTabs"; "required": false; }; }, { "selectTab": "selectTab"; }, ["items"], never, true, never>;
1036
+ * Validates a single file against minSize, maxSize, and accept rules.
1037
+ * Returns an error string, or empty string if valid.
1038
+ */
1039
+ private validateFile;
1040
+ /** Validates a batch; sets validationError and returns only valid files. */
1041
+ private processFiles;
1042
+ onFileSelect(event: Event, input: HTMLInputElement): void;
1043
+ onDrop(event: DragEvent): void;
1044
+ onDragOver(event: DragEvent): void;
1045
+ removeFile(index: number, input?: HTMLInputElement): void;
1046
+ /** Human-readable byte string: 1024 → "1 KB", 5242880 → "5 MB" */
1047
+ formatBytes(bytes: number): string;
1048
+ /**
1049
+ * Builds a human-readable hint string from the current constraints.
1050
+ * e.g. "PNG, JPG • Max 5 MB • Min 10 KB"
1051
+ */
1052
+ get isFilled(): boolean;
1053
+ /** Combines external errorMessage prop with internal validation errors. */
1054
+ get displayError(): string;
1055
+ get hasError(): boolean;
1056
+ static ɵfac: i0.ɵɵFactoryDeclaration<FileUploadComponent, never>;
1057
+ static ɵcmp: i0.ɵɵComponentDeclaration<FileUploadComponent, "cats-ui-file-upload", never, { "placeholder": { "alias": "placeholder"; "required": false; }; "errorMessage": { "alias": "errorMessage"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "multiple": { "alias": "multiple"; "required": false; }; "buttonPosition": { "alias": "buttonPosition"; "required": false; }; "maxSize": { "alias": "maxSize"; "required": false; }; "minSize": { "alias": "minSize"; "required": false; }; "helperText": { "alias": "helperText"; "required": false; }; "accept": { "alias": "accept"; "required": false; }; }, { "onfileChange": "onfileChange"; "onfileRemove": "onfileRemove"; }, never, never, true, never>;
1058
+ }
1059
+
1060
+ interface HeaderConfig {
1061
+ brandLogo: string;
1062
+ productLogo: string;
1063
+ showDropdown?: boolean;
1064
+ showGlobalIcon?: boolean;
1065
+ showAiAgent?: boolean;
1066
+ }
1067
+ declare class HeaderComponent {
1068
+ headerConfig: HeaderConfig;
1069
+ dropdownItems: any[];
1070
+ onDropdownSelection: EventEmitter<any>;
1071
+ profileOpen: boolean;
1072
+ dropdownOpen: boolean;
1073
+ selectedItem: any;
1074
+ ngOnInit(): void;
1075
+ onSelect(item: any): void;
1076
+ toggleMenu(): void;
1077
+ toggleDropdown(): void;
1078
+ closeMenu(): void;
1079
+ static ɵfac: i0.ɵɵFactoryDeclaration<HeaderComponent, never>;
1080
+ static ɵcmp: i0.ɵɵComponentDeclaration<HeaderComponent, "cats-ui-header", never, { "headerConfig": { "alias": "headerConfig"; "required": false; }; "dropdownItems": { "alias": "dropdownItems"; "required": false; }; }, { "onDropdownSelection": "onDropdownSelection"; }, never, never, true, never>;
1081
+ }
1082
+
1083
+ declare class DialogRef<T = any> {
1084
+ id: string;
1085
+ private afterClosed$;
1086
+ constructor(id: string);
1087
+ close(result?: T): void;
1088
+ afterClosed(): Observable<T | undefined>;
1089
+ }
1090
+
1091
+ declare class DialogBoxComponent {
1092
+ content: any;
1093
+ config: DialogConfig;
1094
+ dialogRef: DialogRef;
1095
+ expandable: boolean;
1096
+ vc: ViewContainerRef;
1097
+ isExpanded: boolean;
1098
+ ngAfterViewInit(): void;
1099
+ toggleExpand(): void;
1100
+ onBackdropClick(): void;
1101
+ closeModal(): void;
1102
+ static ɵfac: i0.ɵɵFactoryDeclaration<DialogBoxComponent, never>;
1103
+ static ɵcmp: i0.ɵɵComponentDeclaration<DialogBoxComponent, "cats-ui-dialog-box", never, { "content": { "alias": "content"; "required": false; }; "config": { "alias": "config"; "required": false; }; "dialogRef": { "alias": "dialogRef"; "required": false; }; "expandable": { "alias": "expandable"; "required": false; }; }, {}, never, never, true, never>;
1104
+ }
1105
+
1106
+ declare class DialogBoxService {
1107
+ private appRef;
1108
+ private injector;
1109
+ private dialogs;
1110
+ constructor(appRef: ApplicationRef, injector: EnvironmentInjector);
1111
+ open(componentOrTemplate: any, config?: DialogConfig): DialogRef;
1112
+ close(id: string): void;
1113
+ closeAll(): void;
1114
+ private generateId;
1115
+ static ɵfac: i0.ɵɵFactoryDeclaration<DialogBoxService, never>;
1116
+ static ɵprov: i0.ɵɵInjectableDeclaration<DialogBoxService>;
1117
+ }
1118
+
1119
+ interface SidebarConfig {
1120
+ sidebarType?: 'sectional' | string;
1121
+ switchOrganiser?: boolean;
1122
+ }
1123
+ interface SidebarAttribute {
1124
+ attributeId?: number;
1125
+ attributeName: string;
1126
+ icon?: string;
1127
+ activeIcon?: string;
1128
+ url?: string;
1129
+ }
1130
+ interface SidebarFeature {
1131
+ featureId?: number;
1132
+ moduleId?: number;
1133
+ featuresName: string;
1134
+ icon?: string;
1135
+ activeIcon?: string;
1136
+ expandable?: boolean;
1137
+ url?: string;
1138
+ isEnable?: boolean;
1139
+ attributes?: SidebarAttribute[];
1140
+ }
1141
+ interface SidebarModule {
1142
+ moduleName: string;
1143
+ icon?: string;
1144
+ activeIcon?: string;
1145
+ expandable?: boolean;
1146
+ url?: string;
1147
+ isEnable?: boolean;
1148
+ features: SidebarFeature[];
1149
+ }
1150
+ declare class SidebarComponent {
1151
+ private router;
1152
+ appMenus: SidebarModule[];
1153
+ isCollapsed: boolean;
1154
+ sidebarConfig: SidebarConfig;
1155
+ expandedFeatures: Set<string>;
1156
+ activeSidebar: EventEmitter<any>;
1157
+ collapsedOpenModule: number | null;
1158
+ collapsedOpenFeature: string | null;
1159
+ activeItem: {
1160
+ moduleIndex: number;
1161
+ featureIndex: number;
1162
+ attrIndex: number;
1163
+ } | null;
1164
+ constructor(router: Router);
1165
+ /** A feature is expandable if it has at least one attribute */
1166
+ isExpandable(feature: SidebarFeature): boolean;
1167
+ ngOnInit(): void;
1168
+ toggleCollapse(): void;
1169
+ expandedModules: Set<number>;
1170
+ toggleModule(moduleIndex: number): void;
1171
+ isModuleExpanded(moduleIndex: number): boolean;
1172
+ toggleFeature(moduleIndex: number, featureIndex: number): void;
1173
+ isFeatureExpanded(moduleIndex: number, featureIndex: number): boolean;
1174
+ setActiveItem(moduleIndex: number, featureIndex: number, attrIndex: number): void;
1175
+ onFeatureClick(moduleIndex: number, featureIndex: number, feature: SidebarFeature): void;
1176
+ isActiveItem(moduleIndex: number, featureIndex?: number, attrIndex?: number): boolean;
1177
+ collapsedModuleIndex: number | null;
1178
+ collapsedFeatureIndex: number | null;
1179
+ openAttributeFeatureIndex: number | null;
1180
+ isCollapsedIconActive(mIdx: number, fIdx?: number): boolean;
1181
+ onCollapsedSectionalIconClick(mIdx: number, fIdx: number, source?: string): void;
1182
+ onCollapsedModuleIconClick(mIdx: number): void;
1183
+ onCollapsedFeatureClick(mIdx: number, fIdx: number): void;
1184
+ navigateToItem(module: SidebarModule, feature?: SidebarFeature, attribute?: SidebarAttribute): void;
1185
+ handleOutsideClick(event: Event): void;
1186
+ static ɵfac: i0.ɵɵFactoryDeclaration<SidebarComponent, never>;
1187
+ static ɵcmp: i0.ɵɵComponentDeclaration<SidebarComponent, "cats-ui-sidebar", never, { "appMenus": { "alias": "appMenus"; "required": false; }; "sidebarConfig": { "alias": "sidebarConfig"; "required": false; }; }, { "activeSidebar": "activeSidebar"; }, never, never, true, never>;
904
1188
  }
905
1189
 
906
- export { AccordionComponent, AccordionItemComponent, AutoCompleteMultiSelectComponent, AutoCompleteMultiSelectConfig, AutoCompleteSingleSelectComponent, AutoCompleteSingleSelectConfig, CatsUiService, CatsUiTooltipDirective, CheckBoxConfig, CheckBoxSubtask, CheckboxButtonComponent, DROPDOWN_CONTROL_VALUE_ACCESSOR, DROPDOWN_CONTROL_VALUE_VALIDATOR, DateTimePickerComponent, InputComponent, InputConfig, MULTI_SELECT_CONTROL_VALUE_ACCESSOR, MULTI_SELECT_CONTROL_VALUE_VALIDATOR, MultiSelectComponent, MultiSelectConfig, OutsideClickDirective, RadioButtonComponent, SINGLE_SELECT_CONTROL_VALUE_ACCESSOR, SINGLE_SELECT_CONTROL_VALUE_VALIDATOR, SearchBoxComponent, SearchConfig, SingleSelectComponent, SingleSelectConfig, TabComponent, TabContentDirective, TabHeadingDirective, TabItemComponent, ToggleConfig, ToogleButtonComponent };
907
- export type { DateConfig, RadioButtonConfig };
1190
+ export { AccordionComponent, AccordionItemComponent, AutoCompleteMultiSelectComponent, AutoCompleteMultiSelectConfig, AutoCompleteSingleSelectComponent, AutoCompleteSingleSelectConfig, CatsUiService, CatsUiTooltipDirective, CheckBoxConfig, CheckBoxSubtask, CheckboxButtonComponent, CustomDatePickerComponent, DROPDOWN_CONTROL_VALUE_ACCESSOR, DROPDOWN_CONTROL_VALUE_VALIDATOR, DialogBoxComponent, DialogBoxService, FileUploadComponent, HeaderComponent, InputComponent, InputConfig, MULTI_SELECT_CONTROL_VALUE_ACCESSOR, MULTI_SELECT_CONTROL_VALUE_VALIDATOR, MultiSelectComponent, MultiSelectConfig, OutsideClickDirective, RadioButtonComponent, SINGLE_SELECT_CONTROL_VALUE_ACCESSOR, SINGLE_SELECT_CONTROL_VALUE_VALIDATOR, SearchBoxComponent, SearchConfig, SidebarComponent, SingleSelectComponent, SingleSelectConfig, TabContentComponent, TabsetComponent, TimestampFilterComponent, ToggleConfig, ToogleButtonComponent, WizardComponent, WizardService, WizardStepDirective };
1191
+ export type { CalenderView, DatePickerConfig, DatePickerMode, DateRange, DateTimeResult, DialogConfig, FilterType, HeaderConfig, RadioButtonConfig, SidebarAttribute, SidebarConfig, SidebarFeature, SidebarModule, TabConfig, TabItem, TimeFilterConfig, TimeFilterOption, TimeFilterOutput, TimeFilterValue };