cloud-ide-element 1.0.4 → 1.0.5
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/README.md +63 -271
- package/fesm2022/cloud-ide-element.mjs +614 -618
- package/fesm2022/cloud-ide-element.mjs.map +1 -1
- package/index.d.ts +1362 -3
- package/package.json +3 -30
- package/esm2022/cloud-ide-element.mjs +0 -5
- package/esm2022/lib/components/confirmation-modal/confirmation-modal.component.mjs +0 -182
- package/esm2022/lib/components/data-grid/data-grid.component.mjs +0 -1363
- package/esm2022/lib/components/data-grid/data-grid.types.mjs +0 -37
- package/esm2022/lib/components/dropdown/dropdown.component.mjs +0 -396
- package/esm2022/lib/components/global-notifications/global-notifications.component.mjs +0 -30
- package/esm2022/lib/components/json-editor/json-editor.component.mjs +0 -521
- package/esm2022/lib/components/skeleton-loader/skeleton-loader.component.mjs +0 -33
- package/esm2022/lib/components/toast-notification/toast-notification.component.mjs +0 -152
- package/esm2022/lib/elements/button/cide-ele-button.component.mjs +0 -249
- package/esm2022/lib/elements/file-input/file-input.component.mjs +0 -83
- package/esm2022/lib/elements/icon/icon.component.mjs +0 -26
- package/esm2022/lib/elements/input/input.component.mjs +0 -467
- package/esm2022/lib/elements/select/select.component.mjs +0 -471
- package/esm2022/lib/elements/spinner/spinner.component.mjs +0 -32
- package/esm2022/lib/elements/tab/cide-ele-tab.component.mjs +0 -74
- package/esm2022/lib/elements/textarea/textarea.component.mjs +0 -157
- package/esm2022/lib/services/confirmation.service.mjs +0 -151
- package/esm2022/lib/services/dropdown-manager.service.mjs +0 -93
- package/esm2022/lib/services/notification.service.mjs +0 -196
- package/esm2022/lib/utils/directives/resizer/resizer.directive.mjs +0 -231
- package/esm2022/lib/utils/directives/tooltip/tooltip.directive.mjs +0 -294
- package/esm2022/lib/utils/pipes/capitalize/capitalize.pipe.mjs +0 -38
- package/esm2022/lib/utils/services/elements/elements.service.mjs +0 -39
- package/esm2022/public-api.mjs +0 -31
- package/lib/components/confirmation-modal/confirmation-modal.component.d.ts +0 -16
- package/lib/components/data-grid/data-grid.component.d.ts +0 -244
- package/lib/components/data-grid/data-grid.types.d.ts +0 -146
- package/lib/components/dropdown/dropdown.component.d.ts +0 -75
- package/lib/components/global-notifications/global-notifications.component.d.ts +0 -5
- package/lib/components/json-editor/json-editor.component.d.ts +0 -116
- package/lib/components/skeleton-loader/skeleton-loader.component.d.ts +0 -11
- package/lib/components/toast-notification/toast-notification.component.d.ts +0 -13
- package/lib/elements/button/cide-ele-button.component.d.ts +0 -85
- package/lib/elements/file-input/file-input.component.d.ts +0 -25
- package/lib/elements/icon/icon.component.d.ts +0 -9
- package/lib/elements/input/input.component.d.ts +0 -182
- package/lib/elements/select/select.component.d.ts +0 -91
- package/lib/elements/spinner/spinner.component.d.ts +0 -19
- package/lib/elements/tab/cide-ele-tab.component.d.ts +0 -26
- package/lib/elements/textarea/textarea.component.d.ts +0 -47
- package/lib/services/confirmation.service.d.ts +0 -65
- package/lib/services/dropdown-manager.service.d.ts +0 -22
- package/lib/services/notification.service.d.ts +0 -81
- package/lib/utils/directives/resizer/resizer.directive.d.ts +0 -44
- package/lib/utils/directives/tooltip/tooltip.directive.d.ts +0 -43
- package/lib/utils/pipes/capitalize/capitalize.pipe.d.ts +0 -7
- package/lib/utils/services/elements/elements.service.d.ts +0 -12
- package/public-api.d.ts +0 -22
package/index.d.ts
CHANGED
|
@@ -1,5 +1,1364 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { PipeTransform, OnChanges, OnInit, EventEmitter, SimpleChanges, OnDestroy, Renderer2, ElementRef, AfterContentInit, QueryList, TemplateRef } from '@angular/core';
|
|
3
|
+
import { ControlValueAccessor, Validator, AbstractControl, ValidationErrors } from '@angular/forms';
|
|
4
|
+
import { elementStyleType, labelPlacementType, labelDirType, autocapitalizeType, autocompleteType, controlType, inputType, themeSize, spinnerType, iconType, selectSearchType, ICoreSype, GetElementDataRequest } from 'cloud-ide-lms-model';
|
|
5
|
+
import { Router, NavigationExtras } from '@angular/router';
|
|
6
|
+
import { BehaviorSubject } from 'rxjs';
|
|
7
|
+
import * as cloud_ide_element from 'cloud-ide-element';
|
|
8
|
+
|
|
9
|
+
declare class CapitalizePipe implements PipeTransform {
|
|
10
|
+
transform(value: string, capitalizationMethod: 'allUpperCase' | 'titleCase' | 'sentenceCase'): string;
|
|
11
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CapitalizePipe, never>;
|
|
12
|
+
static ɵpipe: i0.ɵɵPipeDeclaration<CapitalizePipe, "capitalize", true>;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
/** @description type to register error related to control */
|
|
16
|
+
type ErrorValidationStatus = {
|
|
17
|
+
maxlength?: string;
|
|
18
|
+
minlength?: string;
|
|
19
|
+
required?: string;
|
|
20
|
+
};
|
|
21
|
+
type ValidationStatus = {
|
|
22
|
+
validation: ErrorValidationStatus;
|
|
23
|
+
status: boolean;
|
|
24
|
+
};
|
|
25
|
+
declare class CideInputComponent implements ControlValueAccessor, Validator, OnChanges, OnInit {
|
|
26
|
+
capitalizePipe: CapitalizePipe;
|
|
27
|
+
private elementService;
|
|
28
|
+
constructor();
|
|
29
|
+
/**
|
|
30
|
+
* @description to se the visual of control like solid control offerd by material design or outline with a border
|
|
31
|
+
* @options solid | outline | standard
|
|
32
|
+
*/
|
|
33
|
+
fill: elementStyleType;
|
|
34
|
+
/** @description Lable of control (Title), Like Name, Email */
|
|
35
|
+
label: string;
|
|
36
|
+
/** @description to hide and show label */
|
|
37
|
+
labelHide: boolean;
|
|
38
|
+
/** @description is control Editable or Disabled */
|
|
39
|
+
disabled: boolean;
|
|
40
|
+
/** @description Is Clear Input Cross button is visible or not */
|
|
41
|
+
clearInput: boolean;
|
|
42
|
+
/** @description Position of Label 'floating' | 'fixed' */
|
|
43
|
+
labelPlacement: labelPlacementType;
|
|
44
|
+
/** @description Lable direction from start of contrl or end of control */
|
|
45
|
+
labelDir: labelDirType;
|
|
46
|
+
/** @description Place holder for control to display if there is no value */
|
|
47
|
+
placeholder: string;
|
|
48
|
+
/** @description it is to set leading icon, at the start of control */
|
|
49
|
+
leadingIcon: string;
|
|
50
|
+
/** @description it is to set trailing icon, at the end of control, for password type control eye is the trailing icon */
|
|
51
|
+
trailingIcon: string;
|
|
52
|
+
/** @description to display below the control for suggestion, if there is any error then error will bw the first to shoe in place of help text */
|
|
53
|
+
helperText: string;
|
|
54
|
+
/** @description default true to collapse when there is no help text or error text, if false then element area in DOM will be reserved never detroy */
|
|
55
|
+
helperTextCollapse: boolean;
|
|
56
|
+
/** @description show and hide helper text its forecfull */
|
|
57
|
+
hideHelperAndErrorText: boolean;
|
|
58
|
+
/** @description if found any error in control the error thext will be used to display error message, if there is help text still error text is having higher priority then helptext */
|
|
59
|
+
errorText: string;
|
|
60
|
+
/** @description maxlength for control */
|
|
61
|
+
maxlength: number;
|
|
62
|
+
/** @description minlength for control */
|
|
63
|
+
minlength: number;
|
|
64
|
+
/** @description is control is required or not input type is true | false */
|
|
65
|
+
required: boolean;
|
|
66
|
+
/** @description Auto capatalization for the value and applicable to word or to complete sentance */
|
|
67
|
+
autocapitalize: autocapitalizeType;
|
|
68
|
+
/** @description auto complete type to help reader what is the type of value */
|
|
69
|
+
autocomplete: autocompleteType;
|
|
70
|
+
/** @description type of control */
|
|
71
|
+
type: controlType;
|
|
72
|
+
/** @description width of control, default width is 100% */
|
|
73
|
+
width: string;
|
|
74
|
+
/** @description uniq id of control, used to differenciat the value also prevent value should not effect another values */
|
|
75
|
+
id: string;
|
|
76
|
+
/** @description to get input value using one way binding like: [ngModel] or by two way binding [(ngModel)] */
|
|
77
|
+
ngModel: inputType;
|
|
78
|
+
option: string[];
|
|
79
|
+
/** @description min value for number type control */
|
|
80
|
+
min: number;
|
|
81
|
+
/** @description max value for number type control */
|
|
82
|
+
max: number;
|
|
83
|
+
/**
|
|
84
|
+
* @description
|
|
85
|
+
* Holds the size of the component like Small, Extra small, Large
|
|
86
|
+
* by Default it takes small size
|
|
87
|
+
* or the size set by the project setup service
|
|
88
|
+
* or it will beset for individual component
|
|
89
|
+
*
|
|
90
|
+
* Size Appled
|
|
91
|
+
* Component level then setup service then finally default md
|
|
92
|
+
* Options: "2xs" | ""xs" | "sm" | "md" | "lg" | "xl" | "xxl"
|
|
93
|
+
*/
|
|
94
|
+
size: themeSize;
|
|
95
|
+
/** @description to set return value using one way binding like: (ngModelChanges) or by two way binding [(ngModel)] */
|
|
96
|
+
ngModelChange: EventEmitter<inputType>;
|
|
97
|
+
/** @description is vale need to read from ngModel or from value(need to implement), it is detected and maild fals on value chnages */
|
|
98
|
+
isNgModel: boolean;
|
|
99
|
+
/** @description this is to set control value is valid or not, set by us inside validate callbck method called by angular */
|
|
100
|
+
isValid: boolean;
|
|
101
|
+
/** @description when control is touched then the will maid true by the us to check it is touched or not, when we will set this true we will call the onTouched callback method of angualr to inform angular that somthis is changed and control is touched */
|
|
102
|
+
isTouched: boolean;
|
|
103
|
+
/** @description we will take type of control in type but is may be not exactly which input's type so we need to get type and set actule type to our input, also when type is set password but in calse view in textt then inuut type need to change to text */
|
|
104
|
+
typeInternal: controlType;
|
|
105
|
+
/** @description if traling is set the it is assigned by it, but some case tarling icon not as it is set need tro be changed at runtime, like password visibility hide and show */
|
|
106
|
+
trailingIconInternal: string;
|
|
107
|
+
isTrailingIconAllwedClick: boolean;
|
|
108
|
+
idRandom: string;
|
|
109
|
+
/**
|
|
110
|
+
* @description Function to call when the HTML Chnage to tell Angular somthing is changed.
|
|
111
|
+
* @field value : inputType
|
|
112
|
+
*/
|
|
113
|
+
private onChange;
|
|
114
|
+
/** @description Function to call when the input is touched (clciked) to tell Angular somthing is changed. */
|
|
115
|
+
onTouched: () => void;
|
|
116
|
+
/** @description Function to call when the input is need to Validate to tell Angular somthing is changed (in case of some input dipendent validation). */
|
|
117
|
+
onValidate: () => void;
|
|
118
|
+
/**
|
|
119
|
+
* @description
|
|
120
|
+
* Method that performs synchronous validation against the provided control.
|
|
121
|
+
* Exicuted by Angular
|
|
122
|
+
*
|
|
123
|
+
* @param control The control to validate against.
|
|
124
|
+
*
|
|
125
|
+
* @returns A map of validation errors if validation fails,
|
|
126
|
+
* otherwise null.
|
|
127
|
+
*/
|
|
128
|
+
validate(control: AbstractControl): ValidationErrors | null;
|
|
129
|
+
/**
|
|
130
|
+
* @description
|
|
131
|
+
* Registers a callback function to call when the validator inputs change.
|
|
132
|
+
* Exicuted by Angular
|
|
133
|
+
*
|
|
134
|
+
* @param fn The callback function
|
|
135
|
+
*/
|
|
136
|
+
registerOnValidatorChange?(fn: () => void): void;
|
|
137
|
+
/** @description when form control change from model side this method is implemented */
|
|
138
|
+
writeValue(value: inputType): void;
|
|
139
|
+
/** @description Allows Angular to register a function to call when the model changes. */
|
|
140
|
+
registerOnChange(fn: (value: inputType) => void): void;
|
|
141
|
+
/** @description Allows Angular to register a function to call when the input has been touched. */
|
|
142
|
+
registerOnTouched(fn: () => void): void;
|
|
143
|
+
/** @description Detect wether input propertires canged or not */
|
|
144
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
145
|
+
ngOnInit(): void;
|
|
146
|
+
/** @description custom method run when HTML changes, we call method registerd by angular to detect change */
|
|
147
|
+
upDateValue(value: {
|
|
148
|
+
target: {
|
|
149
|
+
value: inputType;
|
|
150
|
+
};
|
|
151
|
+
} | Event): void;
|
|
152
|
+
/**
|
|
153
|
+
* @description method applicable in case of control type checkbox
|
|
154
|
+
*
|
|
155
|
+
* @param value boolean | string
|
|
156
|
+
*/
|
|
157
|
+
updateValueCheckBox(value: string | boolean): void;
|
|
158
|
+
/** @description clear the value */
|
|
159
|
+
ClearInputValue(): void;
|
|
160
|
+
/** @description when HTML is focuesd */
|
|
161
|
+
focusControl(): void;
|
|
162
|
+
/** @description If control value need to be processed, like UPPERCASE */
|
|
163
|
+
processValue(value: inputType, type: controlType): inputType;
|
|
164
|
+
/** @description for capitalization */
|
|
165
|
+
autoCapitalizeByOption(value: inputType, type: controlType): inputType;
|
|
166
|
+
/** @description It is used to return the value is valid or not */
|
|
167
|
+
isValidValueAndType(value: inputType, type: controlType): boolean;
|
|
168
|
+
/** @description to check control is valid or not */
|
|
169
|
+
isControlValid(value: inputType): ValidationStatus;
|
|
170
|
+
/** @description Allows Angular to disable the input. */
|
|
171
|
+
setDisabledState(isDisabled: boolean): void;
|
|
172
|
+
/** @description Method for trailing Icon Click */
|
|
173
|
+
trailingIconClick(): void;
|
|
174
|
+
/**
|
|
175
|
+
* Method to generate Random String
|
|
176
|
+
* @param setupPrarameter { lenght: number, prefix: string }
|
|
177
|
+
* default lenght is 10, prefox is ""
|
|
178
|
+
* @returns string
|
|
179
|
+
*/
|
|
180
|
+
randomString(setupPrarameter?: {
|
|
181
|
+
lenght: number;
|
|
182
|
+
prefix: string;
|
|
183
|
+
}): string;
|
|
184
|
+
getControlData(): Promise<void>;
|
|
185
|
+
/**
|
|
186
|
+
* @description use to detact the change in type if changes done this method is ued to run
|
|
187
|
+
*/
|
|
188
|
+
detectTypeChange(): void;
|
|
189
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CideInputComponent, never>;
|
|
190
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<CideInputComponent, "cide-ele-input", never, { "fill": { "alias": "fill"; "required": false; }; "label": { "alias": "label"; "required": false; }; "labelHide": { "alias": "labelHide"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "clearInput": { "alias": "clearInput"; "required": false; }; "labelPlacement": { "alias": "labelPlacement"; "required": false; }; "labelDir": { "alias": "labelDir"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "leadingIcon": { "alias": "leadingIcon"; "required": false; }; "trailingIcon": { "alias": "trailingIcon"; "required": false; }; "helperText": { "alias": "helperText"; "required": false; }; "helperTextCollapse": { "alias": "helperTextCollapse"; "required": false; }; "hideHelperAndErrorText": { "alias": "hideHelperAndErrorText"; "required": false; }; "errorText": { "alias": "errorText"; "required": false; }; "maxlength": { "alias": "maxlength"; "required": false; }; "minlength": { "alias": "minlength"; "required": false; }; "required": { "alias": "required"; "required": false; }; "autocapitalize": { "alias": "autocapitalize"; "required": false; }; "autocomplete": { "alias": "autocomplete"; "required": false; }; "type": { "alias": "type"; "required": false; }; "width": { "alias": "width"; "required": false; }; "id": { "alias": "id"; "required": false; }; "ngModel": { "alias": "ngModel"; "required": false; }; "option": { "alias": "option"; "required": false; }; "min": { "alias": "min"; "required": false; }; "max": { "alias": "max"; "required": false; }; "size": { "alias": "size"; "required": false; }; }, { "ngModelChange": "ngModelChange"; }, never, never, true, never>;
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
type ButtonVariant = 'primary' | 'secondary' | 'outline' | 'text' | 'link' | 'success' | 'danger' | 'warning' | 'info' | 'ghost';
|
|
194
|
+
type ButtonSize = 'xs' | 'sm' | 'md' | 'lg' | 'xl';
|
|
195
|
+
type ButtonType = 'button' | 'submit' | 'reset';
|
|
196
|
+
type ButtonShape = 'default' | 'rounded' | 'pill' | 'square';
|
|
197
|
+
type ButtonElevation = 'none' | 'low' | 'medium' | 'high';
|
|
1
198
|
/**
|
|
2
|
-
*
|
|
199
|
+
* Advanced Angular button component that provides a comprehensive button implementation
|
|
200
|
+
* with loading state, styling variants, animations, tooltips, and other features.
|
|
201
|
+
*
|
|
202
|
+
* This component uses proper Angular templating to avoid hydration issues (NG0500).
|
|
3
203
|
*/
|
|
4
|
-
|
|
5
|
-
|
|
204
|
+
declare class CideEleButtonComponent implements OnInit, OnChanges, OnDestroy {
|
|
205
|
+
private elementService;
|
|
206
|
+
private router;
|
|
207
|
+
private renderer;
|
|
208
|
+
private elementRef;
|
|
209
|
+
private destroy$;
|
|
210
|
+
private clickCount;
|
|
211
|
+
private clickDebouncer$;
|
|
212
|
+
constructor(elementService: CideElementsService, router: Router, renderer: Renderer2, elementRef: ElementRef);
|
|
213
|
+
/**
|
|
214
|
+
* @description Label of button like Submit, Update, Add, etc.
|
|
215
|
+
* Note: it is only used in case you did not set label between tags (via ng-content)
|
|
216
|
+
*/
|
|
217
|
+
label: string;
|
|
218
|
+
/** @description Button style variant */
|
|
219
|
+
variant: ButtonVariant;
|
|
220
|
+
/** @description Button size */
|
|
221
|
+
size: ButtonSize;
|
|
222
|
+
/** @description Button HTML type attribute */
|
|
223
|
+
type: ButtonType;
|
|
224
|
+
/** @description Button shape */
|
|
225
|
+
shape: ButtonShape;
|
|
226
|
+
/** @description Button shadow elevation */
|
|
227
|
+
elevation: ButtonElevation;
|
|
228
|
+
/** @description Button disabled state */
|
|
229
|
+
disabled: boolean | null;
|
|
230
|
+
/** @description Unique ID of control, used to differentiate elements */
|
|
231
|
+
id: string;
|
|
232
|
+
/** @description Enables loading state with spinner */
|
|
233
|
+
loading: boolean;
|
|
234
|
+
/** @description Makes button take full width of container */
|
|
235
|
+
fullWidth: boolean;
|
|
236
|
+
/** @description Icon to display on the left side of the button */
|
|
237
|
+
leftIcon: string;
|
|
238
|
+
/** @description Icon to display on the right side of the button */
|
|
239
|
+
rightIcon: string;
|
|
240
|
+
/** @description Additional CSS classes to apply */
|
|
241
|
+
customClass: string;
|
|
242
|
+
/** @description Tooltip text to display on hover */
|
|
243
|
+
tooltip: string;
|
|
244
|
+
/** @description Aria label for accessibility */
|
|
245
|
+
ariaLabel: string;
|
|
246
|
+
/** @description Test ID for automated testing */
|
|
247
|
+
testId: string;
|
|
248
|
+
/** @description Route to navigate to when clicked (for link buttons) */
|
|
249
|
+
routerLink: string | unknown[];
|
|
250
|
+
/** @description Router navigation extras */
|
|
251
|
+
routerExtras: NavigationExtras;
|
|
252
|
+
/** @description Prevent multiple rapid clicks (debounce) */
|
|
253
|
+
preventDoubleClick: boolean;
|
|
254
|
+
/** @description Animation on click */
|
|
255
|
+
animated: boolean;
|
|
256
|
+
/**
|
|
257
|
+
* @description Click event of button
|
|
258
|
+
*/
|
|
259
|
+
btnClick: EventEmitter<Event>;
|
|
260
|
+
/**
|
|
261
|
+
* @description Double click event
|
|
262
|
+
*/
|
|
263
|
+
doubleClick: EventEmitter<Event>;
|
|
264
|
+
onClick(event: Event): void;
|
|
265
|
+
private handleClick;
|
|
266
|
+
private addClickAnimation;
|
|
267
|
+
ngOnInit(): void;
|
|
268
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
269
|
+
ngOnDestroy(): void;
|
|
270
|
+
getControlData(): Promise<void>;
|
|
271
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CideEleButtonComponent, never>;
|
|
272
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<CideEleButtonComponent, "button[cideEleButton], a[cideEleButton]", never, { "label": { "alias": "label"; "required": false; }; "variant": { "alias": "variant"; "required": false; }; "size": { "alias": "size"; "required": false; }; "type": { "alias": "type"; "required": false; }; "shape": { "alias": "shape"; "required": false; }; "elevation": { "alias": "elevation"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "id": { "alias": "id"; "required": false; }; "loading": { "alias": "loading"; "required": false; }; "fullWidth": { "alias": "fullWidth"; "required": false; }; "leftIcon": { "alias": "leftIcon"; "required": false; }; "rightIcon": { "alias": "rightIcon"; "required": false; }; "customClass": { "alias": "customClass"; "required": false; }; "tooltip": { "alias": "tooltip"; "required": false; }; "ariaLabel": { "alias": "ariaLabel"; "required": false; }; "testId": { "alias": "testId"; "required": false; }; "routerLink": { "alias": "routerLink"; "required": false; }; "routerExtras": { "alias": "routerExtras"; "required": false; }; "preventDoubleClick": { "alias": "preventDoubleClick"; "required": false; }; "animated": { "alias": "animated"; "required": false; }; }, { "btnClick": "btnClick"; "doubleClick": "doubleClick"; }, never, ["*"], true, never>;
|
|
273
|
+
}
|
|
274
|
+
|
|
275
|
+
declare class CideSpinnerComponent {
|
|
276
|
+
/**
|
|
277
|
+
* @description
|
|
278
|
+
* Holds the size of the component like Small, Extra small, Large
|
|
279
|
+
* by Default it takes small size
|
|
280
|
+
* or the size set by the project setup service
|
|
281
|
+
* or it will beset for individual component
|
|
282
|
+
*
|
|
283
|
+
* Size Appled
|
|
284
|
+
* Component level then setup service then finally default md
|
|
285
|
+
* Options: "xs" | "sm" | "md" | "lg" | "xl" | "xxl"
|
|
286
|
+
*/
|
|
287
|
+
size: themeSize;
|
|
288
|
+
type: spinnerType;
|
|
289
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CideSpinnerComponent, never>;
|
|
290
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<CideSpinnerComponent, "cide-ele-spinner", never, { "size": { "alias": "size"; "required": false; }; "type": { "alias": "type"; "required": false; }; }, {}, never, never, true, never>;
|
|
291
|
+
}
|
|
292
|
+
|
|
293
|
+
declare class CideIconComponent {
|
|
294
|
+
size: themeSize;
|
|
295
|
+
type: iconType;
|
|
296
|
+
toolTip: string;
|
|
297
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CideIconComponent, never>;
|
|
298
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<CideIconComponent, "cide-ele-icon", never, { "size": { "alias": "size"; "required": false; }; "type": { "alias": "type"; "required": false; }; "toolTip": { "alias": "toolTip"; "required": false; }; }, {}, never, ["*"], true, never>;
|
|
299
|
+
}
|
|
300
|
+
|
|
301
|
+
interface SelectOption {
|
|
302
|
+
value: string | number;
|
|
303
|
+
label: string;
|
|
304
|
+
disabled?: boolean;
|
|
305
|
+
}
|
|
306
|
+
declare class CideSelectOptionComponent {
|
|
307
|
+
private elementRef;
|
|
308
|
+
value: string | number;
|
|
309
|
+
disabled: boolean;
|
|
310
|
+
get label(): string;
|
|
311
|
+
constructor(elementRef: ElementRef);
|
|
312
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CideSelectOptionComponent, never>;
|
|
313
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<CideSelectOptionComponent, "cide-ele-select-option", never, { "value": { "alias": "value"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; }, {}, never, ["*"], true, never>;
|
|
314
|
+
}
|
|
315
|
+
declare class CideSelectComponent implements ControlValueAccessor, Validator, OnInit, OnChanges, AfterContentInit, OnDestroy {
|
|
316
|
+
private elementRef;
|
|
317
|
+
optionComponents: QueryList<CideSelectOptionComponent>;
|
|
318
|
+
searchInputRef: ElementRef<HTMLInputElement>;
|
|
319
|
+
label: string;
|
|
320
|
+
labelHide: boolean;
|
|
321
|
+
placeholder: string;
|
|
322
|
+
helperText: string;
|
|
323
|
+
errorText: string;
|
|
324
|
+
required: boolean;
|
|
325
|
+
disabled: boolean;
|
|
326
|
+
id: string;
|
|
327
|
+
ngModel: string | number;
|
|
328
|
+
size: themeSize;
|
|
329
|
+
fill: elementStyleType;
|
|
330
|
+
labelPlacement: labelPlacementType;
|
|
331
|
+
labelDir: labelDirType;
|
|
332
|
+
leadingIcon: string;
|
|
333
|
+
trailingIcon: string;
|
|
334
|
+
clearInput: boolean;
|
|
335
|
+
options: SelectOption[];
|
|
336
|
+
multiple: boolean;
|
|
337
|
+
searchable: boolean;
|
|
338
|
+
showSearchInput: boolean;
|
|
339
|
+
loading: boolean;
|
|
340
|
+
ngModelChange: EventEmitter<any>;
|
|
341
|
+
selectionChange: EventEmitter<SelectOption>;
|
|
342
|
+
searchChange: EventEmitter<selectSearchType>;
|
|
343
|
+
isOpen: boolean;
|
|
344
|
+
isTouched: boolean;
|
|
345
|
+
isValid: boolean;
|
|
346
|
+
searchTerm: string;
|
|
347
|
+
filteredOptions: SelectOption[];
|
|
348
|
+
dropdownPosition: 'bottom' | 'top';
|
|
349
|
+
private isDropdownInteraction;
|
|
350
|
+
private debugId;
|
|
351
|
+
private timeoutIds;
|
|
352
|
+
private interactionCount;
|
|
353
|
+
private maxInteractionCount;
|
|
354
|
+
constructor(elementRef: ElementRef);
|
|
355
|
+
onChange: (value: string | number) => void;
|
|
356
|
+
onTouched: () => void;
|
|
357
|
+
onValidate: () => void;
|
|
358
|
+
ngOnInit(): void;
|
|
359
|
+
ngAfterContentInit(): void;
|
|
360
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
361
|
+
writeValue(value: string | number): void;
|
|
362
|
+
registerOnChange(fn: (value: string | number) => void): void;
|
|
363
|
+
registerOnTouched(fn: () => void): void;
|
|
364
|
+
setDisabledState(isDisabled: boolean): void;
|
|
365
|
+
validate(control: AbstractControl): ValidationErrors | null;
|
|
366
|
+
validateValue(value: string | number): ValidationErrors | null;
|
|
367
|
+
toggleDropdown(): void;
|
|
368
|
+
ngOnDestroy(): void;
|
|
369
|
+
private onWindowResize;
|
|
370
|
+
private calculateDropdownPosition;
|
|
371
|
+
selectOption(option: SelectOption): void;
|
|
372
|
+
onBlur(): void;
|
|
373
|
+
focusControl(): void;
|
|
374
|
+
clearSelection(): void;
|
|
375
|
+
getSelectedOptionLabel(): string;
|
|
376
|
+
filterOptions(): void;
|
|
377
|
+
onSearchInput(event: Event): void;
|
|
378
|
+
onDropdownMouseDown(): void;
|
|
379
|
+
onDropdownMouseUp(): void;
|
|
380
|
+
isOptionSelected(option: SelectOption): boolean;
|
|
381
|
+
trackByValue(index: number, option: SelectOption): string | number;
|
|
382
|
+
private logDebug;
|
|
383
|
+
private clearTimeouts;
|
|
384
|
+
private addTimeout;
|
|
385
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CideSelectComponent, never>;
|
|
386
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<CideSelectComponent, "cide-ele-select", never, { "label": { "alias": "label"; "required": false; }; "labelHide": { "alias": "labelHide"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "helperText": { "alias": "helperText"; "required": false; }; "errorText": { "alias": "errorText"; "required": false; }; "required": { "alias": "required"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "id": { "alias": "id"; "required": false; }; "ngModel": { "alias": "ngModel"; "required": false; }; "size": { "alias": "size"; "required": false; }; "fill": { "alias": "fill"; "required": false; }; "labelPlacement": { "alias": "labelPlacement"; "required": false; }; "labelDir": { "alias": "labelDir"; "required": false; }; "leadingIcon": { "alias": "leadingIcon"; "required": false; }; "trailingIcon": { "alias": "trailingIcon"; "required": false; }; "clearInput": { "alias": "clearInput"; "required": false; }; "options": { "alias": "options"; "required": false; }; "multiple": { "alias": "multiple"; "required": false; }; "searchable": { "alias": "searchable"; "required": false; }; "showSearchInput": { "alias": "showSearchInput"; "required": false; }; "loading": { "alias": "loading"; "required": false; }; }, { "ngModelChange": "ngModelChange"; "selectionChange": "change"; "searchChange": "searchChange"; }, ["optionComponents"], never, true, never>;
|
|
387
|
+
}
|
|
388
|
+
|
|
389
|
+
interface TabItem {
|
|
390
|
+
id: string;
|
|
391
|
+
label: string;
|
|
392
|
+
disabled?: boolean;
|
|
393
|
+
icon?: string;
|
|
394
|
+
badge?: string | number;
|
|
395
|
+
}
|
|
396
|
+
declare class CideEleTabComponent implements OnInit {
|
|
397
|
+
tabs: TabItem[];
|
|
398
|
+
activeTabId?: string;
|
|
399
|
+
size: 'sm' | 'md' | 'lg';
|
|
400
|
+
variant: 'default' | 'pills' | 'underline';
|
|
401
|
+
fullWidth: boolean;
|
|
402
|
+
disabled: boolean;
|
|
403
|
+
tabChange: EventEmitter<TabItem>;
|
|
404
|
+
activeTab: i0.WritableSignal<string>;
|
|
405
|
+
ngOnInit(): void;
|
|
406
|
+
onTabClick(tab: TabItem): void;
|
|
407
|
+
isActive(tabId: string): boolean;
|
|
408
|
+
getTabClasses(tab: TabItem): string;
|
|
409
|
+
getContainerClasses(): string;
|
|
410
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CideEleTabComponent, never>;
|
|
411
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<CideEleTabComponent, "cide-ele-tab", never, { "tabs": { "alias": "tabs"; "required": false; }; "activeTabId": { "alias": "activeTabId"; "required": false; }; "size": { "alias": "size"; "required": false; }; "variant": { "alias": "variant"; "required": false; }; "fullWidth": { "alias": "fullWidth"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; }, { "tabChange": "tabChange"; }, never, never, true, never>;
|
|
412
|
+
}
|
|
413
|
+
|
|
414
|
+
declare class CideEleFileInputComponent implements ControlValueAccessor {
|
|
415
|
+
label: string;
|
|
416
|
+
accept: string;
|
|
417
|
+
multiple: boolean;
|
|
418
|
+
disabled: boolean;
|
|
419
|
+
helperText: string;
|
|
420
|
+
errorText: string;
|
|
421
|
+
id: string;
|
|
422
|
+
fileChange: EventEmitter<FileList | null>;
|
|
423
|
+
files: FileList | null;
|
|
424
|
+
fileNames: string[];
|
|
425
|
+
private onChange;
|
|
426
|
+
private onTouched;
|
|
427
|
+
writeValue(files: FileList | null): void;
|
|
428
|
+
registerOnChange(fn: (files: FileList | null) => void): void;
|
|
429
|
+
registerOnTouched(fn: () => void): void;
|
|
430
|
+
setDisabledState(isDisabled: boolean): void;
|
|
431
|
+
onFileSelected(event: Event): void;
|
|
432
|
+
clearFiles(): void;
|
|
433
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CideEleFileInputComponent, never>;
|
|
434
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<CideEleFileInputComponent, "cide-ele-file-input", never, { "label": { "alias": "label"; "required": false; }; "accept": { "alias": "accept"; "required": false; }; "multiple": { "alias": "multiple"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "helperText": { "alias": "helperText"; "required": false; }; "errorText": { "alias": "errorText"; "required": false; }; }, { "fileChange": "fileChange"; }, never, never, true, never>;
|
|
435
|
+
}
|
|
436
|
+
|
|
437
|
+
declare class CideTextareaComponent implements ControlValueAccessor, Validator, OnInit, OnChanges {
|
|
438
|
+
label: string;
|
|
439
|
+
labelHide: boolean;
|
|
440
|
+
placeholder: string;
|
|
441
|
+
helperText: string;
|
|
442
|
+
errorText: string;
|
|
443
|
+
required: boolean;
|
|
444
|
+
disabled: boolean;
|
|
445
|
+
minlength: number;
|
|
446
|
+
maxlength: number;
|
|
447
|
+
rows: number | string;
|
|
448
|
+
id: string;
|
|
449
|
+
ngModel: string;
|
|
450
|
+
size: themeSize;
|
|
451
|
+
fill: elementStyleType;
|
|
452
|
+
labelPlacement: labelPlacementType;
|
|
453
|
+
labelDir: labelDirType;
|
|
454
|
+
leadingIcon: string;
|
|
455
|
+
trailingIcon: string;
|
|
456
|
+
clearInput: boolean;
|
|
457
|
+
trailingIconInternal: string;
|
|
458
|
+
isTrailingIconAllwedClick: boolean;
|
|
459
|
+
ngModelChange: EventEmitter<string>;
|
|
460
|
+
isTouched: boolean;
|
|
461
|
+
isValid: boolean;
|
|
462
|
+
onChange: (value: string) => void;
|
|
463
|
+
onTouched: () => void;
|
|
464
|
+
onValidate: () => void;
|
|
465
|
+
ngOnInit(): void;
|
|
466
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
467
|
+
writeValue(value: string): void;
|
|
468
|
+
registerOnChange(fn: (value: string) => void): void;
|
|
469
|
+
registerOnTouched(fn: () => void): void;
|
|
470
|
+
setDisabledState(isDisabled: boolean): void;
|
|
471
|
+
validate(control: AbstractControl): ValidationErrors | null;
|
|
472
|
+
validateValue(value: string): ValidationErrors | null;
|
|
473
|
+
onInput(event: Event): void;
|
|
474
|
+
onBlur(): void;
|
|
475
|
+
ClearInputValue(): void;
|
|
476
|
+
trailingIconClick(): void;
|
|
477
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CideTextareaComponent, never>;
|
|
478
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<CideTextareaComponent, "cide-ele-textarea", never, { "label": { "alias": "label"; "required": false; }; "labelHide": { "alias": "labelHide"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "helperText": { "alias": "helperText"; "required": false; }; "errorText": { "alias": "errorText"; "required": false; }; "required": { "alias": "required"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "minlength": { "alias": "minlength"; "required": false; }; "maxlength": { "alias": "maxlength"; "required": false; }; "rows": { "alias": "rows"; "required": false; }; "id": { "alias": "id"; "required": false; }; "ngModel": { "alias": "ngModel"; "required": false; }; "size": { "alias": "size"; "required": false; }; "fill": { "alias": "fill"; "required": false; }; "labelPlacement": { "alias": "labelPlacement"; "required": false; }; "labelDir": { "alias": "labelDir"; "required": false; }; "leadingIcon": { "alias": "leadingIcon"; "required": false; }; "trailingIcon": { "alias": "trailingIcon"; "required": false; }; "clearInput": { "alias": "clearInput"; "required": false; }; }, { "ngModelChange": "ngModelChange"; }, never, never, true, never>;
|
|
479
|
+
}
|
|
480
|
+
|
|
481
|
+
declare class CideElementsService {
|
|
482
|
+
cide_element_data: {
|
|
483
|
+
[key: string]: ICoreSype;
|
|
484
|
+
};
|
|
485
|
+
is_cide_element_data_updated: BehaviorSubject<boolean>;
|
|
486
|
+
getElementData(body: GetElementDataRequest): Promise<ICoreSype>;
|
|
487
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CideElementsService, never>;
|
|
488
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<CideElementsService>;
|
|
489
|
+
}
|
|
490
|
+
|
|
491
|
+
type CideEleResizerDirection = 'horizontal' | 'vertical';
|
|
492
|
+
type CideEleResizerDirectionTo = "right-to-left" | "left-to-right" | "";
|
|
493
|
+
declare class CideEleResizerDirective implements OnInit {
|
|
494
|
+
private el;
|
|
495
|
+
private renderer;
|
|
496
|
+
direction: CideEleResizerDirection;
|
|
497
|
+
to: CideEleResizerDirectionTo;
|
|
498
|
+
prevElementSelector: string;
|
|
499
|
+
nextElementSelector: string;
|
|
500
|
+
parentElementSelector: string;
|
|
501
|
+
minPrevSize: number;
|
|
502
|
+
minNextSize: number;
|
|
503
|
+
usePercentage: boolean;
|
|
504
|
+
resizeStart: EventEmitter<void>;
|
|
505
|
+
resizing: EventEmitter<{
|
|
506
|
+
prevSize: number;
|
|
507
|
+
nextSize: number;
|
|
508
|
+
}>;
|
|
509
|
+
resizeEnd: EventEmitter<{
|
|
510
|
+
prevSize: number;
|
|
511
|
+
nextSize: number;
|
|
512
|
+
}>;
|
|
513
|
+
private isResizing;
|
|
514
|
+
private startPosition;
|
|
515
|
+
private prevElement;
|
|
516
|
+
private nextElement;
|
|
517
|
+
private prevSize;
|
|
518
|
+
private nextSize;
|
|
519
|
+
private containerSize;
|
|
520
|
+
private startPrevSize;
|
|
521
|
+
private startNextSize;
|
|
522
|
+
constructor(el: ElementRef, renderer: Renderer2);
|
|
523
|
+
ngOnInit(): void;
|
|
524
|
+
onMouseDown(event: MouseEvent): void;
|
|
525
|
+
private onMouseMove;
|
|
526
|
+
private onMouseUp;
|
|
527
|
+
private getPrevElement;
|
|
528
|
+
private getNextElement;
|
|
529
|
+
private getSizeProperty;
|
|
530
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CideEleResizerDirective, never>;
|
|
531
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<CideEleResizerDirective, "[cideEleResizer]", never, { "direction": { "alias": "direction"; "required": false; }; "to": { "alias": "to"; "required": false; }; "prevElementSelector": { "alias": "prevElementSelector"; "required": false; }; "nextElementSelector": { "alias": "nextElementSelector"; "required": false; }; "parentElementSelector": { "alias": "parentElementSelector"; "required": false; }; "minPrevSize": { "alias": "minPrevSize"; "required": false; }; "minNextSize": { "alias": "minNextSize"; "required": false; }; "usePercentage": { "alias": "usePercentage"; "required": false; }; }, { "resizeStart": "resizeStart"; "resizing": "resizing"; "resizeEnd": "resizeEnd"; }, never, never, true, never>;
|
|
532
|
+
}
|
|
533
|
+
|
|
534
|
+
type TooltipPlacement = 'top' | 'bottom' | 'left' | 'right';
|
|
535
|
+
type TooltipType = 'default' | 'success' | 'warning' | 'error' | 'info' | 'light' | 'dark';
|
|
536
|
+
declare class TooltipDirective implements OnInit, OnDestroy {
|
|
537
|
+
private el;
|
|
538
|
+
private renderer;
|
|
539
|
+
cideEleTooltip: string;
|
|
540
|
+
tooltipColor: string;
|
|
541
|
+
tooltipBg: string;
|
|
542
|
+
tooltipPlacement: TooltipPlacement;
|
|
543
|
+
tooltipType: TooltipType;
|
|
544
|
+
tooltipDelay: number;
|
|
545
|
+
tooltipDir: TooltipPlacement;
|
|
546
|
+
tooltipShowArrow: boolean;
|
|
547
|
+
tooltipMultiline: boolean;
|
|
548
|
+
tooltipMaxWidth: string;
|
|
549
|
+
tooltipInteractive: boolean;
|
|
550
|
+
tooltipClass: string;
|
|
551
|
+
private tooltipElement;
|
|
552
|
+
private visible;
|
|
553
|
+
private showTimeout;
|
|
554
|
+
private hideTimeout;
|
|
555
|
+
private hideDelay;
|
|
556
|
+
private interactiveMouseLeaveHandler;
|
|
557
|
+
constructor(el: ElementRef, renderer: Renderer2);
|
|
558
|
+
ngOnInit(): void;
|
|
559
|
+
onMouseEnter(): void;
|
|
560
|
+
onFocus(): void;
|
|
561
|
+
onMouseLeave(): void;
|
|
562
|
+
onBlur(): void;
|
|
563
|
+
onClick(): void;
|
|
564
|
+
ngOnDestroy(): void;
|
|
565
|
+
private clearTimeouts;
|
|
566
|
+
private show;
|
|
567
|
+
private hide;
|
|
568
|
+
private createTooltip;
|
|
569
|
+
private styleTooltip;
|
|
570
|
+
private positionTooltip;
|
|
571
|
+
private destroyTooltip;
|
|
572
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<TooltipDirective, never>;
|
|
573
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<TooltipDirective, "[cideEleTooltip]", never, { "cideEleTooltip": { "alias": "cideEleTooltip"; "required": false; }; "tooltipColor": { "alias": "tooltipColor"; "required": false; }; "tooltipBg": { "alias": "tooltipBg"; "required": false; }; "tooltipPlacement": { "alias": "tooltipPlacement"; "required": false; }; "tooltipType": { "alias": "tooltipType"; "required": false; }; "tooltipDelay": { "alias": "tooltipDelay"; "required": false; }; "tooltipDir": { "alias": "tooltipDir"; "required": false; }; "tooltipShowArrow": { "alias": "tooltipShowArrow"; "required": false; }; "tooltipMultiline": { "alias": "tooltipMultiline"; "required": false; }; "tooltipMaxWidth": { "alias": "tooltipMaxWidth"; "required": false; }; "tooltipInteractive": { "alias": "tooltipInteractive"; "required": false; }; "tooltipClass": { "alias": "tooltipClass"; "required": false; }; }, {}, never, never, true, never>;
|
|
574
|
+
}
|
|
575
|
+
|
|
576
|
+
declare class CideEleSkeletonLoaderComponent {
|
|
577
|
+
width: string;
|
|
578
|
+
height: string;
|
|
579
|
+
borderRadius: string;
|
|
580
|
+
count: number;
|
|
581
|
+
circle: boolean;
|
|
582
|
+
animation: 'pulse' | 'wave' | 'none';
|
|
583
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CideEleSkeletonLoaderComponent, never>;
|
|
584
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<CideEleSkeletonLoaderComponent, "cide-ele-skeleton-loader", never, { "width": { "alias": "width"; "required": false; }; "height": { "alias": "height"; "required": false; }; "borderRadius": { "alias": "borderRadius"; "required": false; }; "count": { "alias": "count"; "required": false; }; "circle": { "alias": "circle"; "required": false; }; "animation": { "alias": "animation"; "required": false; }; }, {}, never, never, true, never>;
|
|
585
|
+
}
|
|
586
|
+
|
|
587
|
+
type ColumnType = 'text' | 'number' | 'date' | 'boolean' | 'status' | 'actions' | 'custom' | 'order';
|
|
588
|
+
type ColumnWidth = 'xs' | 'sm' | 'md' | 'lg' | 'xl' | 'auto' | string;
|
|
589
|
+
type TextAlign = 'left' | 'center' | 'right';
|
|
590
|
+
interface GridColumn {
|
|
591
|
+
key: string;
|
|
592
|
+
header: string;
|
|
593
|
+
type: ColumnType;
|
|
594
|
+
width?: ColumnWidth;
|
|
595
|
+
sortable?: boolean;
|
|
596
|
+
searchable?: boolean;
|
|
597
|
+
truncate?: boolean;
|
|
598
|
+
align?: TextAlign;
|
|
599
|
+
renderer?: string;
|
|
600
|
+
valueGetter?: string;
|
|
601
|
+
formatter?: GridFormatter;
|
|
602
|
+
actions?: GridAction[];
|
|
603
|
+
statusConfig?: StatusConfig;
|
|
604
|
+
}
|
|
605
|
+
interface GridFormatter {
|
|
606
|
+
type: 'date' | 'currency' | 'percentage' | 'custom';
|
|
607
|
+
format?: string;
|
|
608
|
+
customFunction?: string;
|
|
609
|
+
}
|
|
610
|
+
interface StatusConfig {
|
|
611
|
+
activeValue: string | number | boolean;
|
|
612
|
+
activeLabel: string;
|
|
613
|
+
inactiveLabel: string;
|
|
614
|
+
activeClass: string;
|
|
615
|
+
inactiveClass: string;
|
|
616
|
+
}
|
|
617
|
+
interface GridAction {
|
|
618
|
+
key: string;
|
|
619
|
+
label: string;
|
|
620
|
+
icon: string;
|
|
621
|
+
variant: 'ghost' | 'primary' | 'outline' | 'danger';
|
|
622
|
+
tooltip?: string;
|
|
623
|
+
condition?: string;
|
|
624
|
+
onClick: string;
|
|
625
|
+
}
|
|
626
|
+
interface GridPaginationConfig {
|
|
627
|
+
enabled: boolean;
|
|
628
|
+
pageSize: number;
|
|
629
|
+
pageSizeOptions: number[];
|
|
630
|
+
showQuickJump: boolean;
|
|
631
|
+
showPageInfo: boolean;
|
|
632
|
+
showRefresh: boolean;
|
|
633
|
+
}
|
|
634
|
+
interface GridSearchConfig {
|
|
635
|
+
enabled: boolean;
|
|
636
|
+
placeholder: string;
|
|
637
|
+
searchableColumns: string[];
|
|
638
|
+
debounceMs?: number;
|
|
639
|
+
}
|
|
640
|
+
interface GridExportConfig {
|
|
641
|
+
enabled: boolean;
|
|
642
|
+
formats: ('csv' | 'excel' | 'pdf')[];
|
|
643
|
+
filename?: string;
|
|
644
|
+
}
|
|
645
|
+
interface GridLoadingConfig {
|
|
646
|
+
useDefer: boolean;
|
|
647
|
+
skeletonRows: number;
|
|
648
|
+
showOverlay: boolean;
|
|
649
|
+
}
|
|
650
|
+
interface GridScrollConfig {
|
|
651
|
+
enabled: boolean;
|
|
652
|
+
maxHeight?: string;
|
|
653
|
+
minHeight?: string;
|
|
654
|
+
stickyHeader?: boolean;
|
|
655
|
+
virtualScroll?: boolean;
|
|
656
|
+
rowHeight?: number;
|
|
657
|
+
}
|
|
658
|
+
interface GridTreeConfig {
|
|
659
|
+
enabled: boolean;
|
|
660
|
+
primaryKey: string;
|
|
661
|
+
foreignKey: string;
|
|
662
|
+
childrenKey?: string;
|
|
663
|
+
levelKey?: string;
|
|
664
|
+
expandedKey?: string;
|
|
665
|
+
hasChildrenKey?: string;
|
|
666
|
+
}
|
|
667
|
+
interface GridDragDropConfig {
|
|
668
|
+
enabled: boolean;
|
|
669
|
+
dragHandle?: string;
|
|
670
|
+
orderField?: string;
|
|
671
|
+
dragClass?: string;
|
|
672
|
+
dropClass?: string;
|
|
673
|
+
}
|
|
674
|
+
interface GridConfiguration<T = Record<string, unknown>> {
|
|
675
|
+
id: string;
|
|
676
|
+
title?: string;
|
|
677
|
+
subtitle?: string;
|
|
678
|
+
columns: GridColumn[];
|
|
679
|
+
data: T[];
|
|
680
|
+
trackBy?: string;
|
|
681
|
+
pagination: GridPaginationConfig;
|
|
682
|
+
search: GridSearchConfig;
|
|
683
|
+
export?: GridExportConfig;
|
|
684
|
+
loading: GridLoadingConfig;
|
|
685
|
+
scroll?: GridScrollConfig;
|
|
686
|
+
tree?: GridTreeConfig;
|
|
687
|
+
dragDrop?: GridDragDropConfig;
|
|
688
|
+
responsive: boolean;
|
|
689
|
+
striped?: boolean;
|
|
690
|
+
bordered?: boolean;
|
|
691
|
+
compact?: boolean;
|
|
692
|
+
fullHeight?: boolean;
|
|
693
|
+
onRowClick?: string;
|
|
694
|
+
onSort?: string;
|
|
695
|
+
onPageChange?: string;
|
|
696
|
+
onSearch?: string;
|
|
697
|
+
onRefresh?: string;
|
|
698
|
+
onExport?: string;
|
|
699
|
+
onRowReorder?: string;
|
|
700
|
+
tableClass?: string;
|
|
701
|
+
headerClass?: string;
|
|
702
|
+
rowClass?: string;
|
|
703
|
+
cellClass?: string;
|
|
704
|
+
}
|
|
705
|
+
interface GridState<T = Record<string, unknown>> {
|
|
706
|
+
currentPage: number;
|
|
707
|
+
pageSize: number;
|
|
708
|
+
totalItems: number;
|
|
709
|
+
totalPages: number;
|
|
710
|
+
searchQuery: string;
|
|
711
|
+
sortColumn?: string;
|
|
712
|
+
sortDirection?: 'asc' | 'desc';
|
|
713
|
+
loading: boolean;
|
|
714
|
+
isRefreshing: boolean;
|
|
715
|
+
selectedRows: T[];
|
|
716
|
+
}
|
|
717
|
+
interface GridEvent<T = Record<string, unknown>> {
|
|
718
|
+
type: 'rowClick' | 'sort' | 'pageChange' | 'search' | 'refresh' | 'export' | 'action' | 'rowReorder';
|
|
719
|
+
data: T | T[] | string | number | null | {
|
|
720
|
+
sourceItem: T;
|
|
721
|
+
sourceIndex: number;
|
|
722
|
+
targetItem: T;
|
|
723
|
+
targetIndex: number;
|
|
724
|
+
newOrder: T[];
|
|
725
|
+
};
|
|
726
|
+
column?: GridColumn;
|
|
727
|
+
action?: GridAction;
|
|
728
|
+
}
|
|
729
|
+
declare const DEFAULT_GRID_CONFIG: Partial<GridConfiguration>;
|
|
730
|
+
type GridEventHandler<T = Record<string, unknown>> = (event: GridEvent<T>) => void;
|
|
731
|
+
type GridCustomRenderer<T = Record<string, unknown>> = (value: unknown, row: T, column: GridColumn) => string;
|
|
732
|
+
type GridCustomFormatter = (value: unknown, format?: string) => string;
|
|
733
|
+
|
|
734
|
+
interface TemplateContext<T = Record<string, unknown>> {
|
|
735
|
+
$implicit: unknown;
|
|
736
|
+
row: T;
|
|
737
|
+
value: unknown;
|
|
738
|
+
column: GridColumn;
|
|
739
|
+
}
|
|
740
|
+
type TemplateRenderer<T = Record<string, unknown>> = TemplateRef<TemplateContext<T>>;
|
|
741
|
+
type StringRenderer<T = Record<string, unknown>> = (value: unknown, row: T) => string;
|
|
742
|
+
type Renderer<T = Record<string, unknown>> = StringRenderer<T> | TemplateRenderer<T>;
|
|
743
|
+
declare class CideEleDataGridComponent<T = Record<string, unknown>> implements OnInit, OnChanges, OnDestroy {
|
|
744
|
+
config: GridConfiguration<T>;
|
|
745
|
+
customRenderers: Record<string, StringRenderer<T>>;
|
|
746
|
+
templateRenderers: Record<string, unknown>;
|
|
747
|
+
customFormatters: Record<string, (value: unknown, format?: string) => string>;
|
|
748
|
+
actionHandlers: Record<string, (data: T, action?: GridAction) => void>;
|
|
749
|
+
serverSidePagination: boolean;
|
|
750
|
+
totalServerItems: number;
|
|
751
|
+
currentServerPage: number;
|
|
752
|
+
currentServerPageSize: number;
|
|
753
|
+
dragDropEnabled: boolean;
|
|
754
|
+
gridEvent: EventEmitter<GridEvent<T>>;
|
|
755
|
+
private internalData;
|
|
756
|
+
private filteredData;
|
|
757
|
+
currentPage: i0.WritableSignal<number>;
|
|
758
|
+
pageSize: i0.WritableSignal<number>;
|
|
759
|
+
totalItems: i0.WritableSignal<number>;
|
|
760
|
+
totalPages: i0.WritableSignal<number>;
|
|
761
|
+
searchQuery: i0.WritableSignal<string>;
|
|
762
|
+
loading: i0.WritableSignal<boolean>;
|
|
763
|
+
isRefreshing: i0.WritableSignal<boolean>;
|
|
764
|
+
pageChangeLoading: i0.WritableSignal<boolean>;
|
|
765
|
+
jumpToPage: number;
|
|
766
|
+
isDragOverRow: number | null;
|
|
767
|
+
isDragging: i0.WritableSignal<boolean>;
|
|
768
|
+
hasOrderChanged: i0.WritableSignal<boolean>;
|
|
769
|
+
private originalOrderIds;
|
|
770
|
+
private initialDataOrderIds;
|
|
771
|
+
private rowOrderMap;
|
|
772
|
+
private localReorderedData;
|
|
773
|
+
private searchDebounceTimer?;
|
|
774
|
+
private isDataUpdate;
|
|
775
|
+
hasNextPage: i0.Signal<boolean>;
|
|
776
|
+
hasPreviousPage: i0.Signal<boolean>;
|
|
777
|
+
mergedConfig: i0.WritableSignal<GridConfiguration<T>>;
|
|
778
|
+
ngOnInit(): void;
|
|
779
|
+
ngOnDestroy(): void;
|
|
780
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
781
|
+
/**
|
|
782
|
+
* Check if the config change is only a data update
|
|
783
|
+
*/
|
|
784
|
+
private isDataOnlyUpdate;
|
|
785
|
+
/**
|
|
786
|
+
* Update only the data without triggering full grid re-initialization
|
|
787
|
+
* This prevents the search input and other UI state from being reset
|
|
788
|
+
*/
|
|
789
|
+
private updateDataOnly;
|
|
790
|
+
private mergeConfigWithDefaults;
|
|
791
|
+
private initializeGrid;
|
|
792
|
+
/**
|
|
793
|
+
* Get the unique identifier for an item
|
|
794
|
+
*/
|
|
795
|
+
private getItemId;
|
|
796
|
+
/**
|
|
797
|
+
* Get the order value for an item from the config
|
|
798
|
+
*/
|
|
799
|
+
private getItemOrder;
|
|
800
|
+
/**
|
|
801
|
+
* Initialize the original order for drag and drop
|
|
802
|
+
*/
|
|
803
|
+
private initializeOriginalOrder;
|
|
804
|
+
/**
|
|
805
|
+
* Refresh order tracking with current data (called when data updates)
|
|
806
|
+
*/
|
|
807
|
+
private refreshOrderTracking;
|
|
808
|
+
private applyFilters;
|
|
809
|
+
/**
|
|
810
|
+
* Transform flat data to tree structure based on foreign key relationships
|
|
811
|
+
*/
|
|
812
|
+
private transformToTree;
|
|
813
|
+
/**
|
|
814
|
+
* Recursively calculate item level in hierarchy for unlimited depth support
|
|
815
|
+
*/
|
|
816
|
+
private calculateItemLevel;
|
|
817
|
+
/**
|
|
818
|
+
* Flatten tree structure for display, respecting expansion state with unlimited nesting
|
|
819
|
+
*/
|
|
820
|
+
private flattenTreeForDisplay;
|
|
821
|
+
/**
|
|
822
|
+
* Toggle expand/collapse state of a tree item with unlimited nesting support
|
|
823
|
+
*/
|
|
824
|
+
private toggleTreeExpand;
|
|
825
|
+
private updatePaginationState;
|
|
826
|
+
onPageChange(page: number | string): void;
|
|
827
|
+
onPageSizeChange(): void;
|
|
828
|
+
updatePageSize(value: string | number): void;
|
|
829
|
+
previousPage(): void;
|
|
830
|
+
nextPage(): void;
|
|
831
|
+
onJumpToPage(): void;
|
|
832
|
+
getEnhancedPageNumbers(): (number | string)[];
|
|
833
|
+
updateSearchQuery(value: inputType): void;
|
|
834
|
+
onSearch(): void;
|
|
835
|
+
onRefresh(): void;
|
|
836
|
+
setRefreshing(isRefreshing: boolean): void;
|
|
837
|
+
clearPageChangeLoading(): void;
|
|
838
|
+
/**
|
|
839
|
+
* Check if tree view is enabled
|
|
840
|
+
*/
|
|
841
|
+
isTreeEnabled(): boolean;
|
|
842
|
+
/**
|
|
843
|
+
* Get tree configuration
|
|
844
|
+
*/
|
|
845
|
+
getTreeConfig(): cloud_ide_element.GridTreeConfig | undefined;
|
|
846
|
+
/**
|
|
847
|
+
* Check if an item has children
|
|
848
|
+
*/
|
|
849
|
+
hasChildren(item: T): boolean;
|
|
850
|
+
/**
|
|
851
|
+
* Get item level in tree
|
|
852
|
+
*/
|
|
853
|
+
getItemLevel(item: T): number;
|
|
854
|
+
/**
|
|
855
|
+
* Check if item is expanded
|
|
856
|
+
*/
|
|
857
|
+
isItemExpanded(item: T): boolean;
|
|
858
|
+
/**
|
|
859
|
+
* Get tree indent style
|
|
860
|
+
*/
|
|
861
|
+
getTreeIndentStyle(item: T): string;
|
|
862
|
+
/**
|
|
863
|
+
* Get tree level background class for visual distinction
|
|
864
|
+
*/
|
|
865
|
+
getTreeLevelClass(item: T): string;
|
|
866
|
+
/**
|
|
867
|
+
* Check if drag and drop is enabled
|
|
868
|
+
*/
|
|
869
|
+
isDragDropEnabled(): boolean;
|
|
870
|
+
/**
|
|
871
|
+
* Get drag and drop configuration
|
|
872
|
+
*/
|
|
873
|
+
getDragDropConfig(): cloud_ide_element.GridDragDropConfig | undefined;
|
|
874
|
+
/**
|
|
875
|
+
* Handle drag start event
|
|
876
|
+
*/
|
|
877
|
+
onDragStart(event: DragEvent, item: T, index: number): void;
|
|
878
|
+
/**
|
|
879
|
+
* Handle drag over event
|
|
880
|
+
*/
|
|
881
|
+
onDragOver(event: DragEvent): void;
|
|
882
|
+
/**
|
|
883
|
+
* Handle drag leave event
|
|
884
|
+
*/
|
|
885
|
+
onDragLeave(event: DragEvent): void;
|
|
886
|
+
/**
|
|
887
|
+
* Handle drop event
|
|
888
|
+
*/
|
|
889
|
+
onDrop(event: DragEvent, targetItem: T, targetIndex: number): void;
|
|
890
|
+
/**
|
|
891
|
+
* Handle drag end event
|
|
892
|
+
*/
|
|
893
|
+
onDragEnd(event: DragEvent): void;
|
|
894
|
+
/**
|
|
895
|
+
* Calculate new order after reordering
|
|
896
|
+
*/
|
|
897
|
+
private getNewOrder;
|
|
898
|
+
/**
|
|
899
|
+
* Get the current order number for a specific item
|
|
900
|
+
*/
|
|
901
|
+
getCurrentOrderNumber(item: T): number;
|
|
902
|
+
/**
|
|
903
|
+
* Update the row order map with new positions after reordering
|
|
904
|
+
*/
|
|
905
|
+
private updateRowOrderMap;
|
|
906
|
+
/**
|
|
907
|
+
* Check if any row has changed position by comparing old vs new positions
|
|
908
|
+
*/
|
|
909
|
+
private checkIfOrderChanged;
|
|
910
|
+
/**
|
|
911
|
+
* Reset the row order map to original positions (for reset action)
|
|
912
|
+
*/
|
|
913
|
+
private resetRowOrderMap;
|
|
914
|
+
/**
|
|
915
|
+
* Update the row order map baseline to current positions (for save action)
|
|
916
|
+
*/
|
|
917
|
+
private updateRowOrderMapBaseline;
|
|
918
|
+
/**
|
|
919
|
+
* Get the current order array from the row order map
|
|
920
|
+
*/
|
|
921
|
+
private getCurrentOrderFromMap;
|
|
922
|
+
/**
|
|
923
|
+
* Update local data order for visual reordering (LOCAL ONLY)
|
|
924
|
+
*/
|
|
925
|
+
private updateLocalDataOrder;
|
|
926
|
+
/**
|
|
927
|
+
* Check if the current order has changed from the initial order
|
|
928
|
+
*/
|
|
929
|
+
private checkOrderChanged;
|
|
930
|
+
onRowClick(item: T): void;
|
|
931
|
+
onActionClick(item: T, action: GridAction): void;
|
|
932
|
+
private emitEvent;
|
|
933
|
+
/**
|
|
934
|
+
* Get nested value from an object
|
|
935
|
+
* @param obj - The object to get the nested value from
|
|
936
|
+
* @param path - The path to the nested value (e.g., 'contact.email')
|
|
937
|
+
* @returns The nested value or undefined if not found
|
|
938
|
+
* @example
|
|
939
|
+
* const obj = { contact: { email: 'test@example.com' } };
|
|
940
|
+
* const value = getNestedValue(obj, 'contact.email');
|
|
941
|
+
* // value === 'test@example.com'
|
|
942
|
+
*/
|
|
943
|
+
getNestedValue(obj: T, path: string): unknown;
|
|
944
|
+
formatValue(value: unknown, column: GridColumn): string;
|
|
945
|
+
private formatDate;
|
|
946
|
+
private formatCurrency;
|
|
947
|
+
private formatPercentage;
|
|
948
|
+
renderCustomCell(value: unknown, row: T, column: GridColumn): string;
|
|
949
|
+
isTemplateRenderer(rendererKey: string): boolean;
|
|
950
|
+
isStringRenderer(rendererKey: string): boolean;
|
|
951
|
+
getTemplateRenderer(rendererKey: string): TemplateRenderer<T> | null;
|
|
952
|
+
getStringRenderer(rendererKey: string): StringRenderer<T> | null;
|
|
953
|
+
getTemplateContext(value: unknown, row: T, column: GridColumn): TemplateContext<T>;
|
|
954
|
+
getColumnWidthClass(width?: ColumnWidth): string;
|
|
955
|
+
getColumnMaxWidthClass(width?: ColumnWidth): string;
|
|
956
|
+
getStatusClass(value: unknown, statusConfig?: StatusConfig): string;
|
|
957
|
+
getStatusText(value: unknown, statusConfig?: StatusConfig): string;
|
|
958
|
+
getItemRangeText(): string;
|
|
959
|
+
getPageSizeOptions(): {
|
|
960
|
+
value: number;
|
|
961
|
+
label: string;
|
|
962
|
+
}[];
|
|
963
|
+
trackByFn(index: number, item: T): unknown;
|
|
964
|
+
getSkeletonArray(): number[];
|
|
965
|
+
get displayedData(): T[];
|
|
966
|
+
get columns(): GridColumn[];
|
|
967
|
+
get paginationConfig(): cloud_ide_element.GridPaginationConfig;
|
|
968
|
+
get searchConfig(): cloud_ide_element.GridSearchConfig;
|
|
969
|
+
get loadingConfig(): cloud_ide_element.GridLoadingConfig;
|
|
970
|
+
get scrollConfig(): cloud_ide_element.GridScrollConfig | undefined;
|
|
971
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CideEleDataGridComponent<any>, never>;
|
|
972
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<CideEleDataGridComponent<any>, "cide-ele-data-grid", never, { "config": { "alias": "config"; "required": false; }; "customRenderers": { "alias": "customRenderers"; "required": false; }; "templateRenderers": { "alias": "templateRenderers"; "required": false; }; "customFormatters": { "alias": "customFormatters"; "required": false; }; "actionHandlers": { "alias": "actionHandlers"; "required": false; }; "serverSidePagination": { "alias": "serverSidePagination"; "required": false; }; "totalServerItems": { "alias": "totalServerItems"; "required": false; }; "currentServerPage": { "alias": "currentServerPage"; "required": false; }; "currentServerPageSize": { "alias": "currentServerPageSize"; "required": false; }; "dragDropEnabled": { "alias": "dragDropEnabled"; "required": false; }; }, { "gridEvent": "gridEvent"; }, never, never, true, never>;
|
|
973
|
+
}
|
|
974
|
+
|
|
975
|
+
interface DropdownItem {
|
|
976
|
+
id: string;
|
|
977
|
+
label: string;
|
|
978
|
+
icon?: string;
|
|
979
|
+
iconColor?: string;
|
|
980
|
+
textColor?: string;
|
|
981
|
+
hoverBgColor?: string;
|
|
982
|
+
disabled?: boolean;
|
|
983
|
+
divider?: boolean;
|
|
984
|
+
}
|
|
985
|
+
interface DropdownConfig {
|
|
986
|
+
triggerIcon?: string;
|
|
987
|
+
triggerSize?: 'xs' | 'sm' | 'md' | 'lg';
|
|
988
|
+
triggerColor?: string;
|
|
989
|
+
triggerHoverColor?: string;
|
|
990
|
+
triggerHoverBgColor?: string;
|
|
991
|
+
menuWidth?: string;
|
|
992
|
+
menuPosition?: 'left' | 'right' | 'auto';
|
|
993
|
+
showArrow?: boolean;
|
|
994
|
+
forcePosition?: 'top' | 'bottom' | 'left' | 'right';
|
|
995
|
+
offsetX?: number;
|
|
996
|
+
offsetY?: number;
|
|
997
|
+
}
|
|
998
|
+
interface DropdownPosition {
|
|
999
|
+
vertical: 'top' | 'bottom';
|
|
1000
|
+
horizontal: 'left' | 'right';
|
|
1001
|
+
spaceAvailable: {
|
|
1002
|
+
top: number;
|
|
1003
|
+
bottom: number;
|
|
1004
|
+
left: number;
|
|
1005
|
+
right: number;
|
|
1006
|
+
};
|
|
1007
|
+
}
|
|
1008
|
+
declare class CideEleDropdownComponent implements OnInit, OnDestroy {
|
|
1009
|
+
private destroyRef;
|
|
1010
|
+
private dropdownManager;
|
|
1011
|
+
private dropdownId;
|
|
1012
|
+
dropdownContainer: i0.Signal<ElementRef<any>>;
|
|
1013
|
+
dropdownMenu: i0.Signal<ElementRef<any> | undefined>;
|
|
1014
|
+
set items(value: DropdownItem[]);
|
|
1015
|
+
get items(): DropdownItem[];
|
|
1016
|
+
private _items;
|
|
1017
|
+
config: DropdownConfig;
|
|
1018
|
+
triggerTemplate?: TemplateRef<{
|
|
1019
|
+
$implicit: boolean;
|
|
1020
|
+
}>;
|
|
1021
|
+
menuTemplate?: TemplateRef<{
|
|
1022
|
+
$implicit: DropdownItem[];
|
|
1023
|
+
}>;
|
|
1024
|
+
itemClick: EventEmitter<DropdownItem>;
|
|
1025
|
+
dropdownToggle: EventEmitter<boolean>;
|
|
1026
|
+
isOpen: i0.WritableSignal<boolean>;
|
|
1027
|
+
currentPosition: i0.WritableSignal<DropdownPosition>;
|
|
1028
|
+
ngOnInit(): void;
|
|
1029
|
+
ngOnDestroy(): void;
|
|
1030
|
+
getTriggerClasses(): string;
|
|
1031
|
+
getTriggerIconClasses(): string;
|
|
1032
|
+
getMenuClasses(): string;
|
|
1033
|
+
getMenuStyles(): string;
|
|
1034
|
+
calculatePosition(): DropdownPosition;
|
|
1035
|
+
private getMenuWidth;
|
|
1036
|
+
private getEstimatedMenuHeight;
|
|
1037
|
+
toggleDropdown(event: Event): void;
|
|
1038
|
+
private openDropdown;
|
|
1039
|
+
testMouseDown(item: DropdownItem): void;
|
|
1040
|
+
onItemClick(item: DropdownItem, event: Event): void;
|
|
1041
|
+
closeDropdown(): void;
|
|
1042
|
+
getItemClasses(item: DropdownItem): string;
|
|
1043
|
+
onWindowResize(): void;
|
|
1044
|
+
onWindowScroll(): void;
|
|
1045
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CideEleDropdownComponent, never>;
|
|
1046
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<CideEleDropdownComponent, "cide-ele-dropdown", never, { "items": { "alias": "items"; "required": false; }; "config": { "alias": "config"; "required": false; }; "triggerTemplate": { "alias": "triggerTemplate"; "required": false; }; "menuTemplate": { "alias": "menuTemplate"; "required": false; }; }, { "itemClick": "itemClick"; "dropdownToggle": "dropdownToggle"; }, never, never, true, never>;
|
|
1047
|
+
}
|
|
1048
|
+
|
|
1049
|
+
interface DropdownInstance {
|
|
1050
|
+
id: string;
|
|
1051
|
+
close: () => void;
|
|
1052
|
+
element?: Element;
|
|
1053
|
+
}
|
|
1054
|
+
declare class DropdownManagerService {
|
|
1055
|
+
private activeDropdowns;
|
|
1056
|
+
private documentClickListener?;
|
|
1057
|
+
private escapeKeyListener?;
|
|
1058
|
+
constructor();
|
|
1059
|
+
private initializeGlobalListeners;
|
|
1060
|
+
registerDropdown(dropdown: DropdownInstance): void;
|
|
1061
|
+
unregisterDropdown(id: string): void;
|
|
1062
|
+
closeAllDropdowns(): void;
|
|
1063
|
+
closeDropdown(id: string): void;
|
|
1064
|
+
isDropdownOpen(id: string): boolean;
|
|
1065
|
+
private handleDocumentClick;
|
|
1066
|
+
ngOnDestroy(): void;
|
|
1067
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DropdownManagerService, never>;
|
|
1068
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<DropdownManagerService>;
|
|
1069
|
+
}
|
|
1070
|
+
|
|
1071
|
+
interface ConfirmationRequest<T = unknown> {
|
|
1072
|
+
id: string;
|
|
1073
|
+
title: string;
|
|
1074
|
+
message: string;
|
|
1075
|
+
type: 'danger' | 'warning' | 'info' | 'success';
|
|
1076
|
+
icon?: string;
|
|
1077
|
+
confirmText?: string;
|
|
1078
|
+
cancelText?: string;
|
|
1079
|
+
customTemplate?: TemplateRef<unknown>;
|
|
1080
|
+
customData?: T;
|
|
1081
|
+
resolve: (value: boolean | T) => void;
|
|
1082
|
+
reject: (reason?: unknown) => void;
|
|
1083
|
+
}
|
|
1084
|
+
interface ConfirmationOptions<T = unknown> {
|
|
1085
|
+
title: string;
|
|
1086
|
+
message: string;
|
|
1087
|
+
type?: 'danger' | 'warning' | 'info' | 'success';
|
|
1088
|
+
icon?: string;
|
|
1089
|
+
confirmText?: string;
|
|
1090
|
+
cancelText?: string;
|
|
1091
|
+
customTemplate?: TemplateRef<unknown>;
|
|
1092
|
+
customData?: T;
|
|
1093
|
+
}
|
|
1094
|
+
declare class ConfirmationService {
|
|
1095
|
+
private confirmationQueue;
|
|
1096
|
+
private currentRequest;
|
|
1097
|
+
hasActiveConfirmation: i0.Signal<boolean>;
|
|
1098
|
+
queueLength: i0.Signal<number>;
|
|
1099
|
+
constructor();
|
|
1100
|
+
/**
|
|
1101
|
+
* Ask for confirmation with a simple yes/no dialog
|
|
1102
|
+
*/
|
|
1103
|
+
ask(options: ConfirmationOptions<unknown>): Promise<boolean>;
|
|
1104
|
+
/**
|
|
1105
|
+
* Ask for confirmation with custom template and return custom data
|
|
1106
|
+
*/
|
|
1107
|
+
askWithTemplate<T = unknown>(options: ConfirmationOptions<T> & {
|
|
1108
|
+
customTemplate: TemplateRef<unknown>;
|
|
1109
|
+
}): Promise<T>;
|
|
1110
|
+
/**
|
|
1111
|
+
* Quick confirmation for dangerous actions
|
|
1112
|
+
*/
|
|
1113
|
+
confirmDelete(itemName?: string): Promise<boolean>;
|
|
1114
|
+
/**
|
|
1115
|
+
* Quick confirmation for permanent actions
|
|
1116
|
+
*/
|
|
1117
|
+
confirmPermanentAction(action: string, itemName?: string): Promise<boolean>;
|
|
1118
|
+
/**
|
|
1119
|
+
* Quick confirmation for safe actions
|
|
1120
|
+
*/
|
|
1121
|
+
confirmSafeAction(action: string, itemName?: string): Promise<boolean>;
|
|
1122
|
+
private addToQueue;
|
|
1123
|
+
private processQueue;
|
|
1124
|
+
confirmCurrentRequest(data?: unknown): void;
|
|
1125
|
+
cancelCurrentRequest(): void;
|
|
1126
|
+
private removeCurrentRequest;
|
|
1127
|
+
private generateId;
|
|
1128
|
+
private getDefaultIcon;
|
|
1129
|
+
getCurrentRequest(): i0.WritableSignal<ConfirmationRequest<unknown> | null>;
|
|
1130
|
+
getHasActiveConfirmation(): i0.Signal<boolean>;
|
|
1131
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ConfirmationService, never>;
|
|
1132
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<ConfirmationService>;
|
|
1133
|
+
}
|
|
1134
|
+
|
|
1135
|
+
interface NotificationOptions {
|
|
1136
|
+
message: string;
|
|
1137
|
+
type?: 'success' | 'error' | 'warning' | 'info';
|
|
1138
|
+
duration?: number;
|
|
1139
|
+
showUndo?: boolean;
|
|
1140
|
+
undoAction?: () => void;
|
|
1141
|
+
undoText?: string;
|
|
1142
|
+
icon?: string;
|
|
1143
|
+
title?: string;
|
|
1144
|
+
}
|
|
1145
|
+
interface NotificationItem {
|
|
1146
|
+
id: string;
|
|
1147
|
+
message: string;
|
|
1148
|
+
type: 'success' | 'error' | 'warning' | 'info';
|
|
1149
|
+
duration: number;
|
|
1150
|
+
showUndo: boolean;
|
|
1151
|
+
undoAction?: () => void;
|
|
1152
|
+
undoText: string;
|
|
1153
|
+
icon: string;
|
|
1154
|
+
title?: string;
|
|
1155
|
+
timestamp: number;
|
|
1156
|
+
isVisible: boolean;
|
|
1157
|
+
}
|
|
1158
|
+
declare class NotificationService {
|
|
1159
|
+
private notifications;
|
|
1160
|
+
private maxNotifications;
|
|
1161
|
+
activeNotifications: i0.Signal<NotificationItem[]>;
|
|
1162
|
+
constructor();
|
|
1163
|
+
/**
|
|
1164
|
+
* Show a success notification
|
|
1165
|
+
*/
|
|
1166
|
+
success(message: string, options?: Partial<NotificationOptions>): string;
|
|
1167
|
+
/**
|
|
1168
|
+
* Show an error notification
|
|
1169
|
+
*/
|
|
1170
|
+
error(message: string, options?: Partial<NotificationOptions>): string;
|
|
1171
|
+
/**
|
|
1172
|
+
* Show a warning notification
|
|
1173
|
+
*/
|
|
1174
|
+
warning(message: string, options?: Partial<NotificationOptions>): string;
|
|
1175
|
+
/**
|
|
1176
|
+
* Show an info notification
|
|
1177
|
+
*/
|
|
1178
|
+
info(message: string, options?: Partial<NotificationOptions>): string;
|
|
1179
|
+
/**
|
|
1180
|
+
* Show a notification with undo functionality
|
|
1181
|
+
*/
|
|
1182
|
+
showWithUndo(message: string, undoAction: () => void, options?: Partial<NotificationOptions>): string;
|
|
1183
|
+
/**
|
|
1184
|
+
* Show a notification for reversible destructive actions
|
|
1185
|
+
*/
|
|
1186
|
+
showReversibleAction(action: string, itemName: string, undoAction: () => void, options?: Partial<NotificationOptions>): string;
|
|
1187
|
+
/**
|
|
1188
|
+
* Show a notification for background tasks
|
|
1189
|
+
*/
|
|
1190
|
+
showBackgroundTask(taskName: string, isComplete?: boolean, options?: Partial<NotificationOptions>): string;
|
|
1191
|
+
/**
|
|
1192
|
+
* Core show method
|
|
1193
|
+
*/
|
|
1194
|
+
private show;
|
|
1195
|
+
/**
|
|
1196
|
+
* Remove a specific notification
|
|
1197
|
+
*/
|
|
1198
|
+
remove(id: string): void;
|
|
1199
|
+
/**
|
|
1200
|
+
* Remove all notifications
|
|
1201
|
+
*/
|
|
1202
|
+
clearAll(): void;
|
|
1203
|
+
/**
|
|
1204
|
+
* Execute undo action for a notification
|
|
1205
|
+
*/
|
|
1206
|
+
executeUndo(id: string): void;
|
|
1207
|
+
private addNotification;
|
|
1208
|
+
private generateId;
|
|
1209
|
+
private getDefaultIcon;
|
|
1210
|
+
getNotifications(): i0.WritableSignal<NotificationItem[]>;
|
|
1211
|
+
getActiveNotifications(): i0.Signal<NotificationItem[]>;
|
|
1212
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NotificationService, never>;
|
|
1213
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<NotificationService>;
|
|
1214
|
+
}
|
|
1215
|
+
|
|
1216
|
+
declare class CideEleConfirmationModalComponent {
|
|
1217
|
+
private confirmationService;
|
|
1218
|
+
hasActiveConfirmation: i0.Signal<boolean>;
|
|
1219
|
+
currentRequest: i0.WritableSignal<cloud_ide_element.ConfirmationRequest<unknown> | null>;
|
|
1220
|
+
customData: i0.WritableSignal<unknown>;
|
|
1221
|
+
getHeaderClass: i0.Signal<string>;
|
|
1222
|
+
getIconClass: i0.Signal<"success" | "danger" | "warning" | "info">;
|
|
1223
|
+
getConfirmButtonClass: i0.Signal<string>;
|
|
1224
|
+
onBackdropClick(event: Event): void;
|
|
1225
|
+
onCancel(): void;
|
|
1226
|
+
onConfirm(): void;
|
|
1227
|
+
updateCustomData(data: unknown): void;
|
|
1228
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CideEleConfirmationModalComponent, never>;
|
|
1229
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<CideEleConfirmationModalComponent, "cide-ele-confirmation-modal", never, {}, {}, never, never, true, never>;
|
|
1230
|
+
}
|
|
1231
|
+
|
|
1232
|
+
declare class CideEleToastNotificationComponent {
|
|
1233
|
+
private notificationService;
|
|
1234
|
+
activeNotifications: i0.Signal<NotificationItem[]>;
|
|
1235
|
+
getToastClass(notification: NotificationItem): string;
|
|
1236
|
+
getIconClass(type: string): string;
|
|
1237
|
+
removeNotification(id: string): void;
|
|
1238
|
+
executeUndo(id: string): void;
|
|
1239
|
+
trackByNotification(index: number, notification: NotificationItem): string;
|
|
1240
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CideEleToastNotificationComponent, never>;
|
|
1241
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<CideEleToastNotificationComponent, "cide-ele-toast-notification", never, {}, {}, never, never, true, never>;
|
|
1242
|
+
}
|
|
1243
|
+
|
|
1244
|
+
declare class CideEleGlobalNotificationsComponent {
|
|
1245
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CideEleGlobalNotificationsComponent, never>;
|
|
1246
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<CideEleGlobalNotificationsComponent, "cide-ele-global-notifications", never, {}, {}, never, never, true, never>;
|
|
1247
|
+
}
|
|
1248
|
+
|
|
1249
|
+
interface JsonEditorConfig {
|
|
1250
|
+
/** Enable syntax highlighting */
|
|
1251
|
+
syntaxHighlighting?: boolean;
|
|
1252
|
+
/** Enable line numbers */
|
|
1253
|
+
showLineNumbers?: boolean;
|
|
1254
|
+
/** Enable auto-formatting */
|
|
1255
|
+
autoFormat?: boolean;
|
|
1256
|
+
/** Enable validation */
|
|
1257
|
+
validateOnChange?: boolean;
|
|
1258
|
+
/** Theme for the editor */
|
|
1259
|
+
theme?: 'light' | 'dark';
|
|
1260
|
+
/** Minimum height in pixels */
|
|
1261
|
+
minHeight?: number;
|
|
1262
|
+
/** Maximum height in pixels */
|
|
1263
|
+
maxHeight?: number;
|
|
1264
|
+
/** Placeholder text */
|
|
1265
|
+
placeholder?: string;
|
|
1266
|
+
/** Read-only mode */
|
|
1267
|
+
readOnly?: boolean;
|
|
1268
|
+
/** Show error messages */
|
|
1269
|
+
showErrors?: boolean;
|
|
1270
|
+
}
|
|
1271
|
+
interface JsonEditorError {
|
|
1272
|
+
line: number;
|
|
1273
|
+
column: number;
|
|
1274
|
+
message: string;
|
|
1275
|
+
type: 'syntax' | 'validation';
|
|
1276
|
+
}
|
|
1277
|
+
declare class CideEleJsonEditorComponent implements OnInit, ControlValueAccessor {
|
|
1278
|
+
label?: string;
|
|
1279
|
+
helperText?: string;
|
|
1280
|
+
required: boolean;
|
|
1281
|
+
disabled: i0.WritableSignal<boolean>;
|
|
1282
|
+
showCharacterCount: boolean;
|
|
1283
|
+
config: JsonEditorConfig;
|
|
1284
|
+
configSignal: i0.WritableSignal<JsonEditorConfig>;
|
|
1285
|
+
valueChange: EventEmitter<string>;
|
|
1286
|
+
objectChange: EventEmitter<object | null>;
|
|
1287
|
+
errorsChange: EventEmitter<JsonEditorError[]>;
|
|
1288
|
+
validChange: EventEmitter<boolean>;
|
|
1289
|
+
jsonTextarea: i0.Signal<ElementRef<HTMLTextAreaElement>>;
|
|
1290
|
+
private destroyRef;
|
|
1291
|
+
jsonString: i0.WritableSignal<string>;
|
|
1292
|
+
jsonObject: i0.WritableSignal<object | null>;
|
|
1293
|
+
errors: i0.WritableSignal<JsonEditorError[]>;
|
|
1294
|
+
editorId: string;
|
|
1295
|
+
hasErrors: i0.Signal<boolean>;
|
|
1296
|
+
isValid: i0.Signal<boolean>;
|
|
1297
|
+
lineNumbers: i0.Signal<number[]>;
|
|
1298
|
+
containerClass: i0.Signal<string>;
|
|
1299
|
+
private defaultConfig;
|
|
1300
|
+
ngOnInit(): void;
|
|
1301
|
+
/**
|
|
1302
|
+
* Handle input changes
|
|
1303
|
+
*/
|
|
1304
|
+
onInput(event: Event): void;
|
|
1305
|
+
/**
|
|
1306
|
+
* Handle blur event
|
|
1307
|
+
*/
|
|
1308
|
+
onBlur(): void;
|
|
1309
|
+
/**
|
|
1310
|
+
* Parse JSON string and emit object
|
|
1311
|
+
*/
|
|
1312
|
+
private parseJson;
|
|
1313
|
+
/**
|
|
1314
|
+
* Validate JSON and update errors
|
|
1315
|
+
*/
|
|
1316
|
+
private validateJson;
|
|
1317
|
+
/**
|
|
1318
|
+
* Format JSON with proper indentation
|
|
1319
|
+
*/
|
|
1320
|
+
formatJson(): void;
|
|
1321
|
+
/**
|
|
1322
|
+
* Check if there's an error on a specific line
|
|
1323
|
+
*/
|
|
1324
|
+
hasErrorOnLine(line: number): boolean;
|
|
1325
|
+
/**
|
|
1326
|
+
* Get error ID for accessibility
|
|
1327
|
+
*/
|
|
1328
|
+
errorId(): string;
|
|
1329
|
+
/**
|
|
1330
|
+
* Focus the editor
|
|
1331
|
+
*/
|
|
1332
|
+
focus(): void;
|
|
1333
|
+
/**
|
|
1334
|
+
* Clear the editor
|
|
1335
|
+
*/
|
|
1336
|
+
clear(): void;
|
|
1337
|
+
/**
|
|
1338
|
+
* Get current JSON object
|
|
1339
|
+
*/
|
|
1340
|
+
getValue(): object | null;
|
|
1341
|
+
/**
|
|
1342
|
+
* Get current JSON string
|
|
1343
|
+
*/
|
|
1344
|
+
getStringValue(): string;
|
|
1345
|
+
/**
|
|
1346
|
+
* Check if JSON is valid
|
|
1347
|
+
*/
|
|
1348
|
+
isValidJson(): boolean;
|
|
1349
|
+
/**
|
|
1350
|
+
* Get validation errors
|
|
1351
|
+
*/
|
|
1352
|
+
getErrors(): JsonEditorError[];
|
|
1353
|
+
writeValue(value: string | object | null | undefined): void;
|
|
1354
|
+
registerOnChange(fn: (value: string) => void): void;
|
|
1355
|
+
registerOnTouched(fn: () => void): void;
|
|
1356
|
+
setDisabledState(isDisabled: boolean): void;
|
|
1357
|
+
private onChange;
|
|
1358
|
+
private onTouched;
|
|
1359
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CideEleJsonEditorComponent, never>;
|
|
1360
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<CideEleJsonEditorComponent, "cide-ele-json-editor", never, { "label": { "alias": "label"; "required": false; }; "helperText": { "alias": "helperText"; "required": false; }; "required": { "alias": "required"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "showCharacterCount": { "alias": "showCharacterCount"; "required": false; }; "config": { "alias": "config"; "required": false; }; }, { "valueChange": "valueChange"; "objectChange": "objectChange"; "errorsChange": "errorsChange"; "validChange": "validChange"; }, never, never, true, never>;
|
|
1361
|
+
}
|
|
1362
|
+
|
|
1363
|
+
export { CideEleButtonComponent, CideEleConfirmationModalComponent, CideEleDataGridComponent, CideEleDropdownComponent, CideEleFileInputComponent, CideEleGlobalNotificationsComponent, CideEleJsonEditorComponent, CideEleResizerDirective, CideEleSkeletonLoaderComponent, CideEleTabComponent, CideEleToastNotificationComponent, CideElementsService, CideIconComponent, CideInputComponent, CideSelectComponent, CideSelectOptionComponent, CideSpinnerComponent, CideTextareaComponent, ConfirmationService, DEFAULT_GRID_CONFIG, DropdownManagerService, NotificationService, TooltipDirective };
|
|
1364
|
+
export type { ButtonElevation, ButtonShape, ButtonSize, ButtonType, ButtonVariant, CideEleResizerDirection, CideEleResizerDirectionTo, ColumnType, ColumnWidth, ConfirmationOptions, ConfirmationRequest, DropdownConfig, DropdownInstance, DropdownItem, DropdownPosition, ErrorValidationStatus, GridAction, GridColumn, GridConfiguration, GridCustomFormatter, GridCustomRenderer, GridDragDropConfig, GridEvent, GridEventHandler, GridExportConfig, GridFormatter, GridLoadingConfig, GridPaginationConfig, GridScrollConfig, GridSearchConfig, GridState, GridTreeConfig, JsonEditorConfig, JsonEditorError, NotificationItem, NotificationOptions, Renderer, SelectOption, StatusConfig, StringRenderer, TabItem, TemplateContext, TemplateRenderer, TextAlign, TooltipPlacement, TooltipType, ValidationStatus };
|