@magic-xpa/angular 4.1300.0-dev4130.3 → 4.1300.0-dev4130.300

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (63) hide show
  1. package/fesm2022/magic-xpa-angular.mjs +788 -566
  2. package/fesm2022/magic-xpa-angular.mjs.map +1 -1
  3. package/package.json +17 -14
  4. package/types/magic-xpa-angular.d.ts +2711 -0
  5. package/index.d.ts +0 -61
  6. package/src/controls.metadata.model.d.ts +0 -78
  7. package/src/interfaces/sub-form-definition.iterface.d.ts +0 -18
  8. package/src/magic.core.module.d.ts +0 -44
  9. package/src/services/ISubformMagicService.d.ts +0 -4
  10. package/src/services/OverlayWindowService.d.ts +0 -49
  11. package/src/services/StylesMapManager.d.ts +0 -8
  12. package/src/services/accessor.magic.service.d.ts +0 -311
  13. package/src/services/commands-collector.magic.service.d.ts +0 -18
  14. package/src/services/component-list.magic.service.d.ts +0 -50
  15. package/src/services/confirmation.components.magic.provider.d.ts +0 -24
  16. package/src/services/engine.magic.service.d.ts +0 -32
  17. package/src/services/exit.magic.service.d.ts +0 -12
  18. package/src/services/magic-color.service.d.ts +0 -25
  19. package/src/services/magic.lazy.loader.service.d.ts +0 -6
  20. package/src/services/magic.providers.d.ts +0 -110
  21. package/src/services/magic.services.d.ts +0 -22
  22. package/src/services/mg-date-adapter.d.ts +0 -38
  23. package/src/services/overlay.conainer.magic.provider.d.ts +0 -7
  24. package/src/services/router-commands.magic.service.d.ts +0 -23
  25. package/src/services/subform.magic.service.d.ts +0 -71
  26. package/src/services/table.magic.service.d.ts +0 -86
  27. package/src/services/task.magics.service.d.ts +0 -405
  28. package/src/services/title.magic.service.d.ts +0 -20
  29. package/src/ui/GuiInteractiveExecutor.d.ts +0 -25
  30. package/src/ui/components/base-magic-alert.component.d.ts +0 -26
  31. package/src/ui/components/base-magic-confirm.component.d.ts +0 -28
  32. package/src/ui/components/magic-alert.component.d.ts +0 -9
  33. package/src/ui/components/magic-confirmation-box.component.d.ts +0 -9
  34. package/src/ui/directives/NonMagicControlDirective.d.ts +0 -67
  35. package/src/ui/directives/magic/checkbox-noformcontrol.magic.directive.d.ts +0 -15
  36. package/src/ui/directives/magic/checkbox.magic.directive.d.ts +0 -34
  37. package/src/ui/directives/magic/combobox.magic.directive.d.ts +0 -19
  38. package/src/ui/directives/magic/form-controls/control-value-accessors/checkbox.cva.directive.d.ts +0 -13
  39. package/src/ui/directives/magic/form-controls/control-value-accessors/date.cva.directive.d.ts +0 -36
  40. package/src/ui/directives/magic/form-controls/control-value-accessors/default.cva.directive.d.ts +0 -13
  41. package/src/ui/directives/magic/input.noformcontrol.magic.directive.d.ts +0 -15
  42. package/src/ui/directives/magic/nocontrol.magic.directive.d.ts +0 -21
  43. package/src/ui/directives/magic/row.magic.directive.d.ts +0 -32
  44. package/src/ui/directives/magic-focus.directive.d.ts +0 -12
  45. package/src/ui/directives/magic.directive.d.ts +0 -127
  46. package/src/ui/directives/magicViewContainerRef.directive.d.ts +0 -11
  47. package/src/ui/directives/mgformat.magic.directive.d.ts +0 -82
  48. package/src/ui/directives/range-validator.magic.directive.d.ts +0 -33
  49. package/src/ui/magic-confirmationBox.d.ts +0 -25
  50. package/src/ui/magic-modal/base-magic-overlay-container.d.ts +0 -14
  51. package/src/ui/magic-modal/magic-modal-form.d.ts +0 -8
  52. package/src/ui/magic-modal/magic-modal-interface.d.ts +0 -45
  53. package/src/ui/magic-modal/magic-overlay-container-wrapper.d.ts +0 -50
  54. package/src/ui/magic-modal/magic-overlay-container.d.ts +0 -117
  55. package/src/ui/magic-root.component.d.ts +0 -85
  56. package/src/ui/mgerror.magic.component.d.ts +0 -39
  57. package/src/ui/pipes/date.magic.pipe.d.ts +0 -23
  58. package/src/ui/pipes/time.magic.pipe.d.ts +0 -14
  59. package/src/ui/pipes/time24.magic.pipe.d.ts +0 -10
  60. package/src/ui/router-container.magic.component.d.ts +0 -50
  61. package/src/ui/subform.magic.component.d.ts +0 -37
  62. package/src/ui/task-base.magic.component.d.ts +0 -112
  63. package/src/ui/utils.d.ts +0 -12
@@ -0,0 +1,2711 @@
1
+ import { StorageAttribute, MagicProperties } from '@magic-xpa/utils';
2
+ import { HtmlProperties, CustomValidator, GuiCommand, GuiInteractive, OverlayType, PIC, Styles } from '@magic-xpa/gui';
3
+ import * as i0 from '@angular/core';
4
+ import { NgModuleRef, ViewContainerRef, OnInit, Type, InjectionToken, EventEmitter, OnDestroy, AfterViewInit, ChangeDetectorRef, ElementRef, Renderer2, TemplateRef, PipeTransform } from '@angular/core';
5
+ import * as i31 from '@angular/forms';
6
+ import { FormGroup, AbstractControl, ValidatorFn, FormControl, CheckboxControlValueAccessor, DefaultValueAccessor, ControlValueAccessor, Validator } from '@angular/forms';
7
+ import { Subject, Subscription, Observable } from 'rxjs';
8
+ import { MagicBridge, IGuiEvent } from '@magic-xpa/engine';
9
+ import { HttpClient } from '@angular/common/http';
10
+ import { List, RefParam } from '@magic-xpa/mscorelib';
11
+ import * as i32 from '@angular/router';
12
+ import { Router, ActivatedRoute } from '@angular/router';
13
+ import { Title } from '@angular/platform-browser';
14
+ import { MaskitoOptions } from '@maskito/core';
15
+ import { Platform } from '@angular/cdk/platform';
16
+ import * as i30 from '@angular/common';
17
+ import { DatePipe } from '@angular/common';
18
+ import * as i33 from 'ng-dynamic-component';
19
+ import * as i34 from '@maskito/angular';
20
+ import * as i35 from '@angular/cdk/drag-drop';
21
+ import * as _angular_material_core from '@angular/material/core';
22
+ import { NativeDateAdapter, DateAdapter } from '@angular/material/core';
23
+
24
+ /**
25
+ * @ignore
26
+ */
27
+ declare class ControlMetadata {
28
+ controlType: string;
29
+ dataType: StorageAttribute;
30
+ properties: Map<HtmlProperties, any>;
31
+ classesMap: Map<HtmlClasses, any>;
32
+ stylesMap: Map<HtmlClasses, any>;
33
+ removedClass: string;
34
+ classes: string;
35
+ rangeValidator: boolean;
36
+ userProperties: Map<string, any>;
37
+ customValidators: Map<string, CustomValidator>;
38
+ setClass(key: any, value: any): void;
39
+ setStyle(key: any, value: any): void;
40
+ }
41
+ /**
42
+ * @ignore
43
+ */
44
+ declare class ControlsMetadata {
45
+ values: Map<string, string>;
46
+ ControlsProperties: Map<string, ControlMetadata>;
47
+ rowId: string;
48
+ isCreated: boolean;
49
+ isEditing: boolean;
50
+ get Values(): Map<string, string>;
51
+ getControlMetadata(controlId: string): ControlMetadata;
52
+ update(obj: any): void;
53
+ setValue(controlName: string, value: any): void;
54
+ getProperty(controlId: string, prop: HtmlProperties): any;
55
+ getValue(controlName: string): string;
56
+ }
57
+ /**
58
+ * @ignore
59
+ */
60
+ declare class Records {
61
+ data: Map<number, ControlsMetadata>;
62
+ list: ControlsMetadata[];
63
+ includesFirst: boolean;
64
+ includesLast: boolean;
65
+ guiTopIndex: number;
66
+ recordsBeforeCurrentView: number;
67
+ isEmptyDataView: boolean;
68
+ sizeUpdated: boolean;
69
+ getRow(dvRowId: number): ControlsMetadata;
70
+ markRowAsCreated(guiRowId: number): void;
71
+ markRowAsNotCreated(guiRowId: number): void;
72
+ isRowCreated(guiRowId: number): boolean;
73
+ startRowEditing(guiRowId: number): void;
74
+ stopRowEditing(guiRowId: number): void;
75
+ isRowInRowEditing(guiRowId: string): boolean;
76
+ update(obj: any): void;
77
+ updateSize(len: number): void;
78
+ /**
79
+ * crears data for the first record
80
+ * @param template
81
+ */
82
+ clearFirstTableRecord(template: {
83
+ [id: string]: string;
84
+ }): void;
85
+ addRow(guiRowId: number): void;
86
+ createFirst(): void;
87
+ fromJson(data: string): void;
88
+ setGuiTopIndex(topIndex: number): void;
89
+ getGuiTopIndex(): number;
90
+ }
91
+ /**
92
+ * @ignore
93
+ */
94
+ declare enum HtmlClasses {
95
+ Color = "color",
96
+ font = "font",
97
+ FocusColor = "focuscolor",
98
+ HintColor = "hintcolor"
99
+ }
100
+
101
+ /**
102
+ * @ignore
103
+ */
104
+ declare class EngineMagicService {
105
+ magicBridge: typeof MagicBridge;
106
+ isStub: boolean;
107
+ isLoggedIn: boolean;
108
+ refreshDom: Subject<GuiCommand>;
109
+ interactiveCommands: Subject<GuiInteractive>;
110
+ private readonly magicChangeDetection;
111
+ startMagicEngine(httpClient: HttpClient, args: Map<string, string>): void;
112
+ terminateMagic(): Promise<void>;
113
+ insertEvent(guiEvent: IGuiEvent): void;
114
+ GetRangedValue(taskId: string, controlName: string, value: string): string;
115
+ GetControlPictureMask(taskId: string, controlName: string): any;
116
+ UploadFileToServer(fileContent: any, serverFileName: string): any;
117
+ DownloadFileFromServer(serverFileName: string): Promise<ArrayBuffer>;
118
+ GetFormattedValue(taskId: string, controlName: string, value: any, rowId?: string): any;
119
+ ValidateControlValue(taskId: string, controlName: string, value: any): string;
120
+ GetFldRanges(taskId: string, controlName: string): string;
121
+ saveData(data: string): void;
122
+ getIsLoggedIn(): boolean;
123
+ setIsLoggedIn(setIsLoggedIn: boolean): void;
124
+ TransCacheExists(): boolean;
125
+ TerminateContextUsingFetchAPI(): void;
126
+ static ɵfac: i0.ɵɵFactoryDeclaration<EngineMagicService, never>;
127
+ static ɵprov: i0.ɵɵInjectableDeclaration<any>;
128
+ }
129
+
130
+ interface ComponentData {
131
+ component: any;
132
+ moduleRef: NgModuleRef<any>;
133
+ }
134
+ interface ModuleData {
135
+ moduleName: string;
136
+ modulePath: string;
137
+ }
138
+ /**
139
+ * Manages the list of components in a project, and the project title
140
+ */
141
+ declare class ComponentListMagicService {
142
+ /**
143
+ * Map of project components
144
+ */
145
+ components: Map<string, ComponentData>;
146
+ /**
147
+ * Map of project dialogs
148
+ */
149
+ dialogs: Map<string, any>;
150
+ lazyLoadModulesMap: any;
151
+ getData(name: string, mustHaveData: boolean): ComponentData;
152
+ /**
153
+ * Return a component according to name
154
+ * @param name Name of requested component
155
+ * @returns The requested component
156
+ */
157
+ getComponent(name: string, mustHaveData?: boolean): any;
158
+ addComponents(componentList: any, modulRef?: NgModuleRef<any>): void;
159
+ /**
160
+ * Return a component according to name
161
+ * @param name Name of requested component
162
+ * @returns The requested component
163
+ */
164
+ getModuleRef(name: string): NgModuleRef<any>;
165
+ /**
166
+ * Return the lazy load module details of the specified component
167
+ * @param name: Name of requested component
168
+ * @returns: lazy load module details
169
+ */
170
+ getLazyLoadModuleData(name: string): ModuleData;
171
+ /**
172
+ * Project title
173
+ */
174
+ title: string;
175
+ static ɵfac: i0.ɵɵFactoryDeclaration<ComponentListMagicService, never>;
176
+ static ɵprov: i0.ɵɵInjectableDeclaration<any>;
177
+ }
178
+
179
+ /**
180
+ * @ignore
181
+ */
182
+ declare class CommandsCollectorMagicService {
183
+ private count;
184
+ private commands;
185
+ private subscription;
186
+ protected magic: EngineMagicService;
187
+ constructor();
188
+ startCollecting(): void;
189
+ stopCollecting(): void;
190
+ GetCommands(taskId: string): GuiCommand[];
191
+ static ɵfac: i0.ɵɵFactoryDeclaration<CommandsCollectorMagicService, never>;
192
+ static ɵprov: i0.ɵɵInjectableDeclaration<any>;
193
+ }
194
+
195
+ /**
196
+ * @ignore
197
+ */
198
+ interface SubformDefinition {
199
+ formName: string;
200
+ parameters: any;
201
+ }
202
+ /**
203
+ * @ignore
204
+ */
205
+ interface RouteDefinition {
206
+ formName: string;
207
+ parameters: any;
208
+ }
209
+ interface IMagicViewContainerRef {
210
+ setViewContainerRef(vcRef: ViewContainerRef): any;
211
+ }
212
+
213
+ interface ISubformMagicService {
214
+ ExecuteRouteCommand(routeCommand: RouteCommand): any;
215
+ }
216
+
217
+ /**
218
+ * @ignore
219
+ */
220
+ declare class RouteCommand {
221
+ callerMgSubformServiceRef: ISubformMagicService;
222
+ routerOutletName: string;
223
+ formName: string;
224
+ parameters: any;
225
+ routeParams: List<any>;
226
+ }
227
+ /**
228
+ * @ignore
229
+ */
230
+ declare class RouterCommandsMagicService {
231
+ private pendingRouteCommands;
232
+ AddRouteCommand(routeCommand: RouteCommand): void;
233
+ ExecuteNextCommand(): void;
234
+ static ɵfac: i0.ɵɵFactoryDeclaration<RouterCommandsMagicService, never>;
235
+ static ɵprov: i0.ɵɵInjectableDeclaration<any>;
236
+ }
237
+
238
+ /**
239
+ * Mock component, implements routing by connecting the requested URL with the appropriate Magic task
240
+ */
241
+ declare class RouterContainerMagicComponent implements OnInit {
242
+ private componentRef;
243
+ private parentMgSubformService;
244
+ private static lastRoute;
245
+ private routePath;
246
+ static get LastRoute(): string;
247
+ private activatedRoute;
248
+ protected router: Router;
249
+ protected magic: EngineMagicService;
250
+ private containerTaskService;
251
+ private viewContainerRef;
252
+ private componentList;
253
+ protected pendingCommandsCollector: CommandsCollectorMagicService;
254
+ protected routerCommandsMagicService: RouterCommandsMagicService;
255
+ /**
256
+ *
257
+ * @param changeDetectorRef
258
+ * @param activatedRoute
259
+ * @param magic
260
+ * @param componentFactoryResolver
261
+ * @param viewContainerRef
262
+ * @param componentList
263
+ * @param pendingCommandsCollector
264
+ */
265
+ constructor();
266
+ /**
267
+ * Initialization
268
+ */
269
+ ngOnInit(): void;
270
+ private insertRouteEvent;
271
+ initializeComponent(): void;
272
+ /**
273
+ * Cleanup
274
+ */
275
+ ngOnDestroy(): void;
276
+ getRouterPath(): string;
277
+ static ɵfac: i0.ɵɵFactoryDeclaration<RouterContainerMagicComponent, never>;
278
+ static ɵcmp: i0.ɵɵComponentDeclaration<RouterContainerMagicComponent, "magic-route-outlet", never, {}, {}, never, never, false, never>;
279
+ }
280
+
281
+ /**
282
+ * Service for managing subforms and routing
283
+ */
284
+ declare class SubformMagicService implements ISubformMagicService {
285
+ subformsDict: {};
286
+ routesDict: {
287
+ [x: string]: string;
288
+ };
289
+ currentRouteDefinition: RouteDefinition;
290
+ static currentCallerMgSubformServiceRef: any;
291
+ static routerContainers: Array<RouterContainerMagicComponent>;
292
+ private task;
293
+ protected activatedRoute: ActivatedRoute;
294
+ protected componentList: ComponentListMagicService;
295
+ protected pendingCommandsCollector: CommandsCollectorMagicService;
296
+ protected router: Router;
297
+ protected routerCommandsMagicService: RouterCommandsMagicService;
298
+ private componentListMagicService;
299
+ private loader;
300
+ private injector;
301
+ constructor();
302
+ /**
303
+ * Finds and returns the component according to the subform name
304
+ * @param subformName
305
+ * @returns
306
+ */
307
+ mgGetComp(subformName: string): Type<any>;
308
+ /**
309
+ * Returns the parameters of the subform
310
+ * @param subformName
311
+ * @returns
312
+ */
313
+ mgGetParameters(subformName: string): any;
314
+ /**
315
+ * @ignore
316
+ */
317
+ deleteSubformComp(subformControlName: string, formName: string): void;
318
+ /**
319
+ * @ignore
320
+ */
321
+ addSubformComp(subformControlName: string, formName: string, taskId: string, taskDescription: any, routerPath: string, params: List<any>, inDefaultOutlet: boolean): void;
322
+ /**
323
+ * Open the subform using a route command
324
+ */
325
+ ExecuteRouteCommand(routeCommand: RouteCommand): void;
326
+ private PerformRouterNavigate;
327
+ /**
328
+ * @ignore
329
+ */
330
+ init(): void;
331
+ /**
332
+ * @ignore
333
+ */
334
+ refreshView(): void;
335
+ static getRelativeRoute(sendActivatedRoute: ActivatedRoute): ActivatedRoute;
336
+ static ɵfac: i0.ɵɵFactoryDeclaration<SubformMagicService, never>;
337
+ static ɵprov: i0.ɵɵInjectableDeclaration<any>;
338
+ }
339
+
340
+ /**
341
+ * Enables changing the browser title using Magic expression (SetTitle)
342
+ */
343
+ declare class TitleMagicService {
344
+ protected titleService: Title;
345
+ constructor();
346
+ /**
347
+ * Set the new title of the window
348
+ * @param newTitle New title of the window
349
+ */
350
+ setTitle(newTitle: string): void;
351
+ static ɵfac: i0.ɵɵFactoryDeclaration<TitleMagicService, never>;
352
+ static ɵprov: i0.ɵɵInjectableDeclaration<any>;
353
+ }
354
+
355
+ declare let COLOR_FILE_NAME: InjectionToken<string>;
356
+ declare const MAGIC_FG_COLOR: number;
357
+ declare const MAGIC_BG_COLOR: number;
358
+ declare class MagicColorService {
359
+ colorFileName: string;
360
+ getColorFilePath(): string;
361
+ private colorsData;
362
+ private fileNotFound;
363
+ private http;
364
+ colorFile1: string;
365
+ constructor();
366
+ private getColorData;
367
+ private hexToRgba;
368
+ /**
369
+ * Returns the rgba value of specified color
370
+ * @returns : value in format rgba(128,128,128,1)
371
+ * @param : colorNumber -0 based index of color for which RGBA values are returned
372
+ * @param: colorType : 1-MAGIC_FG_COLOR, 2-MAGIC_BG_COLOR
373
+ */
374
+ getColor(colorIndex: number, colorType: number): any;
375
+ static ɵfac: i0.ɵɵFactoryDeclaration<MagicColorService, never>;
376
+ static ɵprov: i0.ɵɵInjectableDeclaration<any>;
377
+ }
378
+
379
+ /**
380
+ * Provides the UI with values calculated by the Magic WebClient
381
+ */
382
+ declare class AccessorMagicService {
383
+ Logger: any;
384
+ readonly hhmm: MaskitoOptions;
385
+ readonly hhmmss: MaskitoOptions;
386
+ protected task: TaskMagicService;
387
+ protected magicColor: MagicColorService;
388
+ /**
389
+ * @ignore
390
+ */
391
+ constructor();
392
+ UploadFileToServer(fileContent: any, serverFileName: string): any;
393
+ DownloadFileFromServer(serverFileName: string): Promise<ArrayBuffer>;
394
+ /**
395
+ * Checks if the control is read-only
396
+ * @param controlId Id of control
397
+ * @returns Is the control not read-only
398
+ */
399
+ checkIsReadOnly(controlId: string): boolean;
400
+ /**
401
+ * Returns the text of the control
402
+ * @param controlId Id of control
403
+ * @param rowId Id of row, if applicable
404
+ * @returns The text of the control
405
+ */
406
+ getText(controlId: string, rowId?: string): string;
407
+ /**
408
+ * Gets the text of the tab page
409
+ * @param controlId Id of control
410
+ * @param layer Id of tabpage
411
+ * @returns Text of tabpage
412
+ */
413
+ getTabpageText(controlId: string, layer: number): string;
414
+ /**
415
+ * Gets the image defined for the control
416
+ * @param controlId Id of control
417
+ * @param rowId Id of row, if applicable
418
+ * @returns Image set on control
419
+ */
420
+ getImage(controlId: string, rowId?: string): string;
421
+ /**
422
+ * Returns whether an image is set for this control
423
+ * @param controlId Id of control
424
+ * @param rowId Id of row, if applicable
425
+ * @returns returns true if control has an image set on it
426
+ */
427
+ isImageExists(controlId: string, rowId?: string): boolean;
428
+ /**
429
+ * Gets the CSS classes set on the control
430
+ * @param controlId Id of control
431
+ * @param rowId Id of row, if applicable
432
+ * @returns The classes for this control
433
+ */
434
+ getClasses(controlId: string, rowId?: string): string;
435
+ /**
436
+ * Gets the CSS styles set on the control
437
+ * @param controlId Id of control
438
+ * @param styleName NAme of style requested
439
+ * @param rowId Id of row, if applicable
440
+ * @returns The style set on the control
441
+ */
442
+ getStyle(controlId: string, styleName: string, rowId?: string): string;
443
+ /**
444
+ * Returns whether a control is visible or not
445
+ * @param controlId Id of control
446
+ * @param rowId Id of row, if applicable
447
+ * @returns Is the control visible or hidden
448
+ */
449
+ getVisible(controlId: string, rowId?: string): string;
450
+ /**
451
+ * Returns whether a control is visible or not
452
+ * @param controlId Id of control
453
+ * @param rowId Id of row, if applicable
454
+ * @returns true if the control is visible, false otherwise
455
+ */
456
+ isVisible(controlId: string, rowId?: string): boolean;
457
+ /**
458
+ * Returns alpha mask of a control
459
+ * @param controlId Id of control
460
+ * @param rowId Id of row, if applicable
461
+ * @returns alpha mask of the control
462
+ */
463
+ getAlphaMask(controlId: string, rowId?: string): string;
464
+ /**
465
+ * Returns object representing numeric picture
466
+ * @param picture string which is defined in magic
467
+ * @returns object representing numeric picture
468
+ */
469
+ getNumericPicture(picture: string): any;
470
+ /**
471
+ * Returns whether a control should have the "required" attribute set on it
472
+ * @param controlId Id of control
473
+ * @param rowId Id of row, if applicable
474
+ * @returns
475
+ */
476
+ getMustInput(controlId: string, rowId?: string): string;
477
+ /**
478
+ * Returns whether a control is disabled
479
+ * @param controlId Id of control
480
+ * @param rowId Id of row, if applicable
481
+ * @returns
482
+ */
483
+ isDisabled(controlId: string, rowId?: string): any;
484
+ /**
485
+ * @ignore
486
+ */
487
+ getProperty(controlId: string, prop: HtmlProperties, rowId?: string): any;
488
+ /**
489
+ * Returns the title (tooltip) text of the control
490
+ * @param controlId Id of control
491
+ * @param rowId Id of row, if applicable
492
+ * @returns
493
+ */
494
+ getTitle(controlId: string, rowId?: string): string;
495
+ /**
496
+ * Returns the title (tooltip) text of the control
497
+ * @param controlId Id of control
498
+ * @param rowId Id of row, if applicable
499
+ * @returns
500
+ */
501
+ getZoomButtonTitle(controlId: string, rowId?: string): string;
502
+ /**
503
+ * Gets the selection control's selected value
504
+ * @param controlId Id of control
505
+ * @param rowId Id of row, if applicable
506
+ * @returns
507
+ */
508
+ getSelectedValue(controlId: string, rowId?: string): string;
509
+ /**
510
+ * Gets the place-holder text of the control
511
+ * @param controlId Id of control
512
+ * @param rowId Id of row, if applicable
513
+ * @returns
514
+ */
515
+ getPlaceholder(controlId: string, rowId?: string): string;
516
+ /**
517
+ * Returns a type for input controls - should the control be a simple text or a password control
518
+ * @param controlId Id of control
519
+ * @param rowId Id of row, if applicable
520
+ * @returns
521
+ */
522
+ getType(controlId: string, rowId?: string): string;
523
+ /**
524
+ * Returns the tab-index of the control
525
+ * @param controlId Id of control
526
+ * @param rowId Id of row, if applicable
527
+ * @returns
528
+ */
529
+ getTabIndex(controlId: string, rowId?: string): number;
530
+ /**
531
+ * Returns the value of the control
532
+ * @param controlId Id of control
533
+ * @param rowId Id of row, if applicable
534
+ * @returns
535
+ */
536
+ getValue(controlId: string, rowId?: string): any;
537
+ /**
538
+ * Returns the formatted value of the control
539
+ * @param controlId Id of control
540
+ * @param rowId Id of row, if applicable
541
+ * @returns
542
+ */
543
+ getFormattedValue(controlId: string, rowId?: string): string;
544
+ /**
545
+ * Returns the Picture of the control
546
+ * @param controlId Id of control
547
+ * @param rowId Id of row, if applicable
548
+ * @returns
549
+ */
550
+ getPicture(controlId: string, rowId?: string): string;
551
+ /**
552
+ * Returns the custom (user) properties of the control
553
+ * @param controlId Id of control
554
+ * @param propertyName Name of requested property
555
+ * @param rowId Id of row, if applicable
556
+ * @returns
557
+ */
558
+ getCustomProperty(controlId: string, propertyNameOrRowID?: string, rowId?: string): any;
559
+ getCustomProperty_1(controlId: string, propertyName: string, rowId?: string): any;
560
+ /**
561
+ * Gets the values of the items of a selection control
562
+ * @param id Id of control
563
+ * @param rowId Id of row, if applicable
564
+ * @returns
565
+ */
566
+ getItemListValues(id: string, rowId?: string): Array<{
567
+ index: number;
568
+ displayValue: string;
569
+ }>;
570
+ /**
571
+ * Gets the filtered items list based on the current value of the control
572
+ * @param controlId Id of control
573
+ * @param rowId Id of row, if applicable
574
+ * @returns
575
+ */
576
+ getFilteredList(controlId: string, rowId?: string): Array<{
577
+ index: number;
578
+ displayValue: string;
579
+ }>;
580
+ /**
581
+ * Gets the display value of the item from items of a selection control
582
+ * @param id Id of control
583
+ * @param rowId Id of row, if applicable
584
+ * @returns
585
+ */
586
+ getDisplayValue(id: any, rowId?: any): string;
587
+ /**
588
+ * Returns whether a tab page is selected or not
589
+ * @param index of current option in iterarotr
590
+ * @param control Id of list control
591
+ * @returns
592
+ */ isOptionSelected(index: any, controlId: any): boolean;
593
+ /**
594
+ * Returns whether a tab page is selected or not - used for the tab buttons
595
+ * @param controlId Id of control
596
+ * @param layer Id of the tab page
597
+ * @returns
598
+ */ isTabPageSelected(controlId: string, layer: number): boolean;
599
+ /**
600
+ * Returns whether a tab page layer is selected or not - used for the div which represents the tab page
601
+ * @param controlId Id of control
602
+ * @param layer Id of the tab page
603
+ * @returns
604
+ */ isTabPageLayerSelected(controlId: string, layer: number): boolean;
605
+ /**
606
+ * Returns the index of the selected tab page
607
+ * @param controlId Id of control
608
+ * @returns
609
+ */
610
+ getTabSelectedIndex(controlId: string): any;
611
+ /**
612
+ * @ignore
613
+ */
614
+ ifRowCreated(row: any): boolean;
615
+ /**
616
+ * @ignore
617
+ */
618
+ getFormGroupByRow(id: string): FormGroup;
619
+ /**
620
+ * @ignore
621
+ */
622
+ isRowSelected(controlId: any, rowId?: any): boolean;
623
+ /**
624
+ * Returns whether a row is in edit state
625
+ * @param row
626
+ */
627
+ isRowInRowEditing(row?: any): boolean;
628
+ /**
629
+ * Returns whether a row is in edit state, use this method while control outside table control
630
+ * @param row
631
+ */
632
+ isCurrentInRowEditing(): boolean;
633
+ /**
634
+ * @ignore
635
+ */
636
+ guiTopIndex(): number;
637
+ /**
638
+ * @ignore
639
+ */
640
+ getErrMsg(id: string, rowId: string): string;
641
+ private getNumericFormatErrorString;
642
+ /**
643
+ * Sets a user-supplied value to the specified control
644
+ * @param controlName
645
+ * @param value
646
+ * @param refreshDisplay
647
+ */
648
+ setValueToControl(controlName: string, value: any, refreshDisplay?: boolean): void;
649
+ /**
650
+ * @ignore
651
+ */
652
+ isDataviewEmpty(): boolean;
653
+ /**
654
+ * simulates a click event on the specified control, for the Magic engine
655
+ * @param controlName
656
+ * @param rowId
657
+ */
658
+ simulateClick(controlName: string, rowId?: number): void;
659
+ /**
660
+ * Return Boolean TRUE if user logged in Else it will return FALSE
661
+ */
662
+ isLoggedIn(): boolean;
663
+ /**
664
+ * Returns JS object containing the records with all table fields.
665
+ */
666
+ GetFormRecords(): any;
667
+ /**
668
+ * SetCookie : set the cookie with specified name and value in browser
669
+ * expires - expiration time
670
+ * path - path which much exists in order so that cookie is sent as header
671
+ * domain - specifies which hosts are allowed to receive the cookie
672
+ * secure - specifies if cookie is secure ( works only with HTTPS)
673
+ * sameSite - lets servers specify whether/when cookies are sent with cross-site requests
674
+ */
675
+ SetCookie(name: string, value: any, expires?: Date, path?: any, domain?: any, secure?: any, sameSite?: any): void;
676
+ /**
677
+ * GetCookie : get the cookie with specified name and value in browser
678
+ */
679
+ GetCookie(name: string): any;
680
+ /**
681
+ * DeleteCookie : deletes the cookie
682
+ */
683
+ DeleteCookie(name: string): any;
684
+ /**
685
+ * get RGBA color from color file
686
+ */
687
+ getColor(colorNumber: number, colorType: any): any;
688
+ static ɵfac: i0.ɵɵFactoryDeclaration<AccessorMagicService, never>;
689
+ static ɵprov: i0.ɵɵInjectableDeclaration<any>;
690
+ }
691
+
692
+ /**
693
+ * Main service to connect the UI with the Magic WebCLient
694
+ */
695
+ declare class TaskMagicService {
696
+ /**
697
+ * Service to provide table-related functionalities
698
+ */
699
+ tableService: any;
700
+ /**
701
+ * Collection of data for all controls
702
+ */
703
+ Records: any;
704
+ /**
705
+ * FormGroup collection for line mode
706
+ */
707
+ formGroups: Array<FormGroup>;
708
+ /**
709
+ * FormGroup for all controls in screen mode
710
+ */
711
+ ScreenModeControls: FormGroup;
712
+ /**
713
+ * @ignore
714
+ */
715
+ refreshDom: Subject<GuiCommand>;
716
+ /**
717
+ * @ignore
718
+ */
719
+ subscribeRefreshDom: Subscription;
720
+ /**
721
+ * @ignore
722
+ */
723
+ detectChanges: Subject<any>;
724
+ /**
725
+ * @ignore
726
+ */
727
+ subscribeInteractiveCommands: Subscription;
728
+ /**
729
+ * @ignore
730
+ */
731
+ interactiveCommands: Subject<GuiInteractive>;
732
+ /**
733
+ * @ignore
734
+ * This event is emitted when the selected row in a table changes.
735
+ */
736
+ OnSelectedRowChanged: EventEmitter<string>;
737
+ /**
738
+ * @ignore
739
+ */
740
+ customPropertiesSubject: Subject<any>;
741
+ /**
742
+ * @ignore
743
+ */
744
+ recordsCountChangeSubject: Subject<any>;
745
+ mgLoadSubject: Subject<any>;
746
+ /**
747
+ * @ignore
748
+ */
749
+ template: {
750
+ [id: string]: string;
751
+ };
752
+ /**
753
+ * Service to provide subform-related functionalities
754
+ */
755
+ mgSubformService: SubformMagicService;
756
+ /**
757
+ * Service to provide the title-change functionality
758
+ */
759
+ mgTitleService: TitleMagicService;
760
+ /**
761
+ * Service which enables getting/setting values from/to the Magic WebClient engine
762
+ */
763
+ mgAccessorService: AccessorMagicService;
764
+ mgInputDateFormat: any;
765
+ /**
766
+ * @ignore
767
+ */
768
+ oldPageSize: number;
769
+ protected magic: EngineMagicService;
770
+ private overlayWindowService;
771
+ constructor();
772
+ /**
773
+ * returns true if used is logged in
774
+ * @returns
775
+ */
776
+ getIsLoggenIn(): boolean;
777
+ /**
778
+ * Id of task to which this service refers
779
+ */
780
+ _taskId: string;
781
+ /**
782
+ * returns the task Id
783
+ * @returns
784
+ */
785
+ get taskId(): string;
786
+ /**
787
+ * Sets the task Id
788
+ * @param value the task id to set
789
+ */
790
+ set taskId(value: string);
791
+ /**
792
+ * Returns the task's data in Screen mode
793
+ * @returns
794
+ */
795
+ get ScreenControlsData(): any;
796
+ /**
797
+ * @ignore
798
+ */
799
+ settemplate(value: any): void;
800
+ /**
801
+ * Builds the FormControl for each and every control
802
+ */
803
+ buildScreenModeControls(): void;
804
+ /**
805
+ * Is the control a table control
806
+ * @param id Id of the control
807
+ * @returns
808
+ */
809
+ isTableControl(id: string): boolean;
810
+ getMgInputDateFormat(): string;
811
+ /**
812
+ * Returns the FormControl of a control
813
+ * @param guiRowid Id of the requested row
814
+ * @param id Id of the control
815
+ * @returns
816
+ */
817
+ getFormControl(guiRowid: string, id: string): AbstractControl;
818
+ /**
819
+ * handle the change of text for input control inside table
820
+ * @param guiRowId Id of the row for which the FormControls are built
821
+ * set the new value of the formcontrol
822
+ */
823
+ setInputTextValue(controlId: string, guiRowid: string, val: any): void;
824
+ /**
825
+ * Build the FormControls for a table row
826
+ * @param guiRowId Id of the row for which the FormControls are built
827
+ */
828
+ buildTableRowControls(guiRowId: number): void;
829
+ /**
830
+ *
831
+ * @ignore
832
+ */
833
+ updateRecordsBeforeCurrentView(value: number): void;
834
+ /**
835
+ * @ignore
836
+ */
837
+ setIncludesFirst(value: boolean): void;
838
+ /**
839
+ * @ignore
840
+ */
841
+ setIncludesLast(value: boolean): void;
842
+ /**
843
+ * @ignore
844
+ */
845
+ markRowAsCreated(guiRowId: number): void;
846
+ /**
847
+ * @ignore
848
+ */
849
+ markRowAsNotCreated(guiRowId: number): void;
850
+ /**
851
+ * @ignore
852
+ */
853
+ startRowEditing(guiRowId: number): void;
854
+ /**
855
+ * @ignore
856
+ */
857
+ stopRowEditing(guiRowId: number): void;
858
+ /**
859
+ * @ignore
860
+ */
861
+ isRowInRowEditing(guiRowId: string): boolean;
862
+ /**
863
+ * @ignore
864
+ */
865
+ setIsEmptyDataView(isEmpty: boolean): void;
866
+ /**
867
+ * Initialize the service to work with the task
868
+ * @param taskId Id of the task
869
+ * @param taskDescription
870
+ */
871
+ initTask(taskId: any, taskDescription: any): void;
872
+ /**
873
+ * @ignore
874
+ */
875
+ refreshView(): void;
876
+ /**
877
+ * Insert an event to the Magic WebClient event queue
878
+ * @param guiEvent The event to insert
879
+ */
880
+ insertEvent(guiEvent: IGuiEvent): void;
881
+ /**
882
+ * @ignore
883
+ */
884
+ GetControlPictureMask(controlName: string): any;
885
+ /**
886
+ * @ignore
887
+ */
888
+ UploadFileToServer(fileContent: any, serverFileName: string): any;
889
+ DownloadFileFromServer(serverFileName: string): Promise<ArrayBuffer>;
890
+ /**
891
+ * Validates the control value, using the Magic WebClient
892
+ * @param controlName Id of validated control
893
+ * @param value value to be validated
894
+ * @returns If validation fails, returns error message, else returns null
895
+ */
896
+ ValidateControlValue(controlName: string, value: any): string;
897
+ /**
898
+ * @ignore
899
+ */
900
+ GetRangedValue(controlName: string, value: string): string;
901
+ /**
902
+ * @ignore
903
+ */
904
+ GetFldRanges(controlName: string): string;
905
+ /**
906
+ * returns the value of a property of the control
907
+ * @param controlId Id of control
908
+ * @param prop Property
909
+ * @param guiRowId Row Id, if applicable
910
+ * @returns Property value
911
+ */
912
+ getProperty(controlId: string, prop: HtmlProperties, guiRowId?: string): any;
913
+ /**
914
+ * @ignore
915
+ */
916
+ getPropertyStub(ControlsProperties: any, controlId: any, prop: any): any;
917
+ /**
918
+ * @ignore
919
+ */
920
+ getStyleStub(ControlsProperties: any, controlId: any, styleName: string): any;
921
+ /**
922
+ * Return the CSS classes used for this control
923
+ * @param controlId Id of control
924
+ * @param guiRowId Row Id, if applicable
925
+ * @returns String containing the classes currently defined for this control
926
+ */
927
+ getClasses(controlId: string, guiRowId?: string): string;
928
+ /**
929
+ * Return the value of a style used for a control
930
+ * @param controlId Id of control
931
+ * @param styleName Name of style
932
+ * @param guiRowId Row Id, if applicable
933
+ * @returns value of style of the control
934
+ */
935
+ getStyle(controlId: string, styleName: string, guiRowId?: string): string;
936
+ /**
937
+ * Return the value of a control
938
+ * @param controlId Id of control
939
+ * @param guiRowId Row Id, if applicable
940
+ * @returns value of the control
941
+ */
942
+ getValue(controlId: string, guiRowId?: string): any;
943
+ /**
944
+ * Return the formatted value of a control
945
+ * @param controlId Id of control
946
+ * @param guiRowId Row Id, if applicable
947
+ * @returns value of the control
948
+ */
949
+ getFormattedValue(controlName: string, val: any, rowId?: string): string;
950
+ /**
951
+ * Sets the value of a control
952
+ * @param controlId Id of control
953
+ * @param guiRowId Row Id, if applicable
954
+ * @param value Value to set
955
+ */
956
+ setValue(controlId: string, guiRowId: string, value: any): void;
957
+ /**
958
+ * @ignore
959
+ */
960
+ protected executeInteractiveCommand(guiInteractiveCommand: GuiInteractive): void;
961
+ /**
962
+ * @ignore
963
+ */
964
+ handleSetProperty(command: GuiCommand, isTableChild: boolean): void;
965
+ executeCommand(command: GuiCommand): void;
966
+ /**
967
+ custom validator
968
+ */
969
+ customValidator(rowid: string, id: string): ValidatorFn;
970
+ /**
971
+ * COnvert a value from Magic format to native format
972
+ * @param controlId Id of control
973
+ * @param rowId Row Id, if applicable
974
+ * @param val Value to convert
975
+ * @returns Converted value
976
+ */
977
+ ConvertValToNative(controlId: string, rowId: number, val: any): any;
978
+ /**
979
+ * Convert a value from native to Magic format
980
+ * @param controlId Id of control
981
+ * @param rowId Row Id, if applicable
982
+ * @param val Value to convert
983
+ * @returns Converted value
984
+ */
985
+ ConvertValFromNative(controlId: string, rowId: number, val: any): any;
986
+ /**
987
+ * Handle resize and also fetch chunk of records if having an empty view.
988
+ * @ignore
989
+ * @param pageSize : PageSize
990
+ * @param topGuiRowId : GuiRowId of first record in view.
991
+ */
992
+ resize(pageSize: number, topGuiRowId: number): void;
993
+ /**
994
+ * Fetches data for new table rows when scrolling done
995
+ */
996
+ onScrollDown(): void;
997
+ /**
998
+ * Sets the new browser window title
999
+ * @param newTitle New window title
1000
+ */
1001
+ setTitle(newTitle: string): void;
1002
+ /**
1003
+ * @ignore
1004
+ */
1005
+ getGuiRowId(dvRowId: number, isTableControl: boolean): number;
1006
+ /**
1007
+ *
1008
+ * @ignore
1009
+ */
1010
+ getDvRowId(guiRowId: number): number;
1011
+ /**
1012
+ * Clean up the service when it is no longer needed
1013
+ */
1014
+ dispose(): void;
1015
+ /**
1016
+ * Handle the Combobox "change" event
1017
+ * @param event The event received from the UI
1018
+ * @param idx Id of the control raising the event
1019
+ * @param line Row Id, if applicable
1020
+ */
1021
+ onComboboxSelectionChanged(event: Event, idx: string, line: number): void;
1022
+ /**
1023
+ * Handle the Listbox "change" event
1024
+ * @param event The event received from the UI
1025
+ * @param idx Id of the control raising the event
1026
+ */
1027
+ onListBoxSelectionChanged(event: Event, idx: string): void;
1028
+ /**
1029
+ * Handle the Checkbox "change" event
1030
+ * @param event The event received from the UI
1031
+ * @param idx Id of the control raising the event
1032
+ * @param rowId Row Id, if applicable
1033
+ */
1034
+ onCheckChanged(event: Event, idx: string, rowId: number): void;
1035
+ /**
1036
+ * Handle tab selection change, caused by UI events
1037
+ * @param idx Id of the control raising the event
1038
+ * @param layer Id of selected tabpage
1039
+ */
1040
+ mgOnTabSelectionChanged(idx: string, layer: number): void;
1041
+ /**
1042
+ * Handle the Radio button "change" event
1043
+ * @param idx Id of the control raising the event
1044
+ * @param rowId Id of the row containing the control (defaults to '0' for non-table controls)
1045
+ */
1046
+ mgOnRadioSelectionChanged(idx: string, rowId?: string): void;
1047
+ /**
1048
+ * Inserts the "close" event to the magic WebClient event queue
1049
+ */
1050
+ close(): void;
1051
+ /**
1052
+ * @ignore
1053
+ */
1054
+ IsStub(): boolean;
1055
+ /**
1056
+ * @ignore
1057
+ */
1058
+ jsonData: string;
1059
+ /**
1060
+ * @ignore
1061
+ */
1062
+ saveData(data: string): void;
1063
+ /**
1064
+ * @ignore
1065
+ */
1066
+ createData(): void;
1067
+ /**
1068
+ * @ignore
1069
+ */
1070
+ loadStubData(stubData: any): void;
1071
+ /**
1072
+ * @ignore
1073
+ */
1074
+ loadData(): void;
1075
+ /**
1076
+ * @ignore
1077
+ */
1078
+ setStubValue(guiRowId: number, fc: FormControl, name: string): void;
1079
+ static ɵfac: i0.ɵɵFactoryDeclaration<TaskMagicService, never>;
1080
+ static ɵprov: i0.ɵɵInjectableDeclaration<any>;
1081
+ }
1082
+
1083
+ /**
1084
+ * Implements various table-related functionalities
1085
+ */
1086
+ declare class TableMagicService {
1087
+ selectedItem: any;
1088
+ private chunkSize;
1089
+ protected componentList: ComponentListMagicService;
1090
+ protected task: TaskMagicService;
1091
+ constructor();
1092
+ shouldOpenFieldTextEditor: boolean;
1093
+ /**
1094
+ * Refreshes the DataSource
1095
+ */
1096
+ refreshDataSource(): void;
1097
+ /**
1098
+ * Returns the table page size
1099
+ * chunkSize as default value for non-paginated tables.
1100
+ */
1101
+ getPageSize(): number;
1102
+ setChunkSize(size: number): void;
1103
+ /**
1104
+ * Returns max no of rows in the table.
1105
+ */
1106
+ getMaxRowsInTable(): number;
1107
+ /**
1108
+ * Selects the specified row
1109
+ * @param rowId The row to select
1110
+ */
1111
+ selectRow(rowId: string): void;
1112
+ getSelectedRow(): any;
1113
+ /**
1114
+ * Returns the selected row
1115
+ */
1116
+ selectedRow(): any;
1117
+ /**
1118
+ * Selects the specified page
1119
+ * @param pageId The page to select
1120
+ */
1121
+ selectPage(pageId: number): void;
1122
+ /**
1123
+ * Returns whether a dialog should be opened for the HTML element
1124
+ * @param element The HTML element for which a dialog may be needed
1125
+ * @returns
1126
+ */
1127
+ OpenDialogForControl(element: HTMLElement): boolean;
1128
+ /**
1129
+ * Returns the dialog used to edit values
1130
+ */
1131
+ getDialog(): any;
1132
+ /**
1133
+ * Handles the table "scrolled" event
1134
+ */
1135
+ onScrollDown(): void;
1136
+ /**
1137
+ * To be overwitten in specific implelemtations
1138
+ */
1139
+ sortData(e: any): void;
1140
+ /**
1141
+ * To be overwitten in specific implelemtations
1142
+ */
1143
+ mgOnPaginateChange(e: any, changeSelectedRow?: boolean): void;
1144
+ mgOptionChanged(e: any): void;
1145
+ /**
1146
+ * Change the number of lines in a table
1147
+ * @param size New number of lines in table
1148
+ */
1149
+ updateTableSize(size: number): void;
1150
+ /**
1151
+ * @ignore
1152
+ */
1153
+ setTableTopIndex(value: number): void;
1154
+ /**
1155
+ * @ignore
1156
+ */
1157
+ getTableTopIndex(): number;
1158
+ static ɵfac: i0.ɵɵFactoryDeclaration<TableMagicService, never>;
1159
+ static ɵprov: i0.ɵɵInjectableDeclaration<any>;
1160
+ }
1161
+
1162
+ /**
1163
+ * Central place for adding the Magic services
1164
+ */
1165
+ declare class MagicServices {
1166
+ task: TaskMagicService;
1167
+ subformService: SubformMagicService;
1168
+ tableService: TableMagicService;
1169
+ titleService: TitleMagicService;
1170
+ mgAccessorService: AccessorMagicService;
1171
+ /**
1172
+ * @ignore
1173
+ */
1174
+ constructor();
1175
+ static ɵfac: i0.ɵɵFactoryDeclaration<MagicServices, never>;
1176
+ static ɵprov: i0.ɵɵInjectableDeclaration<any>;
1177
+ }
1178
+
1179
+ /**
1180
+ * Base component representing a Magic task
1181
+ */
1182
+ declare class TaskBaseMagicComponent implements OnInit, OnDestroy, AfterViewInit {
1183
+ /**
1184
+ * Id of task, used for initializing the task service
1185
+ */
1186
+ taskIdParam: string;
1187
+ /**
1188
+ * @ignore
1189
+ */
1190
+ taskDescription: string;
1191
+ /**
1192
+ * @ignore
1193
+ */
1194
+ magicProperties: typeof MagicProperties;
1195
+ /**
1196
+ * @ignore
1197
+ * Injected as fields rather than constructor parameters, so that the constructor
1198
+ * signature of this base class - which every generated component inherits - is unchanged.
1199
+ */
1200
+ private readonly magicChangeDetection;
1201
+ /**
1202
+ * @ignore
1203
+ */
1204
+ private readonly destroyRef;
1205
+ protected ref: ChangeDetectorRef;
1206
+ magicServices: MagicServices;
1207
+ /**
1208
+ *
1209
+ * @param ref changes-detector object
1210
+ * @param magicServices Access point for all Magic services
1211
+ */
1212
+ constructor();
1213
+ /**
1214
+ * Returns the Magic task service
1215
+ * @returns
1216
+ */
1217
+ get task(): TaskMagicService;
1218
+ /**
1219
+ * Returns the Magic subform service
1220
+ * @returns
1221
+ */
1222
+ get mgSub(): SubformMagicService;
1223
+ /**
1224
+ * Returns the Magic table service
1225
+ * @returns
1226
+ */
1227
+ get tableService(): TableMagicService;
1228
+ /**
1229
+ * Returns the Magic accessor service
1230
+ * @returns
1231
+ */
1232
+ get mg(): AccessorMagicService;
1233
+ /**
1234
+ * Returns the task Id
1235
+ * @returns
1236
+ */
1237
+ get taskId(): string;
1238
+ /**
1239
+ * Returns the FormGroup for screen-mode forms
1240
+ * @returns
1241
+ */
1242
+ get screenFormGroup(): FormGroup;
1243
+ /**
1244
+ * Interface implementation
1245
+ */
1246
+ ngOnInit(): void;
1247
+ /**
1248
+ * @ignore
1249
+ */
1250
+ createFormControlsAccessor(formGroup: FormGroup): void;
1251
+ /**
1252
+ * @ignore
1253
+ */
1254
+ setInputDateFormat(): void;
1255
+ /**
1256
+ * This method is called when the value of any custom property is updated in Magic
1257
+ * propertyName : name of property which is updated. The format is <controlname>~<propertyname>
1258
+ * rowId : row number of the updated property for controls in table control (0 for controls outside table)
1259
+ * value : updated value of the property
1260
+ * @returns : void
1261
+ * To use the method override it in your component and check the property name and write you code ..for eg
1262
+ * if(propertyName == 'controlname~propertyName') {// your code}
1263
+ * else { // your code}
1264
+ */
1265
+ PropertyChanged(propertyName: string, rowId: number, value: any): void;
1266
+ /**
1267
+ * Records count change subject is subscribed to change in its value. This method will be called
1268
+ * as the value of records count is received at from server.
1269
+ * @returns : void
1270
+ * To use the method override it in your component.
1271
+ */
1272
+ RecordsCountChanged(recordsCount: number): void;
1273
+ /**
1274
+ * This method will be called once engine informs UI about loading of first set of data is sent to client
1275
+ * and client has reached its first idle time.
1276
+ * @returns : void
1277
+ * To use the method override it in your component.
1278
+ */
1279
+ mgOnLoad(): void;
1280
+ /**
1281
+ * Interface implementation
1282
+ */
1283
+ ngAfterViewInit(): void;
1284
+ ngAfterContentChecked(): void;
1285
+ /**
1286
+ * Interface implementation
1287
+ */
1288
+ ngOnDestroy(): void;
1289
+ static ɵfac: i0.ɵɵFactoryDeclaration<TaskBaseMagicComponent, never>;
1290
+ static ɵcmp: i0.ɵɵComponentDeclaration<TaskBaseMagicComponent, "task-magic", never, { "taskIdParam": { "alias": "taskIdParam"; "required": false; }; "taskDescription": { "alias": "taskDescription"; "required": false; }; }, {}, never, never, false, never>;
1291
+ }
1292
+
1293
+ /**
1294
+ * @ignore
1295
+ */
1296
+ declare class RowMagicDirective implements OnInit, OnDestroy {
1297
+ rowId: string;
1298
+ /**
1299
+ * The HTML element connected to this directive
1300
+ */
1301
+ protected htmlElement: HTMLElement;
1302
+ /**
1303
+ * @ignore
1304
+ */
1305
+ private rowChangedSubscriber;
1306
+ protected _task: TaskMagicService;
1307
+ protected element: ElementRef;
1308
+ constructor();
1309
+ /**
1310
+ * Initializes this object
1311
+ */
1312
+ ngOnInit(): void;
1313
+ private isInView;
1314
+ /**
1315
+ * Cleanup
1316
+ */
1317
+ ngOnDestroy(): void;
1318
+ onClick($event: any): void;
1319
+ static ɵfac: i0.ɵɵFactoryDeclaration<RowMagicDirective, never>;
1320
+ static ɵdir: i0.ɵɵDirectiveDeclaration<RowMagicDirective, "[magicRow]", never, { "rowId": { "alias": "magicRow"; "required": false; }; }, {}, never, never, false, never>;
1321
+ }
1322
+
1323
+ /**
1324
+ * Connects HTML elements to the Magic Web Client engine
1325
+ */
1326
+ declare class MagicDirective implements OnInit, OnDestroy {
1327
+ set magic(val: any);
1328
+ /**
1329
+ * This flag is used when we only want to register to events, but do not want to execute commands sent from server
1330
+ */
1331
+ set eventsOnly(val: any);
1332
+ /**
1333
+ * pollTime: after which value will be sent to magic
1334
+ */
1335
+ pollTime: number;
1336
+ /**
1337
+ * Row id of the control, for when it is on a table
1338
+ */
1339
+ rowId: string;
1340
+ /**
1341
+ *
1342
+ */
1343
+ /**
1344
+ * The HTML element connected to this directive
1345
+ */
1346
+ protected htmlElement: HTMLElement;
1347
+ /**
1348
+ * Magic's component handling this control
1349
+ */
1350
+ component: TaskBaseMagicComponent;
1351
+ /**
1352
+ * Collection of event handlers for this element
1353
+ */
1354
+ private eventHandlers;
1355
+ /**
1356
+ * Id of this element
1357
+ */
1358
+ id: string;
1359
+ /**
1360
+ * @ignore
1361
+ */
1362
+ protected selector: string;
1363
+ /**
1364
+ * @ignore
1365
+ */
1366
+ subscribeRefreshDom: Subscription;
1367
+ private focusUnlistener;
1368
+ eventsOnlyVal: boolean;
1369
+ static opened: boolean;
1370
+ static noOfAutoCompleteBoxesOpened: number;
1371
+ subscribeInteractiveCommands: Subscription;
1372
+ /**
1373
+ *
1374
+ * @param _task The task service
1375
+ * @param element The element for which the directive is applied
1376
+ * @param renderer Renderer for the element
1377
+ * @param vcRef
1378
+ * @param platform
1379
+ * @param magicRow
1380
+ */
1381
+ constructor();
1382
+ /**
1383
+ * Get the task service
1384
+ * @returns
1385
+ */
1386
+ get task(): TaskMagicService;
1387
+ protected _task: TaskMagicService;
1388
+ protected element: ElementRef;
1389
+ protected renderer: Renderer2;
1390
+ protected vcRef: ViewContainerRef;
1391
+ platform: Platform;
1392
+ protected magicRow: RowMagicDirective;
1393
+ /**
1394
+ * Register to the events this element may need to handle
1395
+ */
1396
+ protected regEvents(): void;
1397
+ /**
1398
+ * Handle focus event
1399
+ */
1400
+ private OnFocus;
1401
+ /**
1402
+ * Is the command's element the same as this directive's element
1403
+ * @param command
1404
+ * @returns true/false
1405
+ */
1406
+ IsSameElement(command: any): boolean;
1407
+ /**
1408
+ * Is the command's element the same as this directive's component
1409
+ * @param command
1410
+ * @returns true/false
1411
+ */
1412
+ private IsSameComponent;
1413
+ /**
1414
+ * @ignore
1415
+ */
1416
+ private regUpdatesUI;
1417
+ /**
1418
+ * Initializes this object
1419
+ */
1420
+ ngOnInit(): void;
1421
+ /**
1422
+ * Handles the commands received from the Magic WebClient engine
1423
+ * @param command
1424
+ */
1425
+ handleCommand(command: GuiCommand): void;
1426
+ /**
1427
+ * handle the interactive commands like CallJS
1428
+ */
1429
+ handleInteractiveCommands(command: GuiInteractive): void;
1430
+ /**
1431
+ * Handle the Magic set-property command
1432
+ * @param command
1433
+ */
1434
+ handleSetProperty(command: GuiCommand): void;
1435
+ /**
1436
+ * Cleanup
1437
+ */
1438
+ ngOnDestroy(): void;
1439
+ static ɵfac: i0.ɵɵFactoryDeclaration<MagicDirective, never>;
1440
+ static ɵdir: i0.ɵɵDirectiveDeclaration<MagicDirective, "[magic]", never, { "magic": { "alias": "magic"; "required": false; }; "eventsOnly": { "alias": "eventsOnly"; "required": false; }; "pollTime": { "alias": "pollTime"; "required": false; }; "rowId": { "alias": "rowId"; "required": false; }; }, {}, never, never, false, never>;
1441
+ }
1442
+
1443
+ /**
1444
+ * Directive for checkboxes, to handle the 'change' event
1445
+ */
1446
+ declare class CheckboxMagicDirective {
1447
+ threeState: i0.InputSignal<boolean>;
1448
+ private subscribeRefreshDom;
1449
+ private isIndeterminate;
1450
+ protected magicDirective: MagicDirective;
1451
+ private el;
1452
+ protected task: TaskMagicService;
1453
+ constructor();
1454
+ /**
1455
+ * Handles the Checkbox 'change' event - pass it to the Magic engine
1456
+ */
1457
+ onChange($event: any): void;
1458
+ ngOnInit(): void;
1459
+ private regUpdatesUI;
1460
+ handleCommand(command: GuiCommand): void;
1461
+ private handleThreeState;
1462
+ /**
1463
+ * Cleanup
1464
+ */
1465
+ ngOnDestroy(): void;
1466
+ static ɵfac: i0.ɵɵFactoryDeclaration<CheckboxMagicDirective, never>;
1467
+ static ɵdir: i0.ɵɵDirectiveDeclaration<CheckboxMagicDirective, " input[type=checkbox][magic]:not([noFormControl])", never, { "threeState": { "alias": "threeState"; "required": false; "isSignal": true; }; }, {}, never, never, false, never>;
1468
+ }
1469
+
1470
+ /**
1471
+ * Directive for checkboxes which should not have a form control
1472
+ */
1473
+ declare class CheckboxNoFormControlMagicDirective {
1474
+ protected magicDirective: MagicDirective;
1475
+ constructor();
1476
+ /**
1477
+ * Handle the 'Checkbox' change event - pass it to the Magic engine
1478
+ */
1479
+ onChange($event: any): void;
1480
+ static ɵfac: i0.ɵɵFactoryDeclaration<CheckboxNoFormControlMagicDirective, never>;
1481
+ static ɵdir: i0.ɵɵDirectiveDeclaration<CheckboxNoFormControlMagicDirective, " input[type=checkbox][magic]:([noFormControl]) ", never, {}, {}, never, never, false, never>;
1482
+ }
1483
+
1484
+ /**
1485
+ * Directive for non-checkbox input controls which do not have a form control
1486
+ */
1487
+ declare class InputNoFormControlMagicDirective {
1488
+ protected magicDirective: MagicDirective;
1489
+ constructor();
1490
+ /**
1491
+ * Handles the 'change' event - pass it to the Magic engine
1492
+ */
1493
+ onChange($event: any): void;
1494
+ static ɵfac: i0.ɵɵFactoryDeclaration<InputNoFormControlMagicDirective, never>;
1495
+ static ɵdir: i0.ɵɵDirectiveDeclaration<InputNoFormControlMagicDirective, "input[magic]:([noFormControl]):not([type=checkbox]), textarea[magic]:([noFormControl]):not([type=checkbox])", never, {}, {}, never, never, false, never>;
1496
+ }
1497
+
1498
+ /**
1499
+ * Directive for comboboxes, to handle the 'change' event
1500
+ */
1501
+ declare class ComboboxMagicDirective {
1502
+ protected magicDirective: MagicDirective;
1503
+ constructor();
1504
+ /**
1505
+ * Handles the Combobox 'change' event - pass it to the Magic engine
1506
+ */
1507
+ onChange($event: any): void;
1508
+ /**
1509
+ * To refresh Combobox selection as per selected property.
1510
+ */
1511
+ onComboboxItemsListChanged(): void;
1512
+ static ɵfac: i0.ɵɵFactoryDeclaration<ComboboxMagicDirective, never>;
1513
+ static ɵdir: i0.ɵɵDirectiveDeclaration<ComboboxMagicDirective, "select[magic]:not([multiple])", never, {}, {}, never, never, false, never>;
1514
+ }
1515
+
1516
+ /**
1517
+ * @ignore
1518
+ */
1519
+ declare const CHECKBOX_VALUE_ACCESSOR: any;
1520
+ /**
1521
+ * Value accessor for Checkbox without a FormControl
1522
+ */
1523
+ declare class MagicCheckboxControlValueAccessor extends CheckboxControlValueAccessor {
1524
+ static ɵfac: i0.ɵɵFactoryDeclaration<MagicCheckboxControlValueAccessor, never>;
1525
+ static ɵdir: i0.ɵɵDirectiveDeclaration<MagicCheckboxControlValueAccessor, " input[type=checkbox][magic]:not([formControlName]):not([no-form-control]), input[type=checkbox][magic]:not([formControl]), input[type=checkbox][magic]:not([ngModel]) ", never, {}, {}, never, never, false, never>;
1526
+ }
1527
+
1528
+ /**
1529
+ * @ignore
1530
+ */
1531
+ declare const MAGIC_DEFAULT_VALUE_ACCESSOR: any;
1532
+ /**
1533
+ * @ignore
1534
+ */
1535
+ declare class MagicDefaultValueAccessor extends DefaultValueAccessor {
1536
+ static ɵfac: i0.ɵɵFactoryDeclaration<MagicDefaultValueAccessor, never>;
1537
+ static ɵdir: i0.ɵɵDirectiveDeclaration<MagicDefaultValueAccessor, " input[magic]:not([type=checkbox]):not([formControlName]):not([no-form-control]), textarea[magic]:not([formControlName]):not([noFormControl]):not([no-form-control]) ", ["magic"], {}, {}, never, never, false, never>;
1538
+ }
1539
+
1540
+ declare const DATE_VALUE_ACCESSOR: any;
1541
+ /**
1542
+ * The accessor for writing a value and listening to changes on a date input element
1543
+ *
1544
+ * ### Example
1545
+ * `<input type="date" name="birthday" ngModel dateInput>`
1546
+ * OR
1547
+ * `<input type="date" formControlName="birthday" dateInput>`
1548
+ */
1549
+ declare class DateValueAccessor implements ControlValueAccessor {
1550
+ onChange: (_: any) => void;
1551
+ onTouched: () => void;
1552
+ onBlurEvent(event: any): void;
1553
+ private renderer;
1554
+ private elementRef;
1555
+ protected magicDir: MagicDirective;
1556
+ protected _task: TaskMagicService;
1557
+ constructor();
1558
+ /** Format year, if user enters 2 digits instead of 4 digits as per the century given in Magic.ini file */
1559
+ formatDateWithCentury(userInput: string, century: number, control: AbstractControl): void;
1560
+ /** Writes a new value to the element (model -> view) */
1561
+ writeValue(value: Date): void;
1562
+ /** Registers a callback function, called when value changes (view -> model) */
1563
+ registerOnChange(fn: (_: any) => void): void;
1564
+ /** Registers a callback function, called when the control is blurred */
1565
+ registerOnTouched(fn: () => void): void;
1566
+ /** Enables or disables the element when the control status changes */
1567
+ setDisabledState(isDisabled: boolean): void;
1568
+ static ɵfac: i0.ɵɵFactoryDeclaration<DateValueAccessor, never>;
1569
+ static ɵdir: i0.ɵɵDirectiveDeclaration<DateValueAccessor, "[dateInput]", never, {}, {}, never, never, false, never>;
1570
+ }
1571
+
1572
+ /**
1573
+ * Describes the behavior of a modal window
1574
+ */
1575
+ interface MagicModalInterface {
1576
+ /**
1577
+ * Returns the X coordinate of the modal window
1578
+ */
1579
+ X(): any;
1580
+ /**
1581
+ * Returns the Y coordinate of the modal window
1582
+ */
1583
+ Y(): any;
1584
+ /**
1585
+ * Returns the width of modal window
1586
+ */
1587
+ Width(): string;
1588
+ /**
1589
+ * Returns the height of modal window
1590
+ */
1591
+ Height(): string;
1592
+ /**
1593
+ * Is the modal window centered relatively to the main window
1594
+ */
1595
+ IsCenteredToWindow(): any;
1596
+ /**
1597
+ * Returns the name of the form - title of the modal window
1598
+ */
1599
+ FormName(): any;
1600
+ /**
1601
+ * Should the title bar be displayed
1602
+ */
1603
+ ShowTitleBar(): any;
1604
+ /**
1605
+ * Should the modal window close when the user clicks on the background
1606
+ */
1607
+ ShouldCloseOnBackgroundClick(): any;
1608
+ /**
1609
+ * Is overlay window resizable
1610
+ */
1611
+ IsResizable(): any;
1612
+ /**
1613
+ * Is overlay window movable
1614
+ */
1615
+ IsMovable(): any;
1616
+ }
1617
+
1618
+ /**
1619
+ * Abstract base for Magic overlay container components.
1620
+ * Concrete classes must implement these members using Angular signal APIs (input/output).
1621
+ * The class is kept as an abstract class (not an interface) so that instanceof checks
1622
+ * in MagicOverlayContainerWrapper continue to work at runtime.
1623
+ */
1624
+ declare abstract class BaseMagicOverlayContainer {
1625
+ /**
1626
+ * The component class to render inside the overlay
1627
+ */
1628
+ abstract ModalComp: any;
1629
+ /**
1630
+ * Parameters to pass to the rendered component
1631
+ */
1632
+ abstract ModalCompParameters: any;
1633
+ /**
1634
+ * Output event emitted when the overlay is closed
1635
+ */
1636
+ abstract onClose: any;
1637
+ }
1638
+
1639
+ /**
1640
+ * Creates a modal window for Magic modal window components
1641
+ */
1642
+ declare class MagicOverlayContainer extends BaseMagicOverlayContainer implements OnInit, AfterViewInit, IMagicViewContainerRef {
1643
+ /**
1644
+ * HTML to be displayed in the modal window
1645
+ */
1646
+ modalbodyViewContainerRef: ViewContainerRef;
1647
+ /**
1648
+ * Header of the modal window
1649
+ */
1650
+ headerElementRef: ElementRef;
1651
+ /**
1652
+ * Foreground of the modal window
1653
+ */
1654
+ foregroundElementRef: ElementRef;
1655
+ /**
1656
+ *
1657
+ */
1658
+ ModalComp: any;
1659
+ /**
1660
+ *
1661
+ */
1662
+ ModalCompParameters: any;
1663
+ onClose: EventEmitter<void>;
1664
+ /**
1665
+ *
1666
+ */
1667
+ private componentRef;
1668
+ private resizing;
1669
+ private resizeDirection;
1670
+ private originalWidth;
1671
+ private originalHeight;
1672
+ private originalMouseX;
1673
+ private originalMouseY;
1674
+ private isCenteredToWindow;
1675
+ private static readonly minAllowedWidth;
1676
+ private static readonly minAllowedHeight;
1677
+ private _isRtl;
1678
+ /**
1679
+ *
1680
+ */
1681
+ constructor();
1682
+ /**
1683
+ *
1684
+ */
1685
+ ngOnInit(): void;
1686
+ ngAfterViewInit(): void;
1687
+ setViewContainerRef(vcRef: ViewContainerRef): void;
1688
+ /**
1689
+ * Returns the form name
1690
+ * @returns
1691
+ */
1692
+ getText(): any;
1693
+ /**
1694
+ * Returns boolean to indicate whether the text direction is right-to-left (RTL)
1695
+ */
1696
+ get isRtl(): boolean;
1697
+ /**
1698
+ * Returns CSS styles for the window
1699
+ * @returns
1700
+ */
1701
+ getStyle(): {};
1702
+ /**
1703
+ * Returns the CSS styles for the client area
1704
+ * @returns
1705
+ */
1706
+ getClientAreaStyles(): {};
1707
+ /**
1708
+ * Should the title bar be displayed
1709
+ * @returns
1710
+ */
1711
+ getShowTitleBar(): any;
1712
+ /**
1713
+ *
1714
+ */
1715
+ OnClose(): void;
1716
+ /**
1717
+ * Handles click in the background window
1718
+ */
1719
+ OnBackgroundClick(): void;
1720
+ /**
1721
+ * Checks if the overlay component allows to be resized.
1722
+ * @returns {boolean} True if the overlay is resizable, false otherwise.
1723
+ */
1724
+ IsResizable(): any;
1725
+ /**
1726
+ * Checks if the overlay component allows to be moved (dragged).
1727
+ * @returns {boolean} True if the overlay is movable, false otherwise.
1728
+ */
1729
+ IsMovable(): any;
1730
+ /**
1731
+ * Initiates the resize process when a mousedown event occurs on a resize handle.
1732
+ * Stores the initial state (dimensions, mouse position) and sets flags.
1733
+ * @param {MouseEvent} event - The mousedown event triggering the resize.
1734
+ * @param {'right' | 'bottom' | 'corner'} direction - Indicates which resize handle was activated.
1735
+ */
1736
+ onResizeStart(event: MouseEvent, direction: 'right' | 'left' | 'bottom' | 'corner'): void;
1737
+ /**
1738
+ * Handles the resizing logic as the mouse moves across the window.
1739
+ * This listener is active globally on the window during a resize operation via @HostListener.
1740
+ * Calculates and applies the new dimensions to the element based on mouse movement.
1741
+ * @param {MouseEvent} event - The mousemove event passed by the HostListener.
1742
+ */
1743
+ onResize(event: MouseEvent): void;
1744
+ /**
1745
+ * Finalizes the resize operation when the mouse button is released anywhere on the window.
1746
+ * Resets the resizing state flags. Triggered globally via @HostListener.
1747
+ */
1748
+ onResizeEnd(): void;
1749
+ getOverlayProps(): MagicModalInterface;
1750
+ static ɵfac: i0.ɵɵFactoryDeclaration<MagicOverlayContainer, never>;
1751
+ static ɵcmp: i0.ɵɵComponentDeclaration<MagicOverlayContainer, "app-magic-overlay-container", never, { "ModalComp": { "alias": "ModalComp"; "required": false; }; "ModalCompParameters": { "alias": "ModalCompParameters"; "required": false; }; }, { "onClose": "onClose"; }, never, never, false, never>;
1752
+ }
1753
+
1754
+ /**
1755
+ * This is a base class for the magic alert components
1756
+ */
1757
+ declare class BaseMagicAlertComponent {
1758
+ /**
1759
+ * title of the component
1760
+ */
1761
+ title: string;
1762
+ /**
1763
+ * message of the component
1764
+ */
1765
+ message: string;
1766
+ /**
1767
+ * onClose Event - to be raised when the component is closed
1768
+
1769
+ */
1770
+ onClose: EventEmitter<void>;
1771
+ /**
1772
+ * close magic alert
1773
+ */
1774
+ OnClose(): void;
1775
+ static ɵfac: i0.ɵɵFactoryDeclaration<BaseMagicAlertComponent, never>;
1776
+ static ɵcmp: i0.ɵɵComponentDeclaration<BaseMagicAlertComponent, "mg-base-alert", never, { "title": { "alias": "title"; "required": false; }; "message": { "alias": "message"; "required": false; }; }, { "onClose": "onClose"; }, never, never, false, never>;
1777
+ }
1778
+
1779
+ /***
1780
+ * This is sample component for the alert message
1781
+ */
1782
+ declare class MagicAlertComponent extends BaseMagicAlertComponent {
1783
+ static ɵfac: i0.ɵɵFactoryDeclaration<MagicAlertComponent, never>;
1784
+ static ɵcmp: i0.ɵɵComponentDeclaration<MagicAlertComponent, "sample-magic-alert-component", never, {}, {}, never, never, false, never>;
1785
+ }
1786
+
1787
+ /**
1788
+ * This is a base class for the magic confirm components
1789
+ */
1790
+ declare class BaseMagicConfirmComponent {
1791
+ /**
1792
+ * title of the component
1793
+ */
1794
+ title: string;
1795
+ /**
1796
+ * message of the component
1797
+ */
1798
+ message: string;
1799
+ /**
1800
+ * onClose Event - to be raised when the component is closed
1801
+ * should pass true when OK is pressed and false when cancel is pressed
1802
+ */
1803
+ onClose: EventEmitter<boolean>;
1804
+ /**
1805
+ * raises close Event
1806
+ * @param result true when OK is pressed and false when cancel is pressed
1807
+ *
1808
+ */
1809
+ OnClose(result: any): void;
1810
+ static ɵfac: i0.ɵɵFactoryDeclaration<BaseMagicConfirmComponent, never>;
1811
+ static ɵcmp: i0.ɵɵComponentDeclaration<BaseMagicConfirmComponent, "mg-base-confirm", never, { "title": { "alias": "title"; "required": false; }; "message": { "alias": "message"; "required": false; }; }, { "onClose": "onClose"; }, never, never, false, never>;
1812
+ }
1813
+
1814
+ /***
1815
+ * This is sample component for the confirmation box
1816
+ */
1817
+ declare class MagicConfirmationBoxComponent extends BaseMagicConfirmComponent {
1818
+ static ɵfac: i0.ɵɵFactoryDeclaration<MagicConfirmationBoxComponent, never>;
1819
+ static ɵcmp: i0.ɵɵComponentDeclaration<MagicConfirmationBoxComponent, "sample-magic-confirmation-box", never, {}, {}, never, never, false, never>;
1820
+ }
1821
+
1822
+ declare class MagicOverlayContainerWrapper implements IMagicViewContainerRef {
1823
+ /**
1824
+ *
1825
+ */
1826
+ Component: i0.InputSignal<any>;
1827
+ /**
1828
+ *
1829
+ */
1830
+ Parameters: i0.InputSignal<any>;
1831
+ OverlayTypeParam: i0.InputSignal<OverlayType>;
1832
+ onClose: i0.OutputEmitterRef<void>;
1833
+ /**
1834
+ * HTML to be displayed in the modal window
1835
+ */
1836
+ overlayContentViewContainerRef: ViewContainerRef;
1837
+ overlayContainerWrapperElementRef: i0.Signal<ElementRef<any>>;
1838
+ /**
1839
+ * @ignore
1840
+ * contais data of allowed base components to use
1841
+ */
1842
+ static allowedBaseComps: Map<number, {
1843
+ comp: any;
1844
+ error: string;
1845
+ }>;
1846
+ private componentListMagicService;
1847
+ private magicLazyModuleLoader;
1848
+ private injector;
1849
+ private changeDetectorRef;
1850
+ constructor();
1851
+ /**
1852
+ *
1853
+ */
1854
+ ngOnInit(): void;
1855
+ private loadComponent;
1856
+ setViewContainerRef(vcRef: ViewContainerRef): void;
1857
+ GetRootElement(): HTMLElement;
1858
+ DetectChanges(): void;
1859
+ static ɵfac: i0.ɵɵFactoryDeclaration<MagicOverlayContainerWrapper, never>;
1860
+ static ɵcmp: i0.ɵɵComponentDeclaration<MagicOverlayContainerWrapper, "app-magic-overlay-container-wrapper", never, { "Component": { "alias": "Component"; "required": false; "isSignal": true; }; "Parameters": { "alias": "Parameters"; "required": false; "isSignal": true; }; "OverlayTypeParam": { "alias": "OverlayTypeParam"; "required": false; "isSignal": true; }; }, { "onClose": "onClose"; }, never, never, false, never>;
1861
+ }
1862
+
1863
+ /**
1864
+ * This service supports custom actions on magic exit
1865
+ */
1866
+ declare class ExitMagicService {
1867
+ /**
1868
+ * Override this method to implement custom logic on magic exit
1869
+ */
1870
+ exitMagic(): void;
1871
+ static ɵfac: i0.ɵɵFactoryDeclaration<ExitMagicService, never>;
1872
+ static ɵprov: i0.ɵɵInjectableDeclaration<any>;
1873
+ }
1874
+
1875
+ /**
1876
+ * Root Magic component
1877
+ */
1878
+ declare class MagicShellComponent implements AfterViewInit, IMagicViewContainerRef {
1879
+ /**
1880
+ * Root component to be displayed in the window
1881
+ */
1882
+ RootComponent: Type<any>;
1883
+ /**
1884
+ * parameters for the Root Component
1885
+ */
1886
+ RootComponentParameters: any;
1887
+ overlayWindowsContainerViewRef: ViewContainerRef;
1888
+ rootMagicElementRef: i0.Signal<ElementRef<any>>;
1889
+ SpinnerTemplate: i0.InputSignal<TemplateRef<any>>;
1890
+ showSpinner: boolean;
1891
+ magicEngineTerminated: boolean;
1892
+ protected engineMagicService: EngineMagicService;
1893
+ protected componentList: ComponentListMagicService;
1894
+ protected changeDetectorRef: ChangeDetectorRef;
1895
+ private titleService;
1896
+ private overlayWindowService;
1897
+ private httpClient;
1898
+ private pendingCommandsCollector;
1899
+ private route;
1900
+ private router;
1901
+ exitMagicService: ExitMagicService;
1902
+ /**
1903
+ *
1904
+ * @param magic Magic's service
1905
+ * @param componentList Magic component list
1906
+ * @param changeDetectorRef Changes detector
1907
+ * @param titleService Title setting service
1908
+ * @param httpClient The native httpClient instance
1909
+ * @param exitMagicService Magic exit service
1910
+ */
1911
+ constructor();
1912
+ /**
1913
+ * Before-unload event listener
1914
+ * @param event
1915
+ */
1916
+ onBeforeUnload(event: any): string;
1917
+ /**
1918
+ * Page-hide event listener, used in place of 'unload'.
1919
+ * Chrome blocks 'unload' by permissions policy ("unload is not allowed in this document"),
1920
+ * so an unload handler is never even registered. 'pagehide' is fired at an earlier step of
1921
+ * the same unloading sequence, so it covers every case 'unload' did.
1922
+ */
1923
+ onPageHide(): void;
1924
+ ngAfterViewInit(): void;
1925
+ setViewContainerRef(vcRef: ViewContainerRef): void;
1926
+ /**
1927
+ * Initialization of Magic mechanisms
1928
+ */
1929
+ initialize(): void;
1930
+ /**
1931
+ * Set the title
1932
+ */
1933
+ setTitle(): void;
1934
+ /**
1935
+ * Set the component according to requested form
1936
+ * @param formName Name of the form to open
1937
+ * @param taskId Id of opening task
1938
+ * @param taskDescription TODO
1939
+ * @param isModal whether modal window is being opened
1940
+ */
1941
+ private setComponent;
1942
+ /**
1943
+ * @ignore
1944
+ */
1945
+ registerUICommands(): void;
1946
+ /**
1947
+ * Execute commands received from the Magic WebClient engine
1948
+ * @param command
1949
+ */
1950
+ executeCommand(command: GuiCommand): void;
1951
+ static ɵfac: i0.ɵɵFactoryDeclaration<MagicShellComponent, never>;
1952
+ static ɵcmp: i0.ɵɵComponentDeclaration<MagicShellComponent, "magic-root", never, { "SpinnerTemplate": { "alias": "SpinnerTemplate"; "required": false; "isSignal": true; }; }, {}, never, never, false, never>;
1953
+ }
1954
+
1955
+ /**
1956
+ * Represents a Magic subform
1957
+ */
1958
+ declare class SubformMagicComponent {
1959
+ /**
1960
+ * @ignore
1961
+ */
1962
+ id: string;
1963
+ /**
1964
+ * @ignore
1965
+ */
1966
+ set magic(val: any);
1967
+ /**
1968
+ * @ignore
1969
+ */
1970
+ component: TaskBaseMagicComponent;
1971
+ /**
1972
+ * @ignore
1973
+ */
1974
+ constructor();
1975
+ private vcRef;
1976
+ protected mgSub: SubformMagicService;
1977
+ /**
1978
+ * @ignore
1979
+ */
1980
+ get Component(): Type<any>;
1981
+ /**
1982
+ * @ignore
1983
+ */
1984
+ get Parameters(): any;
1985
+ static ɵfac: i0.ɵɵFactoryDeclaration<SubformMagicComponent, never>;
1986
+ static ɵcmp: i0.ɵɵComponentDeclaration<SubformMagicComponent, "magic-subform", never, { "magic": { "alias": "magic"; "required": false; }; }, {}, never, never, false, never>;
1987
+ }
1988
+
1989
+ /**
1990
+ * Represents a Magic subform
1991
+ */
1992
+ declare class ErrorMagicComponent {
1993
+ /**
1994
+ * @ignore
1995
+ */
1996
+ id: string;
1997
+ rowId: string;
1998
+ /**
1999
+ * @ignore
2000
+ */
2001
+ set magic(val: any);
2002
+ set rowId1(val: any);
2003
+ defaultDisplay: boolean;
2004
+ private customContentRef;
2005
+ /**
2006
+ * @ignore
2007
+ */
2008
+ constructor();
2009
+ /**
2010
+ * returns true if the html element has no children
2011
+ * @param element
2012
+ */
2013
+ isEmpty(element: HTMLElement): boolean;
2014
+ /**
2015
+ * @ignore
2016
+ */
2017
+ HasErrors(id: string): boolean;
2018
+ protected _task: TaskMagicService;
2019
+ mgService: AccessorMagicService;
2020
+ protected changeDetectorRef: ChangeDetectorRef;
2021
+ static ɵfac: i0.ɵɵFactoryDeclaration<ErrorMagicComponent, never>;
2022
+ static ɵcmp: i0.ɵɵComponentDeclaration<ErrorMagicComponent, "mgError", never, { "magic": { "alias": "magic"; "required": false; }; "rowId1": { "alias": "rowId"; "required": false; }; }, {}, never, ["*"], false, never>;
2023
+ }
2024
+
2025
+ /**
2026
+ * @ignore
2027
+ */
2028
+ declare class NoControlMagicDirective extends MagicDirective {
2029
+ set magic(val: any);
2030
+ constructor();
2031
+ _task: TaskMagicService;
2032
+ element: ElementRef;
2033
+ renderer: Renderer2;
2034
+ vcRef: ViewContainerRef;
2035
+ platform: Platform;
2036
+ magicRow: RowMagicDirective;
2037
+ regEvents(): void;
2038
+ isTabControl(): boolean;
2039
+ isRadio(): boolean;
2040
+ handleCommand(command: GuiCommand): void;
2041
+ handleSetProperty(command: GuiCommand): void;
2042
+ static ɵfac: i0.ɵɵFactoryDeclaration<NoControlMagicDirective, never>;
2043
+ static ɵdir: i0.ɵɵDirectiveDeclaration<NoControlMagicDirective, "[magicnc]", never, { "magic": { "alias": "magicnc"; "required": false; }; }, {}, never, never, false, never>;
2044
+ }
2045
+
2046
+ /**
2047
+ * Perform Magic validation on input controls which hold alphanumeric strings
2048
+ */
2049
+ declare class MgformatMagicDirective {
2050
+ datePasteFlag: boolean;
2051
+ private caretPosAfterMinus;
2052
+ private currencyConfig;
2053
+ protected magicDir: MagicDirective;
2054
+ protected _task: TaskMagicService;
2055
+ /**
2056
+ * @ignore
2057
+ */
2058
+ constructor();
2059
+ ngAfterViewInit(): void;
2060
+ /**
2061
+ * @ignore
2062
+ */
2063
+ /**
2064
+ * This can be used to set pattern
2065
+ * On input, verifies the input matches the required mask
2066
+ */
2067
+ onFocusEvent($event: any): void;
2068
+ onPaste(event: ClipboardEvent): void;
2069
+ /**
2070
+ * ngx-currency moves the cursor to the end when '-' is typed, so fix the cursor position.
2071
+ * Only Natural input mode needs this. In Financial mode digits are entered
2072
+ * from the right, so the cursor at the end already works.
2073
+ */
2074
+ onBeforeInputEvent(event: any): void;
2075
+ onInputEvent(event: any): void;
2076
+ /**
2077
+ * Saves where the cursor must go after '-' is typed in a numeric control.
2078
+ * The cursor can't be set here: ngx-currency adds the '-' on the input event,
2079
+ * which comes after this one, and moves the cursor to the end.
2080
+ * @param input The input control
2081
+ */
2082
+ saveCaretPosition(input: HTMLInputElement): void;
2083
+ dateMasking(event: any): void;
2084
+ /**
2085
+ * @ignore
2086
+ */
2087
+ onChangeEvent(event: any): void;
2088
+ onBlurEvent(event: any): void;
2089
+ /** Format year, if user enters 2 digits instead of 4 digits as per the century given in Magic.ini file */
2090
+ formatDateWithCentury(userInput: string, century: number, control: AbstractControl): void;
2091
+ updateYear(day: number, month: string, year: number, separator: string, century: number, centuryVal: number, control: AbstractControl): void;
2092
+ getDateSegments1(dateArray: any): any[];
2093
+ getDateSegments2(dateArray: any): any[];
2094
+ getDateSegments3(dateArray: any): any[];
2095
+ getDateSegments4(dateArray: any): any[];
2096
+ /**
2097
+ * @ignore
2098
+ */
2099
+ calculatePattern(): void;
2100
+ formatDate(pic: PIC): void;
2101
+ /**
2102
+ * @ignore
2103
+ */
2104
+ formatAlphaUnicode(control: AbstractControl): void;
2105
+ /**
2106
+ * @ignore
2107
+ */
2108
+ formatBoolean(control: AbstractControl): void;
2109
+ /**
2110
+ * @ignore
2111
+ */
2112
+ generatePattern(attribute: StorageAttribute, pic: PIC): string;
2113
+ /**
2114
+ * @ignore
2115
+ */
2116
+ generatePatternForNumber(pic: PIC): string;
2117
+ /**
2118
+ * @ignore
2119
+ */
2120
+ isPatternGenerationNeeded(attr: StorageAttribute, pic: PIC): boolean;
2121
+ /**
2122
+ * @ignore
2123
+ */
2124
+ generatePatternForAlpha(pic: PIC): string;
2125
+ /**
2126
+ * @ignore
2127
+ */
2128
+ getDirectiveCount(mask: string, idx: number, pattern: string, changeInPattern: RefParam<boolean>): number;
2129
+ /**
2130
+ * @ignore
2131
+ */
2132
+ IsPatternMatches(mask: string, pattern: string): boolean;
2133
+ static ɵfac: i0.ɵɵFactoryDeclaration<MgformatMagicDirective, never>;
2134
+ static ɵdir: i0.ɵɵDirectiveDeclaration<MgformatMagicDirective, "[mgFormat]", never, {}, {}, never, never, false, never>;
2135
+ }
2136
+
2137
+ /**
2138
+ * @ignore
2139
+ */
2140
+ declare class Constants {
2141
+ static readonly DATE_FMT = "dd/MMM/yyyy";
2142
+ }
2143
+ /**
2144
+ * @ignore
2145
+ */
2146
+ declare class DateMagicPipe extends DatePipe implements PipeTransform {
2147
+ protected _task: TaskMagicService;
2148
+ constructor();
2149
+ transform(value: any, controlId: string): any;
2150
+ static ɵfac: i0.ɵɵFactoryDeclaration<DateMagicPipe, never>;
2151
+ static ɵpipe: i0.ɵɵPipeDeclaration<DateMagicPipe, "magicDate", false>;
2152
+ }
2153
+ declare class MgDateFormatter {
2154
+ ConvertMgDateFormatToAngular(mgDateMask: string): string;
2155
+ }
2156
+
2157
+ /**
2158
+ * @ignore
2159
+ */
2160
+ declare class TimeMagicPipe extends DatePipe implements PipeTransform {
2161
+ protected _task: TaskMagicService;
2162
+ constructor();
2163
+ transform(value: any, controlId: string): any;
2164
+ static ɵfac: i0.ɵɵFactoryDeclaration<TimeMagicPipe, never>;
2165
+ static ɵpipe: i0.ɵɵPipeDeclaration<TimeMagicPipe, "magicTime", false>;
2166
+ }
2167
+
2168
+ /**
2169
+ * Validates the field range.
2170
+ */
2171
+ declare class RangeValidatorMagicDirective implements Validator {
2172
+ protected _task: TaskMagicService;
2173
+ protected vcRef: ViewContainerRef;
2174
+ /**
2175
+ *
2176
+ * @param _task The task service
2177
+ * @param vcRef
2178
+ */
2179
+ constructor();
2180
+ /**
2181
+ * Validation method
2182
+ * @param c FormControl to validate
2183
+ * @returns If validation fails, return error message, else returns null
2184
+ */
2185
+ validate(c: FormControl): {
2186
+ rangevalidator: {
2187
+ errorMsg: string;
2188
+ };
2189
+ };
2190
+ /**
2191
+ * @ignore
2192
+ */
2193
+ getControlName(c: FormControl): string | null;
2194
+ static ɵfac: i0.ɵɵFactoryDeclaration<RangeValidatorMagicDirective, never>;
2195
+ static ɵdir: i0.ɵɵDirectiveDeclaration<RangeValidatorMagicDirective, "[rangevalidator] ", never, {}, {}, never, never, false, never>;
2196
+ }
2197
+
2198
+ /**
2199
+ * Responsible for connecting HTML elements to the Magic WebClient engine showing it is not Magic Control but a Dummy control which is used to notify only receeive focus event for now
2200
+ */
2201
+ declare class NonMagicControlDirective implements OnInit {
2202
+ set magic(val: any);
2203
+ /**
2204
+ * The HTML element connected to this directive
2205
+ */
2206
+ protected htmlElement: HTMLElement;
2207
+ /**
2208
+ * Magic's component handling this control
2209
+ */
2210
+ component: TaskBaseMagicComponent;
2211
+ /**
2212
+ * Collection of event handlers for this element
2213
+ */
2214
+ private eventHandlers;
2215
+ /**
2216
+ * Id of this element
2217
+ */
2218
+ id: string;
2219
+ /**
2220
+ * @ignore
2221
+ */
2222
+ protected selector: string;
2223
+ /**
2224
+ * @ignore
2225
+ */
2226
+ subscribeRefreshDom: Subscription;
2227
+ eventsOnlyVal: boolean;
2228
+ /**
2229
+ *
2230
+ * @param _task The task service
2231
+ * @param element The element for which the directive is applied
2232
+ * @param renderer Renderer for the element
2233
+ * @param vcRef
2234
+ */
2235
+ constructor();
2236
+ protected _task: TaskMagicService;
2237
+ protected element: ElementRef;
2238
+ protected renderer: Renderer2;
2239
+ protected vcRef: ViewContainerRef;
2240
+ /**
2241
+ * Get the task service
2242
+ * @returns
2243
+ */
2244
+ get task(): TaskMagicService;
2245
+ /**
2246
+ * Register to the events this element may need to handle
2247
+ */
2248
+ protected regEvents(): void;
2249
+ /**
2250
+ * Handle focus event
2251
+ */
2252
+ private OnFocus;
2253
+ /**
2254
+ * Initialize this object
2255
+ */
2256
+ ngOnInit(): void;
2257
+ static ɵfac: i0.ɵɵFactoryDeclaration<NonMagicControlDirective, never>;
2258
+ static ɵdir: i0.ɵɵDirectiveDeclaration<NonMagicControlDirective, "[NonMagicControl]", never, { "magic": { "alias": "NonMagicControl"; "required": false; }; }, {}, never, never, false, never>;
2259
+ }
2260
+
2261
+ /**
2262
+ * Directive for setting focus on element
2263
+ */
2264
+ declare class MagicFocusDirective {
2265
+ private hostElement;
2266
+ constructor();
2267
+ ngAfterViewInit(): void;
2268
+ static ɵfac: i0.ɵɵFactoryDeclaration<MagicFocusDirective, never>;
2269
+ static ɵdir: i0.ɵɵDirectiveDeclaration<MagicFocusDirective, "[magicFocus]", never, {}, {}, never, never, false, never>;
2270
+ }
2271
+
2272
+ /**
2273
+ * Directive for setting ViewContainerRef on element
2274
+ */
2275
+ declare class MagicViewContainerRef {
2276
+ private vcRef;
2277
+ constructor();
2278
+ static ɵfac: i0.ɵɵFactoryDeclaration<MagicViewContainerRef, never>;
2279
+ static ɵdir: i0.ɵɵDirectiveDeclaration<MagicViewContainerRef, "[magicViewContainerRef]", never, {}, {}, never, never, false, never>;
2280
+ }
2281
+
2282
+ declare class Time24MagicPipe implements PipeTransform {
2283
+ protected _task: TaskMagicService;
2284
+ constructor();
2285
+ transform(value: any, controlId: string): any;
2286
+ static ɵfac: i0.ɵɵFactoryDeclaration<Time24MagicPipe, never>;
2287
+ static ɵpipe: i0.ɵɵPipeDeclaration<Time24MagicPipe, "magicTime24", false>;
2288
+ }
2289
+
2290
+ /**
2291
+ * @ignore
2292
+ */
2293
+ declare class MagicModule {
2294
+ static ɵfac: i0.ɵɵFactoryDeclaration<MagicModule, never>;
2295
+ static ɵmod: i0.ɵɵNgModuleDeclaration<MagicModule, [typeof MagicDirective, typeof CheckboxMagicDirective, typeof CheckboxNoFormControlMagicDirective, typeof InputNoFormControlMagicDirective, typeof ComboboxMagicDirective, typeof RowMagicDirective, typeof MagicCheckboxControlValueAccessor, typeof MagicDefaultValueAccessor, typeof DateValueAccessor, typeof TaskBaseMagicComponent, typeof MagicOverlayContainer, typeof MagicAlertComponent, typeof MagicConfirmationBoxComponent, typeof BaseMagicAlertComponent, typeof BaseMagicConfirmComponent, typeof MagicOverlayContainerWrapper, typeof RouterContainerMagicComponent, typeof MagicShellComponent, typeof SubformMagicComponent, typeof ErrorMagicComponent, typeof NoControlMagicDirective, typeof MgformatMagicDirective, typeof DateMagicPipe, typeof TimeMagicPipe, typeof RangeValidatorMagicDirective, typeof NonMagicControlDirective, typeof MagicFocusDirective, typeof MagicViewContainerRef, typeof Time24MagicPipe], [typeof i30.CommonModule, typeof i31.FormsModule, typeof i31.ReactiveFormsModule, typeof i32.RouterModule, typeof i33.DynamicModule, typeof i34.MaskitoDirective, typeof i35.CdkDragHandle, typeof i35.CdkDrag, typeof i35.DragDropModule], [typeof MagicDirective, typeof CheckboxMagicDirective, typeof CheckboxNoFormControlMagicDirective, typeof InputNoFormControlMagicDirective, typeof ComboboxMagicDirective, typeof RowMagicDirective, typeof MagicCheckboxControlValueAccessor, typeof MagicDefaultValueAccessor, typeof DateValueAccessor, typeof TaskBaseMagicComponent, typeof MagicOverlayContainer, typeof MagicAlertComponent, typeof MagicConfirmationBoxComponent, typeof BaseMagicAlertComponent, typeof BaseMagicConfirmComponent, typeof MagicOverlayContainerWrapper, typeof RouterContainerMagicComponent, typeof MagicShellComponent, typeof SubformMagicComponent, typeof ErrorMagicComponent, typeof NoControlMagicDirective, typeof MgformatMagicDirective, typeof DateMagicPipe, typeof TimeMagicPipe, typeof RangeValidatorMagicDirective, typeof NonMagicControlDirective, typeof MagicFocusDirective, typeof MagicViewContainerRef, typeof Time24MagicPipe, typeof i34.MaskitoDirective]>;
2296
+ static ɵinj: i0.ɵɵInjectorDeclaration<MagicModule>;
2297
+ }
2298
+
2299
+ /**
2300
+ * Service managing alert and confirmation windows
2301
+ * This is Magic's default provider
2302
+ */
2303
+ declare class ConfirmationComponentsMagicProvider {
2304
+ /**
2305
+ * Return true when use default javascript alert and confirmation or return false to provide custom components
2306
+ * @returns true is we want to use default javascript alert and confirmation
2307
+ */
2308
+ showDefaultConfirmations(): boolean;
2309
+ /**
2310
+ * Returns component that will replace javascript alert. The component will be used only if showDefaultConfirmations = false
2311
+ * @returns component that will replace javascript Alert
2312
+ */
2313
+ getAlertComponent(): any;
2314
+ /**
2315
+ * Returns component that will replace javascript confirmation box. The component will be used only if showDefaultConfirmations = false
2316
+ * @returns component that will replace javascript confirmation box
2317
+ */
2318
+ getConfirmtionComponent(): any;
2319
+ static ɵfac: i0.ɵɵFactoryDeclaration<ConfirmationComponentsMagicProvider, never>;
2320
+ static ɵprov: i0.ɵɵInjectableDeclaration<any>;
2321
+ }
2322
+
2323
+ /**
2324
+ * Notifies Angular that Magic state changed outside of its knowledge.
2325
+ *
2326
+ * The WebClient runs zoneless, so Angular no longer re-renders the application
2327
+ * after every asynchronous task. Change detection is triggered only by Angular's
2328
+ * own APIs - a template event binding, a signal write, `markForCheck()` and so on.
2329
+ *
2330
+ * Magic drives the UI from sources Angular cannot observe: DOM listeners registered
2331
+ * through `Renderer2`, the engine's event loop, and socket callbacks. Every such
2332
+ * source calls {@link notify}, and the Magic components refresh themselves in response.
2333
+ *
2334
+ * Application code can use this service for the same purpose. Call {@link notify}
2335
+ * after changing component state from a callback Angular does not control - a
2336
+ * `setTimeout`, a `Promise`, a `fetch` response or a third-party widget event:
2337
+ *
2338
+ * ```ts
2339
+ * export class MyForm extends TaskBaseMagicComponent {
2340
+ * private readonly magicChangeDetection = inject(MagicChangeDetectionService);
2341
+ *
2342
+ * override mgOnLoad(): void {
2343
+ * setTimeout(() => {
2344
+ * this.statusText = 'Ready';
2345
+ * this.magicChangeDetection.notify();
2346
+ * }, 1000);
2347
+ * }
2348
+ * }
2349
+ * ```
2350
+ *
2351
+ * Notifications are coalesced by Angular's scheduler, so calling {@link notify}
2352
+ * several times in a row still results in a single refresh.
2353
+ */
2354
+ declare class MagicChangeDetectionService {
2355
+ /**
2356
+ * @ignore
2357
+ */
2358
+ private readonly changedSubject;
2359
+ /**
2360
+ * Emits whenever Magic state changed and the views should be refreshed.
2361
+ * Subscribers are expected to mark their view for check.
2362
+ */
2363
+ readonly changed: Observable<void>;
2364
+ /**
2365
+ * Notify Angular that state which the templates depend on has changed.
2366
+ */
2367
+ notify(): void;
2368
+ static ɵfac: i0.ɵɵFactoryDeclaration<MagicChangeDetectionService, never>;
2369
+ static ɵprov: i0.ɵɵInjectableDeclaration<any>;
2370
+ }
2371
+
2372
+ declare class MagicLazyLoaderService {
2373
+ Load(path: string): Promise<any>;
2374
+ static ɵfac: i0.ɵɵFactoryDeclaration<MagicLazyLoaderService, never>;
2375
+ static ɵprov: i0.ɵɵInjectableDeclaration<any>;
2376
+ }
2377
+
2378
+ declare const MG_FORMATS: {
2379
+ parse: {
2380
+ dateInput: {
2381
+ month: string;
2382
+ year: string;
2383
+ day: string;
2384
+ };
2385
+ };
2386
+ display: {
2387
+ dateInput: string;
2388
+ monthYearLabel: {
2389
+ year: string;
2390
+ month: string;
2391
+ };
2392
+ dateA11yLabel: {
2393
+ year: string;
2394
+ month: string;
2395
+ day: string;
2396
+ };
2397
+ monthYearA11yLabel: {
2398
+ year: string;
2399
+ month: string;
2400
+ };
2401
+ };
2402
+ };
2403
+ declare class MgDateAdapter extends NativeDateAdapter {
2404
+ mgdtfmt: string;
2405
+ protected task: TaskMagicService;
2406
+ localeId: string;
2407
+ constructor();
2408
+ parse(value: any): Date | null;
2409
+ format(date: Date, displayFormat: Object): string;
2410
+ static ɵfac: i0.ɵɵFactoryDeclaration<MgDateAdapter, never>;
2411
+ static ɵprov: i0.ɵɵInjectableDeclaration<any>;
2412
+ }
2413
+
2414
+ declare const matDateProviders: ({
2415
+ provide: typeof DateAdapter;
2416
+ useClass: typeof MgDateAdapter;
2417
+ useValue?: undefined;
2418
+ } | {
2419
+ provide: i0.InjectionToken<_angular_material_core.MatDateFormats>;
2420
+ useValue: {
2421
+ parse: {
2422
+ dateInput: {
2423
+ month: string;
2424
+ year: string;
2425
+ day: string;
2426
+ };
2427
+ };
2428
+ display: {
2429
+ dateInput: string;
2430
+ monthYearLabel: {
2431
+ year: string;
2432
+ month: string;
2433
+ };
2434
+ dateA11yLabel: {
2435
+ year: string;
2436
+ month: string;
2437
+ day: string;
2438
+ };
2439
+ monthYearA11yLabel: {
2440
+ year: string;
2441
+ month: string;
2442
+ };
2443
+ };
2444
+ };
2445
+ useClass?: undefined;
2446
+ })[];
2447
+ /**
2448
+ * Magic service providers
2449
+ */
2450
+ declare const basicMagicProviders: (typeof TaskMagicService | typeof SubformMagicService | typeof TitleMagicService | typeof AccessorMagicService | typeof MagicServices | ({
2451
+ provide: typeof DateAdapter;
2452
+ useClass: typeof MgDateAdapter;
2453
+ useValue?: undefined;
2454
+ } | {
2455
+ provide: i0.InjectionToken<_angular_material_core.MatDateFormats>;
2456
+ useValue: {
2457
+ parse: {
2458
+ dateInput: {
2459
+ month: string;
2460
+ year: string;
2461
+ day: string;
2462
+ };
2463
+ };
2464
+ display: {
2465
+ dateInput: string;
2466
+ monthYearLabel: {
2467
+ year: string;
2468
+ month: string;
2469
+ };
2470
+ dateA11yLabel: {
2471
+ year: string;
2472
+ month: string;
2473
+ day: string;
2474
+ };
2475
+ monthYearA11yLabel: {
2476
+ year: string;
2477
+ month: string;
2478
+ };
2479
+ };
2480
+ };
2481
+ useClass?: undefined;
2482
+ })[])[];
2483
+ declare const magicProviders: (typeof TaskMagicService | typeof SubformMagicService | typeof TitleMagicService | typeof AccessorMagicService | typeof TableMagicService | typeof MagicServices | ({
2484
+ provide: typeof DateAdapter;
2485
+ useClass: typeof MgDateAdapter;
2486
+ useValue?: undefined;
2487
+ } | {
2488
+ provide: i0.InjectionToken<_angular_material_core.MatDateFormats>;
2489
+ useValue: {
2490
+ parse: {
2491
+ dateInput: {
2492
+ month: string;
2493
+ year: string;
2494
+ day: string;
2495
+ };
2496
+ };
2497
+ display: {
2498
+ dateInput: string;
2499
+ monthYearLabel: {
2500
+ year: string;
2501
+ month: string;
2502
+ };
2503
+ dateA11yLabel: {
2504
+ year: string;
2505
+ month: string;
2506
+ day: string;
2507
+ };
2508
+ monthYearA11yLabel: {
2509
+ year: string;
2510
+ month: string;
2511
+ };
2512
+ };
2513
+ };
2514
+ useClass?: undefined;
2515
+ })[])[];
2516
+
2517
+ declare class OverlayContainerMagicProvider {
2518
+ getComponent(): typeof MagicOverlayContainer;
2519
+ static ɵfac: i0.ɵɵFactoryDeclaration<OverlayContainerMagicProvider, never>;
2520
+ static ɵprov: i0.ɵɵInjectableDeclaration<any>;
2521
+ }
2522
+
2523
+ /**
2524
+ * Service managing overlay windows
2525
+ */
2526
+ declare class OverlayWindowService {
2527
+ protected componentList: ComponentListMagicService;
2528
+ protected engineMagicService: EngineMagicService;
2529
+ private magicLazyModuleLoader;
2530
+ private injector;
2531
+ private overlayContainerMagicProvider;
2532
+ private confirmationComponentsMagicProvider;
2533
+ constructor();
2534
+ private overlayWindowsContainerViewRef;
2535
+ private overlayWindowFocusManager;
2536
+ private changeDetectorRef;
2537
+ init(overlayWindowsContainerViewRef: ViewContainerRef, rootMagicElement: Element, changeDetectorRef: ChangeDetectorRef): void;
2538
+ loadAndOpenModule(formName: string, taskId: string, taskDescription: string): void;
2539
+ open(formName: string, taskId: string, taskDescription: string): void;
2540
+ close(commandStr: string): void;
2541
+ /**
2542
+ * Open Confirmation box
2543
+ * @param title title of the box
2544
+ * @param msg message
2545
+ * @param style Magic style
2546
+ */
2547
+ openConfirmationBox(title: string, msg: string, style: Styles): void;
2548
+ /**
2549
+ * This method is called on close of the confirmation
2550
+ * @param style Magic style
2551
+ * @param result
2552
+ */
2553
+ finishConfirmation(style: Styles, result: boolean): void;
2554
+ /**
2555
+ * creates a modal component. Can be used for overlay, message box or confirmation box
2556
+ * @param parameters component's parameters
2557
+ * @param component components to create
2558
+ */
2559
+ private createModalComponent;
2560
+ static ɵfac: i0.ɵɵFactoryDeclaration<OverlayWindowService, never>;
2561
+ static ɵprov: i0.ɵɵInjectableDeclaration<any>;
2562
+ }
2563
+
2564
+ /**
2565
+ * @ignore
2566
+ */
2567
+ declare class StylesMapManager {
2568
+ static StylesMap: Map<string, any>;
2569
+ static MagicPropertyToHtmlAttributeMap: Map<string, string>;
2570
+ static magicValueGetStyle(styleName: string, magicValue: any): string;
2571
+ }
2572
+
2573
+ declare class SubscriberService {
2574
+ private static instance;
2575
+ private socket;
2576
+ private constructor();
2577
+ /**
2578
+ * Subscribe to a specific topic
2579
+ * @param topic The topic to subscribe to
2580
+ */
2581
+ subscribe(topic: string): void;
2582
+ /**
2583
+ * Unsubscribe from a specific topic
2584
+ * @param topic The topic to unsubscribe from
2585
+ */
2586
+ unsubscribe(topic: string): void;
2587
+ /**
2588
+ * Get an Observable for incoming messages
2589
+ * @returns Observable that emits message data
2590
+ */
2591
+ onMessage(): Observable<{
2592
+ topic: string;
2593
+ message: any;
2594
+ }>;
2595
+ /**
2596
+ * Get current subscriptions (for debugging)
2597
+ */
2598
+ getSubscriptions(): void;
2599
+ /**
2600
+ * Listen for subscriptions data
2601
+ * @returns Observable that emits subscriptions list
2602
+ */
2603
+ onSubscriptionsData(): Observable<any[]>;
2604
+ /**
2605
+ * Get the singleton instance of SubscriberService
2606
+ * @returns {SubscriberService} The singleton instance
2607
+ */
2608
+ static getInstance(): SubscriberService;
2609
+ /**
2610
+ * Disconnect from the server
2611
+ */
2612
+ disconnect(): void;
2613
+ static ɵfac: i0.ɵɵFactoryDeclaration<SubscriberService, never>;
2614
+ static ɵprov: i0.ɵɵInjectableDeclaration<any>;
2615
+ }
2616
+
2617
+ /**
2618
+ * @ignore
2619
+ */
2620
+ declare class GuiInteractiveExecutor {
2621
+ command: GuiInteractive;
2622
+ component: TaskBaseMagicComponent;
2623
+ task: TaskMagicService;
2624
+ overlayService: OverlayWindowService;
2625
+ Run(): void;
2626
+ static executeInteractiveCommand(task: TaskMagicService, guiIntactiveCommand: GuiInteractive, overlayService: OverlayWindowService): void;
2627
+ private onValue;
2628
+ private onGetRowsInPage;
2629
+ private onGetMaxRowsInPaginatedTable;
2630
+ private OnMessageBox;
2631
+ private OnOpenForm;
2632
+ private OnSetTitle;
2633
+ private OnRefreshPage;
2634
+ private OnGetTopIndex;
2635
+ private OnGetIsRowEditing;
2636
+ private OnGetLastRoute;
2637
+ }
2638
+
2639
+ /**
2640
+ * Displays a message-box
2641
+ */
2642
+ declare class confirmationBox {
2643
+ /**
2644
+ * @ignore
2645
+ */
2646
+ static isConfirmBox(style: Styles): Boolean;
2647
+ /**
2648
+ * Converts the result from the HTML window to the expected result type
2649
+ * @param style Result received from HTML window
2650
+ * @param okWasPressed Was the "OK" pressed
2651
+ * @returns MessageBox result type
2652
+ */
2653
+ static convertToExcpectedResultBox(style: Styles, okWasPressed: Boolean): Styles;
2654
+ /**
2655
+ * Show a message box as an HTML window
2656
+ * @param title Title of the message box
2657
+ * @param message Message that will be display in the message box
2658
+ * @param style Style that include buttons \ Icons
2659
+ * @returns MessageBox result
2660
+ */
2661
+ static showConfirmationBox(title: string, message: string, style: Styles): boolean;
2662
+ }
2663
+
2664
+ /**
2665
+ * @ignore
2666
+ */
2667
+ declare class utils {
2668
+ static getDistance(control: Element, x: number, y: number): number;
2669
+ static getDimentions(el: any): {
2670
+ x: number;
2671
+ y: number;
2672
+ width: any;
2673
+ height: any;
2674
+ };
2675
+ }
2676
+
2677
+ /**
2678
+ * @ignore
2679
+ */
2680
+ declare class ModalFormDefinition {
2681
+ taskId: string;
2682
+ comp: any;
2683
+ parameters: any;
2684
+ }
2685
+
2686
+ declare class MagicModalProperties implements MagicModalInterface {
2687
+ private formName;
2688
+ private showTitleBar;
2689
+ private x;
2690
+ private y;
2691
+ private width;
2692
+ private height;
2693
+ private isCenteredToWindow;
2694
+ private shouldCloseOnBackgroundClick;
2695
+ private isResizable;
2696
+ private isMovable;
2697
+ constructor(formName: string, showTitleBar: boolean, x: number, y: number, width: string, height: string, isCenteredToWindow: boolean, shouldCloseOnBackgroundClick: boolean, isResizable: boolean, isMovable: boolean);
2698
+ X(): number;
2699
+ Y(): number;
2700
+ Width(): string;
2701
+ Height(): string;
2702
+ IsCenteredToWindow(): boolean;
2703
+ FormName(): string;
2704
+ ShowTitleBar(): boolean;
2705
+ ShouldCloseOnBackgroundClick(): boolean;
2706
+ IsResizable(): boolean;
2707
+ IsMovable(): boolean;
2708
+ }
2709
+
2710
+ export { AccessorMagicService, BaseMagicAlertComponent, BaseMagicConfirmComponent, BaseMagicOverlayContainer, CHECKBOX_VALUE_ACCESSOR, COLOR_FILE_NAME, CheckboxMagicDirective, CheckboxNoFormControlMagicDirective, ComboboxMagicDirective, CommandsCollectorMagicService, ComponentListMagicService, ConfirmationComponentsMagicProvider, Constants, ControlMetadata, ControlsMetadata, DATE_VALUE_ACCESSOR, DateMagicPipe, DateValueAccessor, EngineMagicService, ErrorMagicComponent, ExitMagicService, GuiInteractiveExecutor, HtmlClasses, InputNoFormControlMagicDirective, MAGIC_BG_COLOR, MAGIC_DEFAULT_VALUE_ACCESSOR, MAGIC_FG_COLOR, MG_FORMATS, MagicAlertComponent, MagicChangeDetectionService, MagicCheckboxControlValueAccessor, MagicColorService, MagicConfirmationBoxComponent, MagicDefaultValueAccessor, MagicDirective, MagicFocusDirective, MagicLazyLoaderService, MagicModalProperties, MagicModule, MagicOverlayContainer, MagicOverlayContainerWrapper, MagicServices, MagicShellComponent, MagicViewContainerRef, MgDateAdapter, MgDateFormatter, MgformatMagicDirective, ModalFormDefinition, NoControlMagicDirective, NonMagicControlDirective, OverlayContainerMagicProvider, OverlayWindowService, RangeValidatorMagicDirective, Records, RouteCommand, RouterCommandsMagicService, RouterContainerMagicComponent, RowMagicDirective, StylesMapManager, SubformMagicComponent, SubformMagicService, SubscriberService, TableMagicService, TaskBaseMagicComponent, TaskMagicService, Time24MagicPipe, TimeMagicPipe, TitleMagicService, basicMagicProviders, confirmationBox, magicProviders, matDateProviders, utils };
2711
+ export type { ComponentData, IMagicViewContainerRef, ISubformMagicService, MagicModalInterface, ModuleData, RouteDefinition, SubformDefinition };