cloud-ide-element 1.0.44 → 1.0.51
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/fesm2022/cloud-ide-element.mjs +814 -271
- package/fesm2022/cloud-ide-element.mjs.map +1 -1
- package/index.d.ts +81 -8
- package/package.json +1 -1
package/index.d.ts
CHANGED
|
@@ -3,8 +3,9 @@ import { PipeTransform, OnChanges, OnInit, OnDestroy, EventEmitter, TemplateRef,
|
|
|
3
3
|
import { ControlValueAccessor, Validator, AbstractControl, ValidationErrors } from '@angular/forms';
|
|
4
4
|
import { elementStyleType, labelPlacementType, labelDirType, autocapitalizeType, autocompleteType, controlType, inputType, themeSize, spinnerType, iconType, selectSearchType, ICoreSype, GetElementDataRequest } from 'cloud-ide-lms-model';
|
|
5
5
|
import { Router, NavigationExtras } from '@angular/router';
|
|
6
|
-
import { BehaviorSubject } from 'rxjs';
|
|
6
|
+
import { BehaviorSubject, Observable } from 'rxjs';
|
|
7
7
|
import * as cloud_ide_element from 'cloud-ide-element';
|
|
8
|
+
import { HttpClient } from '@angular/common/http';
|
|
8
9
|
|
|
9
10
|
declare class CapitalizePipe implements PipeTransform {
|
|
10
11
|
transform(value: string, capitalizationMethod: 'allUpperCase' | 'titleCase' | 'sentenceCase'): string;
|
|
@@ -410,7 +411,7 @@ declare class CideSelectComponent implements ControlValueAccessor, Validator, On
|
|
|
410
411
|
required: boolean;
|
|
411
412
|
disabled: boolean;
|
|
412
413
|
id: string;
|
|
413
|
-
ngModel: string | number;
|
|
414
|
+
ngModel: string | number | string[];
|
|
414
415
|
size: themeSize;
|
|
415
416
|
fill: elementStyleType;
|
|
416
417
|
labelPlacement: labelPlacementType;
|
|
@@ -435,7 +436,7 @@ declare class CideSelectComponent implements ControlValueAccessor, Validator, On
|
|
|
435
436
|
* Example: if options = [{id: 1, name: 'John'}, {id: 2, name: 'Jane'}], set labelKey = 'name'
|
|
436
437
|
*/
|
|
437
438
|
labelKey: string;
|
|
438
|
-
ngModelChange: EventEmitter<
|
|
439
|
+
ngModelChange: EventEmitter<string | number | string[]>;
|
|
439
440
|
selectionChange: EventEmitter<any>;
|
|
440
441
|
searchChange: EventEmitter<selectSearchType>;
|
|
441
442
|
isOpen: boolean;
|
|
@@ -444,6 +445,9 @@ declare class CideSelectComponent implements ControlValueAccessor, Validator, On
|
|
|
444
445
|
searchTerm: string;
|
|
445
446
|
filteredOptions: (SelectOption | SelectOptionObject)[];
|
|
446
447
|
private searchDebounceTimeout;
|
|
448
|
+
private searchSubject;
|
|
449
|
+
private destroy$;
|
|
450
|
+
private isUpdatingOptions;
|
|
447
451
|
private portalService;
|
|
448
452
|
private dropdownPortalId;
|
|
449
453
|
dropdownTemplate: TemplateRef<any>;
|
|
@@ -466,7 +470,7 @@ declare class CideSelectComponent implements ControlValueAccessor, Validator, On
|
|
|
466
470
|
registerOnTouched(fn: () => void): void;
|
|
467
471
|
setDisabledState(isDisabled: boolean): void;
|
|
468
472
|
validate(control: AbstractControl): ValidationErrors | null;
|
|
469
|
-
validateValue(value: string | number): ValidationErrors | null;
|
|
473
|
+
validateValue(value: string | number | string[]): ValidationErrors | null;
|
|
470
474
|
toggleDropdown(): void;
|
|
471
475
|
private openDropdown;
|
|
472
476
|
private closeDropdown;
|
|
@@ -474,6 +478,10 @@ declare class CideSelectComponent implements ControlValueAccessor, Validator, On
|
|
|
474
478
|
private createDropdownPortal;
|
|
475
479
|
private destroyDropdownPortal;
|
|
476
480
|
private updatePortalContext;
|
|
481
|
+
private updateOptionsInDOM;
|
|
482
|
+
private setupDebouncedSearch;
|
|
483
|
+
private performSearch;
|
|
484
|
+
private cleanupOrphanedPortals;
|
|
477
485
|
private onWindowResize;
|
|
478
486
|
private calculateDropdownPosition;
|
|
479
487
|
selectOption(option: SelectOption | SelectOptionObject): void;
|
|
@@ -484,6 +492,7 @@ declare class CideSelectComponent implements ControlValueAccessor, Validator, On
|
|
|
484
492
|
filterOptions(): void;
|
|
485
493
|
onSearchInput(event: Event): void;
|
|
486
494
|
onDropdownMouseDown(): void;
|
|
495
|
+
onSearchInputBlur(event: Event): void;
|
|
487
496
|
onDropdownMouseUp(): void;
|
|
488
497
|
isOptionSelected(option: SelectOption | SelectOptionObject): boolean;
|
|
489
498
|
getOptionValue(option: SelectOption | SelectOptionObject): string | number;
|
|
@@ -523,6 +532,8 @@ declare class CideEleTabComponent implements OnInit {
|
|
|
523
532
|
}
|
|
524
533
|
|
|
525
534
|
declare class CideEleFileInputComponent implements ControlValueAccessor, OnDestroy {
|
|
535
|
+
private fileManagerService;
|
|
536
|
+
private notificationService;
|
|
526
537
|
label: string;
|
|
527
538
|
accept: string;
|
|
528
539
|
multiple: boolean;
|
|
@@ -533,10 +544,19 @@ declare class CideEleFileInputComponent implements ControlValueAccessor, OnDestr
|
|
|
533
544
|
previewWidth: string;
|
|
534
545
|
previewHeight: string;
|
|
535
546
|
previewBoxMode: boolean;
|
|
547
|
+
showFileName: boolean;
|
|
536
548
|
placeholderText: string;
|
|
537
549
|
placeholderIcon: string;
|
|
550
|
+
autoUpload: boolean;
|
|
551
|
+
uploadData: any;
|
|
538
552
|
id: string;
|
|
553
|
+
isUploading: boolean;
|
|
554
|
+
uploadProgress: number;
|
|
555
|
+
private uploadNotificationId;
|
|
539
556
|
fileChange: EventEmitter<FileList | null>;
|
|
557
|
+
uploadSuccess: EventEmitter<string>;
|
|
558
|
+
uploadError: EventEmitter<string>;
|
|
559
|
+
uploadProgressChange: EventEmitter<number>;
|
|
540
560
|
files: FileList | null;
|
|
541
561
|
fileNames: string[];
|
|
542
562
|
previewUrls: string[];
|
|
@@ -548,6 +568,8 @@ declare class CideEleFileInputComponent implements ControlValueAccessor, OnDestr
|
|
|
548
568
|
setDisabledState(isDisabled: boolean): void;
|
|
549
569
|
onFileSelected(event: Event): void;
|
|
550
570
|
clearFiles(): void;
|
|
571
|
+
private uploadFile;
|
|
572
|
+
private simulateProgress;
|
|
551
573
|
private generatePreviews;
|
|
552
574
|
private clearPreviews;
|
|
553
575
|
private isImageFile;
|
|
@@ -558,7 +580,7 @@ declare class CideEleFileInputComponent implements ControlValueAccessor, OnDestr
|
|
|
558
580
|
isPreviewBoxMode(): boolean;
|
|
559
581
|
hasImages(): boolean;
|
|
560
582
|
static ɵfac: i0.ɵɵFactoryDeclaration<CideEleFileInputComponent, never>;
|
|
561
|
-
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; }; "showPreview": { "alias": "showPreview"; "required": false; }; "previewWidth": { "alias": "previewWidth"; "required": false; }; "previewHeight": { "alias": "previewHeight"; "required": false; }; "previewBoxMode": { "alias": "previewBoxMode"; "required": false; }; "placeholderText": { "alias": "placeholderText"; "required": false; }; "placeholderIcon": { "alias": "placeholderIcon"; "required": false; }; }, { "fileChange": "fileChange"; }, never, never, true, never>;
|
|
583
|
+
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; }; "showPreview": { "alias": "showPreview"; "required": false; }; "previewWidth": { "alias": "previewWidth"; "required": false; }; "previewHeight": { "alias": "previewHeight"; "required": false; }; "previewBoxMode": { "alias": "previewBoxMode"; "required": false; }; "showFileName": { "alias": "showFileName"; "required": false; }; "placeholderText": { "alias": "placeholderText"; "required": false; }; "placeholderIcon": { "alias": "placeholderIcon"; "required": false; }; "autoUpload": { "alias": "autoUpload"; "required": false; }; "uploadData": { "alias": "uploadData"; "required": false; }; }, { "fileChange": "fileChange"; "uploadSuccess": "uploadSuccess"; "uploadError": "uploadError"; "uploadProgressChange": "uploadProgressChange"; }, never, never, true, never>;
|
|
562
584
|
}
|
|
563
585
|
|
|
564
586
|
declare class CideTextareaComponent implements ControlValueAccessor, Validator, OnInit, OnChanges {
|
|
@@ -949,7 +971,7 @@ declare class CideEleDataGridComponent<T = Record<string, unknown>> implements O
|
|
|
949
971
|
private updatePaginationState;
|
|
950
972
|
onPageChange(page: number | string): void;
|
|
951
973
|
onPageSizeChange(): void;
|
|
952
|
-
updatePageSize(value: string | number): void;
|
|
974
|
+
updatePageSize(value: string | number | string[]): void;
|
|
953
975
|
previousPage(): void;
|
|
954
976
|
nextPage(): void;
|
|
955
977
|
onJumpToPage(): void;
|
|
@@ -1115,6 +1137,7 @@ interface DropdownConfig {
|
|
|
1115
1137
|
forcePosition?: 'top' | 'bottom' | 'left' | 'right';
|
|
1116
1138
|
offsetX?: number;
|
|
1117
1139
|
offsetY?: number;
|
|
1140
|
+
minWidth?: number;
|
|
1118
1141
|
usePortal?: boolean;
|
|
1119
1142
|
}
|
|
1120
1143
|
interface DropdownPosition {
|
|
@@ -1158,6 +1181,7 @@ declare class CideEleDropdownComponent implements OnInit, OnDestroy {
|
|
|
1158
1181
|
getMenuStyles(): string;
|
|
1159
1182
|
calculatePosition(): DropdownPosition;
|
|
1160
1183
|
private getMenuWidth;
|
|
1184
|
+
protected getSafeConfig(): DropdownConfig;
|
|
1161
1185
|
private getEstimatedMenuHeight;
|
|
1162
1186
|
toggleDropdown(event: Event): void;
|
|
1163
1187
|
private openDropdown;
|
|
@@ -1270,6 +1294,8 @@ interface NotificationOptions {
|
|
|
1270
1294
|
undoText?: string;
|
|
1271
1295
|
icon?: string;
|
|
1272
1296
|
title?: string;
|
|
1297
|
+
progress?: number;
|
|
1298
|
+
showProgress?: boolean;
|
|
1273
1299
|
}
|
|
1274
1300
|
interface NotificationItem {
|
|
1275
1301
|
id: string;
|
|
@@ -1283,6 +1309,8 @@ interface NotificationItem {
|
|
|
1283
1309
|
title?: string;
|
|
1284
1310
|
timestamp: number;
|
|
1285
1311
|
isVisible: boolean;
|
|
1312
|
+
progress?: number;
|
|
1313
|
+
showProgress?: boolean;
|
|
1286
1314
|
}
|
|
1287
1315
|
declare class NotificationService {
|
|
1288
1316
|
private notifications;
|
|
@@ -1317,6 +1345,14 @@ declare class NotificationService {
|
|
|
1317
1345
|
* Show a notification for background tasks
|
|
1318
1346
|
*/
|
|
1319
1347
|
showBackgroundTask(taskName: string, isComplete?: boolean, options?: Partial<NotificationOptions>): string;
|
|
1348
|
+
/**
|
|
1349
|
+
* Show a progress notification
|
|
1350
|
+
*/
|
|
1351
|
+
showProgress(message: string, progress?: number, options?: Partial<NotificationOptions>): string;
|
|
1352
|
+
/**
|
|
1353
|
+
* Update progress for an existing notification
|
|
1354
|
+
*/
|
|
1355
|
+
updateProgress(id: string, progress: number, message?: string): void;
|
|
1320
1356
|
/**
|
|
1321
1357
|
* Core show method
|
|
1322
1358
|
*/
|
|
@@ -1342,6 +1378,43 @@ declare class NotificationService {
|
|
|
1342
1378
|
static ɵprov: i0.ɵɵInjectableDeclaration<NotificationService>;
|
|
1343
1379
|
}
|
|
1344
1380
|
|
|
1381
|
+
interface FileUploadPayload {
|
|
1382
|
+
cyfm_name: string;
|
|
1383
|
+
cyfm_alt_text: string;
|
|
1384
|
+
cyfm_path: string;
|
|
1385
|
+
cyfm_size_in_byte: number;
|
|
1386
|
+
cyfm_type: string;
|
|
1387
|
+
cyfm_creation_dt: string;
|
|
1388
|
+
cyfm_id_user: string;
|
|
1389
|
+
cyfm_permissions: string[];
|
|
1390
|
+
cyfm_tags: string[];
|
|
1391
|
+
cyfm_version: number;
|
|
1392
|
+
cyfm_file_status_sygmt: string;
|
|
1393
|
+
cyfm_isactive: boolean;
|
|
1394
|
+
fileData: string;
|
|
1395
|
+
[key: string]: any;
|
|
1396
|
+
}
|
|
1397
|
+
declare class CideEleFileManagerService {
|
|
1398
|
+
private http;
|
|
1399
|
+
private baseUrl;
|
|
1400
|
+
constructor(http: HttpClient);
|
|
1401
|
+
/**
|
|
1402
|
+
* Upload a file with base64 encoding
|
|
1403
|
+
* @param file The file to upload
|
|
1404
|
+
* @param additionalData Additional data to include in the payload
|
|
1405
|
+
* @returns Observable with the upload response
|
|
1406
|
+
*/
|
|
1407
|
+
uploadFile(file: File, additionalData?: any): Observable<any>;
|
|
1408
|
+
/**
|
|
1409
|
+
* Set the base URL for API calls
|
|
1410
|
+
* This should be called by the consuming application during initialization
|
|
1411
|
+
* @param url The base URL for the API
|
|
1412
|
+
*/
|
|
1413
|
+
setBaseUrl(url: string): void;
|
|
1414
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CideEleFileManagerService, never>;
|
|
1415
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<CideEleFileManagerService>;
|
|
1416
|
+
}
|
|
1417
|
+
|
|
1345
1418
|
declare class CideEleConfirmationModalComponent implements OnInit, OnDestroy {
|
|
1346
1419
|
private readonly confirmationService;
|
|
1347
1420
|
readonly hasActiveConfirmation: i0.Signal<boolean>;
|
|
@@ -1491,5 +1564,5 @@ declare class CideEleJsonEditorComponent implements OnInit, ControlValueAccessor
|
|
|
1491
1564
|
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>;
|
|
1492
1565
|
}
|
|
1493
1566
|
|
|
1494
|
-
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 };
|
|
1495
|
-
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, SelectOption, SelectOptionObject, StatusConfig, TabItem, TemplateContext, TemplateRenderer, TextAlign, TooltipPlacement, TooltipType, ValidationStatus };
|
|
1567
|
+
export { CideEleButtonComponent, CideEleConfirmationModalComponent, CideEleDataGridComponent, CideEleDropdownComponent, CideEleFileInputComponent, CideEleFileManagerService, CideEleGlobalNotificationsComponent, CideEleJsonEditorComponent, CideEleResizerDirective, CideEleSkeletonLoaderComponent, CideEleTabComponent, CideEleToastNotificationComponent, CideElementsService, CideIconComponent, CideInputComponent, CideSelectComponent, CideSelectOptionComponent, CideSpinnerComponent, CideTextareaComponent, ConfirmationService, DEFAULT_GRID_CONFIG, DropdownManagerService, NotificationService, TooltipDirective };
|
|
1568
|
+
export type { ButtonElevation, ButtonShape, ButtonSize, ButtonType, ButtonVariant, CideEleResizerDirection, CideEleResizerDirectionTo, ColumnType, ColumnWidth, ConfirmationOptions, ConfirmationRequest, DropdownConfig, DropdownInstance, DropdownItem, DropdownPosition, ErrorValidationStatus, FileUploadPayload, GridAction, GridColumn, GridConfiguration, GridCustomFormatter, GridCustomRenderer, GridDragDropConfig, GridEvent, GridEventHandler, GridExportConfig, GridFormatter, GridLoadingConfig, GridPaginationConfig, GridScrollConfig, GridSearchConfig, GridState, GridTreeConfig, JsonEditorConfig, JsonEditorError, NotificationItem, NotificationOptions, SelectOption, SelectOptionObject, StatusConfig, TabItem, TemplateContext, TemplateRenderer, TextAlign, TooltipPlacement, TooltipType, ValidationStatus };
|