@ieeesa-npm/presentation 0.33.16 → 0.33.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2022/lib/components/autocomplete/autocomplete.component.mjs +104 -6
- package/esm2022/lib/components/date-picker/date-picker.component.mjs +91 -7
- package/esm2022/lib/components/dynamic-form/dynamic-form.component.mjs +8 -5
- package/esm2022/lib/components/modal-info/modal-info.component.mjs +3 -3
- package/esm2022/lib/components/multi-select-autocomplete/multi-select-autocomplete.component.mjs +89 -19
- package/esm2022/lib/components/select/select.component.mjs +125 -7
- package/esm2022/lib/components/stepper/stepper.component.mjs +5 -3
- package/esm2022/lib/components/tabs/tabs.component.mjs +3 -3
- package/esm2022/lib/components/time-picker/time-picker.component.mjs +65 -6
- package/esm2022/lib/models/field-config.model.mjs +1 -1
- package/fesm2022/ieeesa-npm-presentation.mjs +483 -52
- package/fesm2022/ieeesa-npm-presentation.mjs.map +1 -1
- package/lib/components/autocomplete/autocomplete.component.d.ts +13 -1
- package/lib/components/date-picker/date-picker.component.d.ts +12 -3
- package/lib/components/multi-select-autocomplete/multi-select-autocomplete.component.d.ts +18 -0
- package/lib/components/select/select.component.d.ts +16 -3
- package/lib/components/time-picker/time-picker.component.d.ts +12 -2
- package/lib/models/field-config.model.d.ts +6 -0
- package/package.json +1 -1
|
@@ -17,6 +17,7 @@ import * as i0 from "@angular/core";
|
|
|
17
17
|
*/
|
|
18
18
|
export declare class AutocompleteComponent implements OnInit, FormField, OnDestroy, AfterViewInit {
|
|
19
19
|
private formUtilityService;
|
|
20
|
+
private elementRef;
|
|
20
21
|
config: FieldConfig;
|
|
21
22
|
group: FormGroup;
|
|
22
23
|
value: string;
|
|
@@ -30,7 +31,11 @@ export declare class AutocompleteComponent implements OnInit, FormField, OnDestr
|
|
|
30
31
|
autoComplete: ElementRef;
|
|
31
32
|
destroy$: Subject<boolean>;
|
|
32
33
|
autocompleteConstInfo: any;
|
|
33
|
-
constructor(formUtilityService: FormUtilityService);
|
|
34
|
+
constructor(formUtilityService: FormUtilityService, elementRef: ElementRef<HTMLElement>);
|
|
35
|
+
private formOverlayScrollContainer?;
|
|
36
|
+
private readonly preferredAutocompleteOverlayHeight;
|
|
37
|
+
private readonly overlayWheelListener;
|
|
38
|
+
private readonly formScrollListener;
|
|
34
39
|
/**
|
|
35
40
|
* Implementation of ngOnInit lifecycle hook method to initialize components instance properties.
|
|
36
41
|
* @memberof AutocompleteComponent
|
|
@@ -73,6 +78,13 @@ export declare class AutocompleteComponent implements OnInit, FormField, OnDestr
|
|
|
73
78
|
* @memberof AutocompleteComponent
|
|
74
79
|
*/
|
|
75
80
|
ngOnDestroy(): void;
|
|
81
|
+
onAutocompleteOpen(): void;
|
|
82
|
+
onAutocompleteClose(): void;
|
|
83
|
+
private setOverlayClipBounds;
|
|
84
|
+
private getFormOverlayScrollContainer;
|
|
85
|
+
private updateOverlayClipBounds;
|
|
86
|
+
private makeRoomForAutocompleteOverlay;
|
|
87
|
+
private clearOverlayClipBounds;
|
|
76
88
|
static ɵfac: i0.ɵɵFactoryDeclaration<AutocompleteComponent, never>;
|
|
77
89
|
static ɵcmp: i0.ɵɵComponentDeclaration<AutocompleteComponent, "ieeesa-autocomplete", never, { "autoCompleteOptions": { "alias": "autoCompleteOptions"; "required": false; }; "isSelectedOptionsVisible": { "alias": "isSelectedOptionsVisible"; "required": false; }; }, { "autoCompleteSearchValue": "autoCompleteSearchValue"; "autoCompleteClearSearchValue": "autoCompleteClearSearchValue"; "autoCompleteOptionSelected": "autoCompleteOptionSelected"; }, never, never, true, never>;
|
|
78
90
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ChangeDetectorRef, EventEmitter, OnInit } from '@angular/core';
|
|
1
|
+
import { ChangeDetectorRef, ElementRef, EventEmitter, OnDestroy, OnInit } from '@angular/core';
|
|
2
2
|
import { FormBuilder, FormGroup } from '@angular/forms';
|
|
3
3
|
import { MomentDateAdapter } from '@angular/material-moment-adapter';
|
|
4
4
|
import { DatePickerHeaderComponent } from '../../components/date-picker-header/date-picker-header.component';
|
|
@@ -27,11 +27,12 @@ export declare class CustomDateAdapter extends MomentDateAdapter {
|
|
|
27
27
|
* @implements {OnInit}
|
|
28
28
|
* @implements {AfterViewInit}
|
|
29
29
|
*/
|
|
30
|
-
export declare class DatePickerComponent implements FormField, OnInit {
|
|
30
|
+
export declare class DatePickerComponent implements FormField, OnInit, OnDestroy {
|
|
31
31
|
private fb;
|
|
32
32
|
private changeDetectorRef;
|
|
33
33
|
private datepickerService;
|
|
34
34
|
private formUtilityService;
|
|
35
|
+
private elementRef;
|
|
35
36
|
config: FieldConfig;
|
|
36
37
|
group: FormGroup;
|
|
37
38
|
datePickerHeader: typeof DatePickerHeaderComponent;
|
|
@@ -81,7 +82,9 @@ export declare class DatePickerComponent implements FormField, OnInit {
|
|
|
81
82
|
}>;
|
|
82
83
|
calendarSelectedDate: Date;
|
|
83
84
|
buttonActionsInfo: any;
|
|
84
|
-
|
|
85
|
+
private formOverlayScrollContainer?;
|
|
86
|
+
private readonly overlayWheelListener;
|
|
87
|
+
constructor(fb: FormBuilder, changeDetectorRef: ChangeDetectorRef, datepickerService: DatepickerService, formUtilityService: FormUtilityService, elementRef: ElementRef<HTMLElement>);
|
|
85
88
|
/**
|
|
86
89
|
* Implementation of ngOnInit lifecycle hook method to creates config if its undefined and sets components instance variables if config is defined. Sets the form group value if form group is defined.
|
|
87
90
|
* @memberof DatePickerComponent
|
|
@@ -134,6 +137,12 @@ export declare class DatePickerComponent implements FormField, OnInit {
|
|
|
134
137
|
* @memberof DatePickerComponent
|
|
135
138
|
*/
|
|
136
139
|
onDatePickerOpen(controlName: string): void;
|
|
140
|
+
onDatePickerClose(): void;
|
|
141
|
+
ngOnDestroy(): void;
|
|
142
|
+
private setOverlayClipBounds;
|
|
143
|
+
private scrollFieldIntoViewForCalendar;
|
|
144
|
+
private getFormOverlayScrollContainer;
|
|
145
|
+
private clearOverlayClipBounds;
|
|
137
146
|
static ɵfac: i0.ɵɵFactoryDeclaration<DatePickerComponent, never>;
|
|
138
147
|
static ɵcmp: i0.ɵɵComponentDeclaration<DatePickerComponent, "ieeesa-date-picker", never, { "selectedDates": { "alias": "selectedDates"; "required": false; }; "selectedRange": { "alias": "selectedRange"; "required": false; }; "calendarType": { "alias": "calendarType"; "required": false; }; "formControlName": { "alias": "formControlName"; "required": false; }; "placeholderLabel": { "alias": "placeholderLabel"; "required": false; }; "isDisabled": { "alias": "isDisabled"; "required": false; }; "isLabelAlignedLeft": { "alias": "isLabelAlignedLeft"; "required": false; }; "datepickerLabel": { "alias": "datepickerLabel"; "required": false; }; "dateRange": { "alias": "dateRange"; "required": false; }; "minDate": { "alias": "minDate"; "required": false; }; "maxDate": { "alias": "maxDate"; "required": false; }; }, { "selectedDate": "selectedDate"; "selectedDateRange": "selectedDateRange"; }, never, never, true, never>;
|
|
139
148
|
}
|
|
@@ -87,6 +87,24 @@ export declare class MultiSelectAutocompleteComponent implements OnInit, FormFie
|
|
|
87
87
|
* @memberof MultiSelectAutocompleteComponent
|
|
88
88
|
*/
|
|
89
89
|
onChange(option: any): AutoCompleteOption;
|
|
90
|
+
/**
|
|
91
|
+
* Clears the typeahead search text from both the reactive form control and the
|
|
92
|
+
* native input element without touching the selected chips. Uses
|
|
93
|
+
* `emitEvent: false` so the valueChanges search stream is not re-triggered.
|
|
94
|
+
* @memberof MultiSelectAutocompleteComponent
|
|
95
|
+
*/
|
|
96
|
+
private clearSearchInput;
|
|
97
|
+
/**
|
|
98
|
+
* Fires when focus leaves the search input (click outside / tab away). If text
|
|
99
|
+
* was typed but never committed as a chip (i.e. nothing was picked from the
|
|
100
|
+
* dropdown), clear it so stale search text is not left behind. Deferred with a
|
|
101
|
+
* short timeout so that if the blur was caused by clicking a dropdown option,
|
|
102
|
+
* onChange commits the selection first (and has already cleared the text),
|
|
103
|
+
* making this a no-op in that case. Clicking back into the same field does not
|
|
104
|
+
* blur it, so the text is preserved while the user is still editing.
|
|
105
|
+
* @memberof MultiSelectAutocompleteComponent
|
|
106
|
+
*/
|
|
107
|
+
onInputBlur(): void;
|
|
90
108
|
/**
|
|
91
109
|
* Formats the selected options and emits the multiSelectAutoCompleteOptionSelected event.
|
|
92
110
|
* @param {SelectOption[]} selectedOptions -Array of selected options.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { EventEmitter, OnInit, AfterViewInit, QueryList } from '@angular/core';
|
|
1
|
+
import { ElementRef, EventEmitter, OnInit, AfterViewInit, OnDestroy, QueryList } from '@angular/core';
|
|
2
2
|
import { FormGroup } from '@angular/forms';
|
|
3
3
|
import { SelectOption } from '@ieeesa-npm/models';
|
|
4
4
|
import { FieldConfig } from '../../models/field-config.model';
|
|
@@ -15,8 +15,9 @@ import * as i0 from "@angular/core";
|
|
|
15
15
|
* @implements {AfterViewInit}
|
|
16
16
|
* @implements {OnDestroy}
|
|
17
17
|
*/
|
|
18
|
-
export declare class SelectComponent implements OnInit, AfterViewInit {
|
|
18
|
+
export declare class SelectComponent implements OnInit, AfterViewInit, OnDestroy {
|
|
19
19
|
private formUtilityService;
|
|
20
|
+
private elementRef;
|
|
20
21
|
formFields: QueryList<SearchComponent>;
|
|
21
22
|
group: FormGroup;
|
|
22
23
|
config: FieldConfig;
|
|
@@ -28,6 +29,8 @@ export declare class SelectComponent implements OnInit, AfterViewInit {
|
|
|
28
29
|
private _selectedOptions;
|
|
29
30
|
private _isSortNeeded;
|
|
30
31
|
private unsortedDropdownOptions;
|
|
32
|
+
private formOverlayScrollContainer?;
|
|
33
|
+
private readonly overlayWheelListener;
|
|
31
34
|
/**
|
|
32
35
|
* Takes isSortNeeded as input to check if the passed options are sorted or not.
|
|
33
36
|
* @memberof SelectComponent
|
|
@@ -57,7 +60,7 @@ export declare class SelectComponent implements OnInit, AfterViewInit {
|
|
|
57
60
|
optionSelected: EventEmitter<SelectOption>;
|
|
58
61
|
optionSearched: EventEmitter<string>;
|
|
59
62
|
dropdownOpenedChange: EventEmitter<SelectOpenedState>;
|
|
60
|
-
constructor(formUtilityService: FormUtilityService);
|
|
63
|
+
constructor(formUtilityService: FormUtilityService, elementRef: ElementRef<HTMLElement>);
|
|
61
64
|
/**
|
|
62
65
|
* Initializes components instance properties from config if its defined otherwise creates form group and config.
|
|
63
66
|
* @memberof SelectComponent
|
|
@@ -75,6 +78,16 @@ export declare class SelectComponent implements OnInit, AfterViewInit {
|
|
|
75
78
|
* @memberof SelectComponent
|
|
76
79
|
*/
|
|
77
80
|
updateArrowDirection(opened: boolean): void;
|
|
81
|
+
prepareSelectOverlayPosition(): void;
|
|
82
|
+
/**
|
|
83
|
+
* Clears form overlay bounds when the component is destroyed while open.
|
|
84
|
+
* @memberof SelectComponent
|
|
85
|
+
*/
|
|
86
|
+
ngOnDestroy(): void;
|
|
87
|
+
private setOverlayClipBounds;
|
|
88
|
+
private getFormOverlayScrollContainer;
|
|
89
|
+
private clearOverlayClipBounds;
|
|
90
|
+
private keepTopSelectPanelInsideFormBody;
|
|
78
91
|
/**
|
|
79
92
|
* Takes the index and the current option as arguments and needs to return the unique identifier for this option.
|
|
80
93
|
* @param {number} index
|
|
@@ -1,20 +1,30 @@
|
|
|
1
|
-
import { ElementRef, EventEmitter } from '@angular/core';
|
|
1
|
+
import { ElementRef, EventEmitter, OnDestroy } from '@angular/core';
|
|
2
2
|
import { FormGroup } from '@angular/forms';
|
|
3
3
|
import { FieldConfig } from '../../models/field-config.model';
|
|
4
4
|
import { SelectedTime } from '../../models/selected-time.model';
|
|
5
5
|
import * as i0 from "@angular/core";
|
|
6
|
-
export declare class TimePickerComponent {
|
|
6
|
+
export declare class TimePickerComponent implements OnDestroy {
|
|
7
|
+
private elementRef;
|
|
7
8
|
config: FieldConfig;
|
|
8
9
|
group: FormGroup;
|
|
9
10
|
formTimeSelected: EventEmitter<SelectedTime>;
|
|
10
11
|
constants: any;
|
|
11
12
|
picker: ElementRef;
|
|
13
|
+
private formOverlayScrollContainer?;
|
|
14
|
+
private readonly overlayWheelListener;
|
|
15
|
+
constructor(elementRef: ElementRef<HTMLElement>);
|
|
12
16
|
/**
|
|
13
17
|
* Handles form time selection event
|
|
14
18
|
* @type {void}
|
|
15
19
|
* @memberof TimePickerComponent
|
|
16
20
|
*/
|
|
17
21
|
onTimeSelection(time: string): void;
|
|
22
|
+
onTimePickerOpen(): void;
|
|
23
|
+
onTimePickerClose(): void;
|
|
24
|
+
ngOnDestroy(): void;
|
|
25
|
+
private setOverlayClipBounds;
|
|
26
|
+
private getFormOverlayScrollContainer;
|
|
27
|
+
private clearOverlayClipBounds;
|
|
18
28
|
static ɵfac: i0.ɵɵFactoryDeclaration<TimePickerComponent, never>;
|
|
19
29
|
static ɵcmp: i0.ɵɵComponentDeclaration<TimePickerComponent, "ieeesa-time-picker", never, {}, { "formTimeSelected": "formTimeSelected"; }, never, never, true, never>;
|
|
20
30
|
}
|
|
@@ -84,6 +84,12 @@ export interface FieldConfig {
|
|
|
84
84
|
canHideColorPicker?: boolean;
|
|
85
85
|
canHideTextInput?: boolean;
|
|
86
86
|
multiSelectAutoCompleteOptions?: AutoCompleteOption[];
|
|
87
|
+
/**
|
|
88
|
+
* When set, controls the reactive form update/validation strategy for this
|
|
89
|
+
* field (e.g. 'blur' so validation errors surface only after the user leaves
|
|
90
|
+
* the field, avoiding an error flash while interacting).
|
|
91
|
+
*/
|
|
92
|
+
updateOn?: 'change' | 'blur' | 'submit';
|
|
87
93
|
editorConfig?: EditorConfig;
|
|
88
94
|
isAllowAnyFileType?: boolean;
|
|
89
95
|
alignBrowsedFiles?: AlignBrowsedFiles;
|