ngx-lite-form 1.3.8 → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -2
- package/fesm2022/ngx-lite-form.mjs +139 -66
- package/fesm2022/ngx-lite-form.mjs.map +1 -1
- package/index.d.ts +16 -7
- package/package.json +28 -8
package/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { FormControl, AbstractControl } from '@angular/forms';
|
|
1
|
+
import { FormControl, AbstractControl, FormGroup, FormGroupDirective } from '@angular/forms';
|
|
2
2
|
import * as _angular_core from '@angular/core';
|
|
3
|
-
import { ElementRef, AfterViewInit, OnDestroy, Type, TemplateRef, ViewContainerRef } from '@angular/core';
|
|
3
|
+
import { DoCheck, ElementRef, AfterViewInit, OnDestroy, Type, TemplateRef, ViewContainerRef, QueryList } from '@angular/core';
|
|
4
4
|
import { DomSanitizer, SafeHtml } from '@angular/platform-browser';
|
|
5
5
|
|
|
6
6
|
declare class FieldDto {
|
|
@@ -145,24 +145,29 @@ declare class LiteTextarea {
|
|
|
145
145
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<LiteTextarea, "lite-textarea", never, { "inEdit": { "alias": "inEdit"; "required": false; "isSignal": true; }; "control": { "alias": "control"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
146
146
|
}
|
|
147
147
|
|
|
148
|
-
declare class LiteSelect {
|
|
148
|
+
declare class LiteSelect implements DoCheck {
|
|
149
149
|
private _elementRef;
|
|
150
150
|
inEdit: _angular_core.InputSignal<boolean>;
|
|
151
151
|
control: _angular_core.InputSignal<SelectFieldDto<any>>;
|
|
152
152
|
showOptions: string;
|
|
153
|
-
inputText: string
|
|
153
|
+
inputText: _angular_core.WritableSignal<string>;
|
|
154
|
+
private _previousOptionsLength;
|
|
155
|
+
private _previousOptionsReference;
|
|
156
|
+
private _optionsVersion;
|
|
154
157
|
readonly FormUtils: typeof FormUtils;
|
|
158
|
+
filteredOptions: _angular_core.Signal<any[]>;
|
|
159
|
+
ngDoCheck(): void;
|
|
155
160
|
constructor(_elementRef: ElementRef);
|
|
156
161
|
onDocumentClick(event: MouseEvent): void;
|
|
162
|
+
private handleInputValidation;
|
|
157
163
|
isRequired(): boolean;
|
|
158
164
|
hasErrors(): boolean;
|
|
159
165
|
getErrorMessage(): string[];
|
|
160
166
|
optionSelected(option: any): void;
|
|
161
167
|
onInputChange(event: Event): void;
|
|
162
|
-
onInputBlur(): void;
|
|
163
168
|
getDisplayValue(): string;
|
|
164
169
|
hasTypedValue(): boolean;
|
|
165
|
-
|
|
170
|
+
toggleOptionPanel(): void;
|
|
166
171
|
shouldShowPlaceholder(): boolean;
|
|
167
172
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<LiteSelect, never>;
|
|
168
173
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<LiteSelect, "lite-select", never, { "inEdit": { "alias": "inEdit"; "required": false; "isSignal": true; }; "control": { "alias": "control"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
@@ -485,6 +490,7 @@ declare class LitePanel implements AfterViewInit, OnDestroy {
|
|
|
485
490
|
title: _angular_core.InputSignal<string | null>;
|
|
486
491
|
content: _angular_core.InputSignal<string | Type<any> | TemplateRef<unknown> | null>;
|
|
487
492
|
contentInputs: _angular_core.InputSignal<Record<string, any> | null>;
|
|
493
|
+
formGroup: _angular_core.InputSignal<FormGroup<any> | null>;
|
|
488
494
|
actions: _angular_core.InputSignal<LitePanelAction[] | null>;
|
|
489
495
|
closeOnOverlayClick: _angular_core.InputSignal<boolean>;
|
|
490
496
|
width: _angular_core.InputSignal<string | number | null>;
|
|
@@ -493,8 +499,10 @@ declare class LitePanel implements AfterViewInit, OnDestroy {
|
|
|
493
499
|
maxHeight: _angular_core.InputSignal<string | number | null>;
|
|
494
500
|
closed: _angular_core.OutputEmitterRef<unknown>;
|
|
495
501
|
dynamicComponentContainer?: ViewContainerRef;
|
|
502
|
+
formGroupDirectives?: QueryList<FormGroupDirective>;
|
|
496
503
|
readonly panelTitleId: string;
|
|
497
504
|
private componentRef?;
|
|
505
|
+
private detectedFormGroup;
|
|
498
506
|
private readonly defaultActions;
|
|
499
507
|
readonly resolvedActions: _angular_core.Signal<LitePanelAction[]>;
|
|
500
508
|
readonly contentTemplate: _angular_core.Signal<TemplateRef<unknown> | null>;
|
|
@@ -513,13 +521,14 @@ declare class LitePanel implements AfterViewInit, OnDestroy {
|
|
|
513
521
|
private shouldRespectComponentValidity;
|
|
514
522
|
private getComponentValidity;
|
|
515
523
|
private findFormGroup;
|
|
524
|
+
private detectFormInTemplate;
|
|
516
525
|
private toCssLength;
|
|
517
526
|
private isNilOrEmpty;
|
|
518
527
|
ngAfterViewInit(): void;
|
|
519
528
|
ngOnDestroy(): void;
|
|
520
529
|
private loadDynamicComponent;
|
|
521
530
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<LitePanel, never>;
|
|
522
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<LitePanel, "lite-panel", never, { "title": { "alias": "title"; "required": false; "isSignal": true; }; "content": { "alias": "content"; "required": false; "isSignal": true; }; "contentInputs": { "alias": "contentInputs"; "required": false; "isSignal": true; }; "actions": { "alias": "actions"; "required": false; "isSignal": true; }; "closeOnOverlayClick": { "alias": "closeOnOverlayClick"; "required": false; "isSignal": true; }; "width": { "alias": "width"; "required": false; "isSignal": true; }; "height": { "alias": "height"; "required": false; "isSignal": true; }; "maxWidth": { "alias": "maxWidth"; "required": false; "isSignal": true; }; "maxHeight": { "alias": "maxHeight"; "required": false; "isSignal": true; }; }, { "closed": "closed"; }, never, ["*"], true, never>;
|
|
531
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<LitePanel, "lite-panel", never, { "title": { "alias": "title"; "required": false; "isSignal": true; }; "content": { "alias": "content"; "required": false; "isSignal": true; }; "contentInputs": { "alias": "contentInputs"; "required": false; "isSignal": true; }; "formGroup": { "alias": "formGroup"; "required": false; "isSignal": true; }; "actions": { "alias": "actions"; "required": false; "isSignal": true; }; "closeOnOverlayClick": { "alias": "closeOnOverlayClick"; "required": false; "isSignal": true; }; "width": { "alias": "width"; "required": false; "isSignal": true; }; "height": { "alias": "height"; "required": false; "isSignal": true; }; "maxWidth": { "alias": "maxWidth"; "required": false; "isSignal": true; }; "maxHeight": { "alias": "maxHeight"; "required": false; "isSignal": true; }; }, { "closed": "closed"; }, never, ["*"], true, never>;
|
|
523
532
|
}
|
|
524
533
|
|
|
525
534
|
type LoadingView = 'spinner' | 'progress';
|
package/package.json
CHANGED
|
@@ -1,24 +1,44 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ngx-lite-form",
|
|
3
|
-
"version": "1.
|
|
4
|
-
"description": "
|
|
3
|
+
"version": "1.4.0",
|
|
4
|
+
"description": "Lightweight Angular 20+ form library with 15+ standalone components: input, textarea, select, multi-select, radio, checkbox, password, date picker, datetime picker, file upload, data table, pagination, modal panel, loading indicators, and toast notifications",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"angular",
|
|
7
|
+
"angular20",
|
|
7
8
|
"forms",
|
|
9
|
+
"reactive-forms",
|
|
8
10
|
"components",
|
|
9
|
-
"ui",
|
|
10
|
-
"
|
|
11
|
+
"ui-library",
|
|
12
|
+
"standalone-components",
|
|
13
|
+
"typescript",
|
|
11
14
|
"input",
|
|
12
|
-
"
|
|
15
|
+
"textarea",
|
|
13
16
|
"select",
|
|
17
|
+
"dropdown",
|
|
14
18
|
"multi-select",
|
|
15
|
-
"textarea",
|
|
16
19
|
"radio",
|
|
17
20
|
"checkbox",
|
|
21
|
+
"password",
|
|
18
22
|
"date-picker",
|
|
19
|
-
"datetime-picker"
|
|
23
|
+
"datetime-picker",
|
|
24
|
+
"file-upload",
|
|
25
|
+
"drag-drop",
|
|
26
|
+
"data-table",
|
|
27
|
+
"table",
|
|
28
|
+
"pagination",
|
|
29
|
+
"paginator",
|
|
30
|
+
"modal",
|
|
31
|
+
"dialog",
|
|
32
|
+
"panel",
|
|
33
|
+
"loading",
|
|
34
|
+
"spinner",
|
|
35
|
+
"toast",
|
|
36
|
+
"snackbar",
|
|
37
|
+
"form-validation",
|
|
38
|
+
"ngx",
|
|
39
|
+
"angular-forms"
|
|
20
40
|
],
|
|
21
|
-
"author": "
|
|
41
|
+
"author": "Ko-Hsin Liang",
|
|
22
42
|
"license": "MIT",
|
|
23
43
|
"repository": {
|
|
24
44
|
"type": "git",
|