@ngx-formly/ionic 7.1.0 → 9.0.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 +26 -9
- package/checkbox/index.d.ts +30 -5
- package/datetime/index.d.ts +54 -5
- package/fesm2022/ngx-formly-ionic-checkbox.mjs +9 -9
- package/fesm2022/ngx-formly-ionic-checkbox.mjs.map +1 -1
- package/fesm2022/ngx-formly-ionic-datetime.mjs +41 -13
- package/fesm2022/ngx-formly-ionic-datetime.mjs.map +1 -1
- package/fesm2022/ngx-formly-ionic-form-field.mjs +45 -34
- package/fesm2022/ngx-formly-ionic-form-field.mjs.map +1 -1
- package/fesm2022/ngx-formly-ionic-input.mjs +35 -34
- package/fesm2022/ngx-formly-ionic-input.mjs.map +1 -1
- package/fesm2022/ngx-formly-ionic-radio.mjs +28 -30
- package/fesm2022/ngx-formly-ionic-radio.mjs.map +1 -1
- package/fesm2022/ngx-formly-ionic-select.mjs +30 -26
- package/fesm2022/ngx-formly-ionic-select.mjs.map +1 -1
- package/fesm2022/ngx-formly-ionic-slider.mjs +11 -11
- package/fesm2022/ngx-formly-ionic-slider.mjs.map +1 -1
- package/fesm2022/ngx-formly-ionic-textarea.mjs +11 -11
- package/fesm2022/ngx-formly-ionic-textarea.mjs.map +1 -1
- package/fesm2022/ngx-formly-ionic-toggle.mjs +9 -9
- package/fesm2022/ngx-formly-ionic-toggle.mjs.map +1 -1
- package/fesm2022/ngx-formly-ionic.mjs +4 -4
- package/form-field/index.d.ts +37 -5
- package/index.d.ts +21 -5
- package/input/index.d.ts +30 -5
- package/package.json +2 -22
- package/radio/index.d.ts +30 -5
- package/select/index.d.ts +42 -5
- package/slider/index.d.ts +30 -5
- package/textarea/index.d.ts +30 -5
- package/toggle/index.d.ts +30 -5
- package/checkbox/checkbox.config.d.ts +0 -2
- package/checkbox/checkbox.module.d.ts +0 -12
- package/checkbox/checkbox.type.d.ts +0 -14
- package/checkbox/public_api.d.ts +0 -3
- package/datetime/datetime.config.d.ts +0 -2
- package/datetime/datetime.module.d.ts +0 -12
- package/datetime/datetime.type.d.ts +0 -38
- package/datetime/public_api.d.ts +0 -3
- package/esm2022/checkbox/checkbox.config.mjs +0 -17
- package/esm2022/checkbox/checkbox.module.mjs +0 -36
- package/esm2022/checkbox/checkbox.type.mjs +0 -23
- package/esm2022/checkbox/ngx-formly-ionic-checkbox.mjs +0 -5
- package/esm2022/checkbox/public_api.mjs +0 -4
- package/esm2022/datetime/datetime.config.mjs +0 -13
- package/esm2022/datetime/datetime.module.mjs +0 -36
- package/esm2022/datetime/datetime.type.mjs +0 -129
- package/esm2022/datetime/ngx-formly-ionic-datetime.mjs +0 -5
- package/esm2022/datetime/public_api.mjs +0 -3
- package/esm2022/form-field/form-field.config.mjs +0 -12
- package/esm2022/form-field/form-field.module.mjs +0 -24
- package/esm2022/form-field/form-field.wrapper.mjs +0 -44
- package/esm2022/form-field/formly.attributes.mjs +0 -31
- package/esm2022/form-field/ngx-formly-ionic-form-field.mjs +0 -5
- package/esm2022/form-field/public_api.mjs +0 -4
- package/esm2022/input/input.config.mjs +0 -32
- package/esm2022/input/input.module.mjs +0 -37
- package/esm2022/input/input.type.mjs +0 -50
- package/esm2022/input/ngx-formly-ionic-input.mjs +0 -5
- package/esm2022/input/public_api.mjs +0 -4
- package/esm2022/lib/ui-ionic.config.mjs +0 -17
- package/esm2022/lib/ui-ionic.mjs +0 -3
- package/esm2022/lib/ui-ionic.module.mjs +0 -50
- package/esm2022/ngx-formly-ionic.mjs +0 -5
- package/esm2022/public_api.mjs +0 -5
- package/esm2022/radio/ngx-formly-ionic-radio.mjs +0 -5
- package/esm2022/radio/public_api.mjs +0 -4
- package/esm2022/radio/radio.config.mjs +0 -13
- package/esm2022/radio/radio.module.mjs +0 -40
- package/esm2022/radio/radio.type.mjs +0 -45
- package/esm2022/select/ngx-formly-ionic-select.mjs +0 -5
- package/esm2022/select/public_api.mjs +0 -4
- package/esm2022/select/select.config.mjs +0 -14
- package/esm2022/select/select.module.mjs +0 -41
- package/esm2022/select/select.type.mjs +0 -69
- package/esm2022/slider/ngx-formly-ionic-slider.mjs +0 -5
- package/esm2022/slider/public_api.mjs +0 -3
- package/esm2022/slider/slider.config.mjs +0 -10
- package/esm2022/slider/slider.module.mjs +0 -37
- package/esm2022/slider/slider.type.mjs +0 -39
- package/esm2022/textarea/ngx-formly-ionic-textarea.mjs +0 -5
- package/esm2022/textarea/public_api.mjs +0 -4
- package/esm2022/textarea/textarea.config.mjs +0 -13
- package/esm2022/textarea/textarea.module.mjs +0 -37
- package/esm2022/textarea/textarea.type.mjs +0 -35
- package/esm2022/toggle/ngx-formly-ionic-toggle.mjs +0 -5
- package/esm2022/toggle/public_api.mjs +0 -3
- package/esm2022/toggle/toggle.config.mjs +0 -13
- package/esm2022/toggle/toggle.module.mjs +0 -36
- package/esm2022/toggle/toggle.type.mjs +0 -23
- package/form-field/form-field.config.d.ts +0 -2
- package/form-field/form-field.module.d.ts +0 -12
- package/form-field/form-field.wrapper.d.ts +0 -12
- package/form-field/formly.attributes.d.ts +0 -9
- package/form-field/public_api.d.ts +0 -4
- package/input/input.config.d.ts +0 -2
- package/input/input.module.d.ts +0 -12
- package/input/input.type.d.ts +0 -14
- package/input/public_api.d.ts +0 -3
- package/lib/ui-ionic.config.d.ts +0 -1
- package/lib/ui-ionic.d.ts +0 -2
- package/lib/ui-ionic.module.d.ts +0 -15
- package/public_api.d.ts +0 -1
- package/radio/public_api.d.ts +0 -3
- package/radio/radio.config.d.ts +0 -2
- package/radio/radio.module.d.ts +0 -13
- package/radio/radio.type.d.ts +0 -13
- package/select/public_api.d.ts +0 -3
- package/select/select.config.d.ts +0 -2
- package/select/select.module.d.ts +0 -13
- package/select/select.type.d.ts +0 -25
- package/slider/public_api.d.ts +0 -3
- package/slider/slider.config.d.ts +0 -2
- package/slider/slider.module.d.ts +0 -12
- package/slider/slider.type.d.ts +0 -14
- package/textarea/public_api.d.ts +0 -3
- package/textarea/textarea.config.d.ts +0 -2
- package/textarea/textarea.module.d.ts +0 -12
- package/textarea/textarea.type.d.ts +0 -14
- package/toggle/public_api.d.ts +0 -3
- package/toggle/toggle.config.d.ts +0 -2
- package/toggle/toggle.module.d.ts +0 -12
- package/toggle/toggle.type.d.ts +0 -14
package/README.md
CHANGED
|
@@ -55,15 +55,32 @@ Formly is a dynamic (JSON powered) form library for Angular that brings unmatche
|
|
|
55
55
|
|
|
56
56
|
#### **Which Version to use?**
|
|
57
57
|
|
|
58
|
-
| Angular version | Formly version
|
|
59
|
-
| --------------- |
|
|
60
|
-
| Angular >=
|
|
61
|
-
| Angular >=
|
|
62
|
-
| Angular >=
|
|
63
|
-
| Angular >=
|
|
64
|
-
| Angular >=
|
|
65
|
-
| Angular >=
|
|
66
|
-
| Angular >=
|
|
58
|
+
| Angular version | Formly version | Migration |
|
|
59
|
+
| --------------- | -------------------- | ---------------------------------- |
|
|
60
|
+
| Angular >= 20 | `@ngx-formly/core@9.x` | [Upgrade to v9](UPGRADE-9.0.md) |
|
|
61
|
+
| Angular >= 19 | `@ngx-formly/core@8.x` | [Upgrade to v8](UPGRADE-8.0.md) |
|
|
62
|
+
| Angular >= 18 | `@ngx-formly/core@7.x` | [Upgrade to v7](UPGRADE-7.0.md) |
|
|
63
|
+
| Angular >= 13 | `@ngx-formly/core@6.x` | [Upgrade to v6](UPGRADE-6.0.md) |
|
|
64
|
+
| Angular >= 7 | `@ngx-formly/core@5.x` | [Upgrade to v5](UPGRADE-5.0.md) |
|
|
65
|
+
| Angular >= 6 | `@ngx-formly/core@4.x` | |
|
|
66
|
+
| Angular >= 5 | `@ngx-formly/core@3.x` | |
|
|
67
|
+
| Angular >= 4 | `@ngx-formly/core@2.x` | [Upgrade to v2](UPGRADE-2.0.md) |
|
|
68
|
+
| Angular >= 2 | `ng-formly@1.x` | |
|
|
69
|
+
|
|
70
|
+
#### Upgrading to v9
|
|
71
|
+
|
|
72
|
+
Formly v9 requires Angular 20 or newer. Upgrade Angular first, then update all
|
|
73
|
+
`@ngx-formly/*` packages used by your application together to v9.
|
|
74
|
+
The Material, PrimeNG, and NG-ZORRO integrations require version 20 or newer of
|
|
75
|
+
their respective UI libraries. Kendo requires version 19.1 or newer, and NativeScript
|
|
76
|
+
requires `@nativescript/angular` 20 or newer. Applications staying on Angular 19 should
|
|
77
|
+
use Formly v8; applications staying on Angular 18 should use Formly v7.
|
|
78
|
+
|
|
79
|
+
PrimeNG datepicker fields no longer accept `monthNavigator`, `yearNavigator`, or
|
|
80
|
+
`yearRange`, which PrimeNG 20 removed. Replace `@primeng/themes` imports with
|
|
81
|
+
`@primeuix/themes` when configuring a PrimeNG theme.
|
|
82
|
+
|
|
83
|
+
See the [v9 upgrade guide](UPGRADE-9.0.md) for migration steps and the [changelog](CHANGELOG.md) for the full list of changes.
|
|
67
84
|
|
|
68
85
|
## Core Team
|
|
69
86
|
|
package/checkbox/index.d.ts
CHANGED
|
@@ -1,5 +1,30 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import * as i6 from '@ngx-formly/core';
|
|
2
|
+
import { ConfigOption, FormlyFieldConfig, FieldType, FieldTypeConfig } from '@ngx-formly/core';
|
|
3
|
+
import * as i0 from '@angular/core';
|
|
4
|
+
import { Type } from '@angular/core';
|
|
5
|
+
import * as i5 from '@ngx-formly/ionic/form-field';
|
|
6
|
+
import { FormlyFieldProps } from '@ngx-formly/ionic/form-field';
|
|
7
|
+
import * as i2 from '@angular/common';
|
|
8
|
+
import * as i3 from '@angular/forms';
|
|
9
|
+
import * as i4 from '@ionic/angular';
|
|
10
|
+
|
|
11
|
+
declare function withFormlyFieldCheckbox(): ConfigOption;
|
|
12
|
+
|
|
13
|
+
interface CheckboxProps extends FormlyFieldProps {
|
|
14
|
+
}
|
|
15
|
+
interface FormlyCheckboxFieldConfig extends FormlyFieldConfig<CheckboxProps> {
|
|
16
|
+
type: 'checkbox' | Type<FormlyFieldCheckbox>;
|
|
17
|
+
}
|
|
18
|
+
declare class FormlyFieldCheckbox extends FieldType<FieldTypeConfig<CheckboxProps>> {
|
|
19
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<FormlyFieldCheckbox, never>;
|
|
20
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<FormlyFieldCheckbox, "formly-field-ion-checkbox", never, {}, {}, never, never, false, never>;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
declare class FormlyCheckboxModule {
|
|
24
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<FormlyCheckboxModule, never>;
|
|
25
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<FormlyCheckboxModule, [typeof FormlyFieldCheckbox], [typeof i2.CommonModule, typeof i3.ReactiveFormsModule, typeof i4.IonicModule, typeof i5.FormlyFormFieldModule, typeof i6.FormlyModule], never>;
|
|
26
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<FormlyCheckboxModule>;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export { FormlyCheckboxModule, FormlyFieldCheckbox, withFormlyFieldCheckbox };
|
|
30
|
+
export type { FormlyCheckboxFieldConfig };
|
package/datetime/index.d.ts
CHANGED
|
@@ -1,5 +1,54 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import * as i6 from '@ngx-formly/core';
|
|
2
|
+
import { ConfigOption, FormlyFieldConfig, FieldType, FieldTypeConfig } from '@ngx-formly/core';
|
|
3
|
+
import * as i0 from '@angular/core';
|
|
4
|
+
import { Type } from '@angular/core';
|
|
5
|
+
import * as i4 from '@ionic/angular';
|
|
6
|
+
import { IonDatetime } from '@ionic/angular';
|
|
7
|
+
import * as i5 from '@ngx-formly/ionic/form-field';
|
|
8
|
+
import { FormlyFieldProps } from '@ngx-formly/ionic/form-field';
|
|
9
|
+
import * as i2 from '@angular/common';
|
|
10
|
+
import * as i3 from '@angular/forms';
|
|
11
|
+
|
|
12
|
+
declare function withFormlyFieldDatetime(): ConfigOption;
|
|
13
|
+
|
|
14
|
+
interface DatetimeProps extends FormlyFieldProps {
|
|
15
|
+
presentation?: 'date' | 'date-time' | 'month' | 'month-year' | 'time' | 'time-date' | 'year';
|
|
16
|
+
locale?: any;
|
|
17
|
+
cancelText?: string;
|
|
18
|
+
doneText?: string;
|
|
19
|
+
dayValues?: number | number[] | string | undefined;
|
|
20
|
+
hourValues?: number | number[] | string | undefined;
|
|
21
|
+
minuteValues?: number | number[] | string | undefined;
|
|
22
|
+
monthValues?: number | number[] | string | undefined;
|
|
23
|
+
yearValues?: number | number[] | string | undefined;
|
|
24
|
+
minDate?: string | undefined;
|
|
25
|
+
maxDate?: string | undefined;
|
|
26
|
+
displayFormat?: string;
|
|
27
|
+
}
|
|
28
|
+
interface FormlyDatetimeFieldConfig extends FormlyFieldConfig<DatetimeProps> {
|
|
29
|
+
type: 'datetime' | Type<FormlyFieldDatetime>;
|
|
30
|
+
}
|
|
31
|
+
declare class FormlyFieldDatetime extends FieldType<FieldTypeConfig<DatetimeProps>> {
|
|
32
|
+
datetime: IonDatetime;
|
|
33
|
+
isOpen: boolean;
|
|
34
|
+
defaultOptions: {
|
|
35
|
+
props: {
|
|
36
|
+
presentation: "month-year";
|
|
37
|
+
};
|
|
38
|
+
};
|
|
39
|
+
displayFormat(): string;
|
|
40
|
+
confirm(): void;
|
|
41
|
+
reset(): void;
|
|
42
|
+
close(): void;
|
|
43
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<FormlyFieldDatetime, never>;
|
|
44
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<FormlyFieldDatetime, "formly-field-ion-datetime", never, {}, {}, never, never, false, never>;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
declare class FormlyDatetimeModule {
|
|
48
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<FormlyDatetimeModule, never>;
|
|
49
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<FormlyDatetimeModule, [typeof FormlyFieldDatetime], [typeof i2.CommonModule, typeof i3.ReactiveFormsModule, typeof i4.IonicModule, typeof i5.FormlyFormFieldModule, typeof i6.FormlyModule], never>;
|
|
50
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<FormlyDatetimeModule>;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
export { FormlyDatetimeModule, withFormlyFieldDatetime };
|
|
54
|
+
export type { FormlyDatetimeFieldConfig };
|
|
@@ -11,20 +11,20 @@ import { FormlyFormFieldModule } from '@ngx-formly/ionic/form-field';
|
|
|
11
11
|
import { CommonModule } from '@angular/common';
|
|
12
12
|
|
|
13
13
|
class FormlyFieldCheckbox extends FieldType {
|
|
14
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
15
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "
|
|
14
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.33", ngImport: i0, type: FormlyFieldCheckbox, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
15
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.33", type: FormlyFieldCheckbox, isStandalone: false, selector: "formly-field-ion-checkbox", usesInheritance: true, ngImport: i0, template: `
|
|
16
16
|
<ion-checkbox [formControl]="formControl" [ionFormlyAttributes]="field">
|
|
17
17
|
{{ props.label }}
|
|
18
18
|
</ion-checkbox>
|
|
19
|
-
`, isInline: true, styles: [":host{display:inherit}\n"], dependencies: [{ kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: i2.IonCheckbox, selector: "ion-checkbox", inputs: ["alignment", "checked", "color", "disabled", "indeterminate", "justify", "labelPlacement", "mode", "name", "value"] }, { kind: "directive", type: i2.BooleanValueAccessor, selector: "ion-checkbox,ion-toggle" }, { kind: "directive", type: i3.ɵIonFormlyAttributes, selector: "[ionFormlyAttributes]", inputs: ["ionFormlyAttributes"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
19
|
+
`, isInline: true, styles: [":host{display:inherit}\n"], dependencies: [{ kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: i2.IonCheckbox, selector: "ion-checkbox", inputs: ["alignment", "checked", "color", "disabled", "errorText", "helperText", "indeterminate", "justify", "labelPlacement", "mode", "name", "required", "value"] }, { kind: "directive", type: i2.BooleanValueAccessor, selector: "ion-checkbox,ion-toggle" }, { kind: "directive", type: i3.ɵIonFormlyAttributes, selector: "[ionFormlyAttributes]", inputs: ["ionFormlyAttributes"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
20
20
|
}
|
|
21
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
21
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.33", ngImport: i0, type: FormlyFieldCheckbox, decorators: [{
|
|
22
22
|
type: Component,
|
|
23
23
|
args: [{ selector: 'formly-field-ion-checkbox', template: `
|
|
24
24
|
<ion-checkbox [formControl]="formControl" [ionFormlyAttributes]="field">
|
|
25
25
|
{{ props.label }}
|
|
26
26
|
</ion-checkbox>
|
|
27
|
-
`, changeDetection: ChangeDetectionStrategy.OnPush, styles: [":host{display:inherit}\n"] }]
|
|
27
|
+
`, changeDetection: ChangeDetectionStrategy.OnPush, standalone: false, styles: [":host{display:inherit}\n"] }]
|
|
28
28
|
}] });
|
|
29
29
|
|
|
30
30
|
function withFormlyFieldCheckbox() {
|
|
@@ -44,18 +44,18 @@ function withFormlyFieldCheckbox() {
|
|
|
44
44
|
}
|
|
45
45
|
|
|
46
46
|
class FormlyCheckboxModule {
|
|
47
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
48
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "
|
|
47
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.33", ngImport: i0, type: FormlyCheckboxModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
48
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.33", ngImport: i0, type: FormlyCheckboxModule, declarations: [FormlyFieldCheckbox], imports: [CommonModule,
|
|
49
49
|
ReactiveFormsModule,
|
|
50
50
|
IonicModule,
|
|
51
51
|
FormlyFormFieldModule, i1$1.FormlyModule] }); }
|
|
52
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "
|
|
52
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.33", ngImport: i0, type: FormlyCheckboxModule, imports: [CommonModule,
|
|
53
53
|
ReactiveFormsModule,
|
|
54
54
|
IonicModule,
|
|
55
55
|
FormlyFormFieldModule,
|
|
56
56
|
FormlyModule.forChild(withFormlyFieldCheckbox())] }); }
|
|
57
57
|
}
|
|
58
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
58
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.33", ngImport: i0, type: FormlyCheckboxModule, decorators: [{
|
|
59
59
|
type: NgModule,
|
|
60
60
|
args: [{
|
|
61
61
|
declarations: [FormlyFieldCheckbox],
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ngx-formly-ionic-checkbox.mjs","sources":["../../../../src/ui/ionic/checkbox/src/checkbox.type.ts","../../../../src/ui/ionic/checkbox/src/checkbox.config.ts","../../../../src/ui/ionic/checkbox/src/checkbox.module.ts","../../../../src/ui/ionic/checkbox/src/ngx-formly-ionic-checkbox.ts"],"sourcesContent":["import { Component, ChangeDetectionStrategy, Type } from '@angular/core';\nimport { FieldType, FieldTypeConfig, FormlyFieldConfig } from '@ngx-formly/core';\nimport { FormlyFieldProps } from '@ngx-formly/ionic/form-field';\n\ninterface CheckboxProps extends FormlyFieldProps {}\n\nexport interface FormlyCheckboxFieldConfig extends FormlyFieldConfig<CheckboxProps> {\n type: 'checkbox' | Type<FormlyFieldCheckbox>;\n}\n\n@Component({\n selector: 'formly-field-ion-checkbox',\n template: `\n <ion-checkbox [formControl]=\"formControl\" [ionFormlyAttributes]=\"field\">\n {{ props.label }}\n </ion-checkbox>\n `,\n changeDetection: ChangeDetectionStrategy.OnPush,\n styleUrls: ['./checkbox.type.scss'],\n})\nexport class FormlyFieldCheckbox extends FieldType<FieldTypeConfig<CheckboxProps>> {}\n","import { ConfigOption } from '@ngx-formly/core';\nimport { FormlyFieldCheckbox } from './checkbox.type';\n\nexport function withFormlyFieldCheckbox(): ConfigOption {\n return {\n types: [\n {\n name: 'checkbox',\n component: FormlyFieldCheckbox,\n wrappers: ['form-field'],\n },\n {\n name: 'boolean',\n extends: 'checkbox',\n },\n ],\n };\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { FormlyModule } from '@ngx-formly/core';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { IonicModule } from '@ionic/angular';\nimport { FormlyFormFieldModule } from '@ngx-formly/ionic/form-field';\n\nimport { FormlyFieldCheckbox } from './checkbox.type';\nimport { withFormlyFieldCheckbox } from './checkbox.config';\n\n@NgModule({\n declarations: [FormlyFieldCheckbox],\n imports: [\n CommonModule,\n ReactiveFormsModule,\n IonicModule,\n FormlyFormFieldModule,\n FormlyModule.forChild(withFormlyFieldCheckbox()),\n ],\n})\nexport class FormlyCheckboxModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["i1"],"mappings":";;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"ngx-formly-ionic-checkbox.mjs","sources":["../../../../src/ui/ionic/checkbox/src/checkbox.type.ts","../../../../src/ui/ionic/checkbox/src/checkbox.config.ts","../../../../src/ui/ionic/checkbox/src/checkbox.module.ts","../../../../src/ui/ionic/checkbox/src/ngx-formly-ionic-checkbox.ts"],"sourcesContent":["import { Component, ChangeDetectionStrategy, Type } from '@angular/core';\nimport { FieldType, FieldTypeConfig, FormlyFieldConfig } from '@ngx-formly/core';\nimport { FormlyFieldProps } from '@ngx-formly/ionic/form-field';\n\ninterface CheckboxProps extends FormlyFieldProps {}\n\nexport interface FormlyCheckboxFieldConfig extends FormlyFieldConfig<CheckboxProps> {\n type: 'checkbox' | Type<FormlyFieldCheckbox>;\n}\n\n@Component({\n selector: 'formly-field-ion-checkbox',\n template: `\n <ion-checkbox [formControl]=\"formControl\" [ionFormlyAttributes]=\"field\">\n {{ props.label }}\n </ion-checkbox>\n `,\n changeDetection: ChangeDetectionStrategy.OnPush,\n styleUrls: ['./checkbox.type.scss'],\n standalone: false,\n})\nexport class FormlyFieldCheckbox extends FieldType<FieldTypeConfig<CheckboxProps>> {}\n","import { ConfigOption } from '@ngx-formly/core';\nimport { FormlyFieldCheckbox } from './checkbox.type';\n\nexport function withFormlyFieldCheckbox(): ConfigOption {\n return {\n types: [\n {\n name: 'checkbox',\n component: FormlyFieldCheckbox,\n wrappers: ['form-field'],\n },\n {\n name: 'boolean',\n extends: 'checkbox',\n },\n ],\n };\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { FormlyModule } from '@ngx-formly/core';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { IonicModule } from '@ionic/angular';\nimport { FormlyFormFieldModule } from '@ngx-formly/ionic/form-field';\n\nimport { FormlyFieldCheckbox } from './checkbox.type';\nimport { withFormlyFieldCheckbox } from './checkbox.config';\n\n@NgModule({\n declarations: [FormlyFieldCheckbox],\n imports: [\n CommonModule,\n ReactiveFormsModule,\n IonicModule,\n FormlyFormFieldModule,\n FormlyModule.forChild(withFormlyFieldCheckbox()),\n ],\n})\nexport class FormlyCheckboxModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["i1"],"mappings":";;;;;;;;;;;;AAqBM,MAAO,mBAAoB,SAAQ,SAAyC,CAAA;+GAArE,mBAAmB,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAnB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,mBAAmB,EAAA,YAAA,EAAA,KAAA,EAAA,QAAA,EAAA,2BAAA,EAAA,eAAA,EAAA,IAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,EATpB;;;;AAIT,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,0BAAA,CAAA,EAAA,YAAA,EAAA,CAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAAA,EAAA,CAAA,eAAA,EAAA,QAAA,EAAA,2CAAA,EAAA,EAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAAA,EAAA,CAAA,oBAAA,EAAA,QAAA,EAAA,eAAA,EAAA,MAAA,EAAA,CAAA,aAAA,EAAA,UAAA,EAAA,SAAA,CAAA,EAAA,OAAA,EAAA,CAAA,eAAA,CAAA,EAAA,QAAA,EAAA,CAAA,QAAA,CAAA,EAAA,EAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAAA,EAAA,CAAA,WAAA,EAAA,QAAA,EAAA,cAAA,EAAA,MAAA,EAAA,CAAA,WAAA,EAAA,SAAA,EAAA,OAAA,EAAA,UAAA,EAAA,WAAA,EAAA,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AA,CAAA,EAAA,CAAA,CAAA;AAIZ,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,oBAAoB,YAP7B,YAAY;YACZ,mBAAmB;YACnB,WAAW;YACX,qBAAqB;AACrB,YAAA,YAAY,CAAC,QAAQ,CAAC,uBAAuB,EAAE,CAAC,CAAA,EAAA,CAAA,CAAA;;4FAGvC,oBAAoB,EAAA,UAAA,EAAA,CAAA;kBAVhC,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,YAAY,EAAE,CAAC,mBAAmB,CAAC;AACnC,oBAAA,OAAO,EAAE;wBACP,YAAY;wBACZ,mBAAmB;wBACnB,WAAW;wBACX,qBAAqB;AACrB,wBAAA,YAAY,CAAC,QAAQ,CAAC,uBAAuB,EAAE,CAAC;AACjD,qBAAA;AACF,iBAAA;;;ACnBD;;AAEG;;;;"}
|
|
@@ -53,11 +53,25 @@ class FormlyFieldDatetime extends FieldType {
|
|
|
53
53
|
this.isOpen = false;
|
|
54
54
|
this.formControl.markAsTouched();
|
|
55
55
|
}
|
|
56
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
57
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
58
|
-
<ion-item
|
|
56
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.33", ngImport: i0, type: FormlyFieldDatetime, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
57
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.33", type: FormlyFieldDatetime, isStandalone: false, selector: "formly-field-ion-datetime", viewQueries: [{ propertyName: "datetime", first: true, predicate: IonDatetime, descendants: true }], usesInheritance: true, ngImport: i0, template: `
|
|
58
|
+
<ion-item
|
|
59
|
+
[button]="true"
|
|
60
|
+
[detail]="false"
|
|
61
|
+
[disabled]="formControl.disabled"
|
|
62
|
+
[attr.aria-label]="props.label"
|
|
63
|
+
aria-haspopup="dialog"
|
|
64
|
+
[attr.aria-expanded]="isOpen"
|
|
65
|
+
(click)="isOpen = true"
|
|
66
|
+
>
|
|
59
67
|
<ion-label>
|
|
60
|
-
|
|
68
|
+
@if (!props.hideLabel) {
|
|
69
|
+
{{ props.label }}
|
|
70
|
+
@if (props.required && !props.hideRequiredMarker) {
|
|
71
|
+
<span aria-hidden="true">*</span>
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
<p>{{ formControl.value ? (formControl.value | date: displayFormat()) : props.placeholder }}</p>
|
|
61
75
|
</ion-label>
|
|
62
76
|
</ion-item>
|
|
63
77
|
<ion-modal
|
|
@@ -88,14 +102,28 @@ class FormlyFieldDatetime extends FieldType {
|
|
|
88
102
|
</ion-datetime>
|
|
89
103
|
</ng-template>
|
|
90
104
|
</ion-modal>
|
|
91
|
-
`, isInline: true, styles: [".ion-datetime-modal{--width: 310px;--border-radius: 8px}.ion-datetime-modal.ion-datetime-modal-time-date{--height: 440px}.ion-datetime-modal.ion-datetime-modal-date{--height: 390px}.ion-datetime-modal.ion-datetime-modal-time{--height: 260px}formly-field-ion-datetime{display:inherit}formly-field-ion-datetime ion-item{flex:1}\n"], dependencies: [{ kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: i2.IonButton, selector: "ion-button", inputs: ["buttonType", "color", "disabled", "download", "expand", "fill", "form", "href", "mode", "rel", "routerAnimation", "routerDirection", "shape", "size", "strong", "target", "type"] }, { kind: "component", type: i2.IonButtons, selector: "ion-buttons", inputs: ["collapse"] }, { kind: "component", type: i2.IonDatetime, selector: "ion-datetime", inputs: ["cancelText", "clearText", "color", "dayValues", "disabled", "doneText", "firstDayOfWeek", "formatOptions", "highlightedDates", "hourCycle", "hourValues", "isDateEnabled", "locale", "max", "min", "minuteValues", "mode", "monthValues", "multiple", "name", "preferWheel", "presentation", "readonly", "showClearButton", "showDefaultButtons", "showDefaultTimeLabel", "showDefaultTitle", "size", "titleSelectedDatesFormatter", "value", "yearValues"] }, { kind: "component", type: i2.IonItem, selector: "ion-item", inputs: ["button", "color", "detail", "detailIcon", "disabled", "download", "href", "lines", "mode", "rel", "routerAnimation", "routerDirection", "target", "type"] }, { kind: "component", type: i2.IonLabel, selector: "ion-label", inputs: ["color", "mode", "position"] }, { kind: "component", type: i2.IonModal, selector: "ion-modal" }, { kind: "directive", type: i2.SelectValueAccessor, selector: "ion-select, ion-radio-group, ion-segment, ion-datetime" }, { kind: "directive", type: i3.ɵIonFormlyAttributes, selector: "[ionFormlyAttributes]", inputs: ["ionFormlyAttributes"] }, { kind: "pipe", type: i4.DatePipe, name: "date" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
105
|
+
`, isInline: true, styles: [".ion-datetime-modal{--width: 310px;--border-radius: 8px}.ion-datetime-modal.ion-datetime-modal-time-date{--height: 440px}.ion-datetime-modal.ion-datetime-modal-date{--height: 390px}.ion-datetime-modal.ion-datetime-modal-time{--height: 260px}formly-field-ion-datetime{display:inherit}formly-field-ion-datetime ion-item{flex:1}\n"], dependencies: [{ kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: i2.IonButton, selector: "ion-button", inputs: ["buttonType", "color", "disabled", "download", "expand", "fill", "form", "href", "mode", "rel", "routerAnimation", "routerDirection", "shape", "size", "strong", "target", "type"] }, { kind: "component", type: i2.IonButtons, selector: "ion-buttons", inputs: ["collapse"] }, { kind: "component", type: i2.IonDatetime, selector: "ion-datetime", inputs: ["cancelText", "clearText", "color", "dayValues", "disabled", "doneText", "firstDayOfWeek", "formatOptions", "highlightedDates", "hourCycle", "hourValues", "isDateEnabled", "locale", "max", "min", "minuteValues", "mode", "monthValues", "multiple", "name", "preferWheel", "presentation", "readonly", "showAdjacentDays", "showClearButton", "showDefaultButtons", "showDefaultTimeLabel", "showDefaultTitle", "size", "titleSelectedDatesFormatter", "value", "yearValues"] }, { kind: "component", type: i2.IonItem, selector: "ion-item", inputs: ["button", "color", "detail", "detailIcon", "disabled", "download", "href", "lines", "mode", "rel", "routerAnimation", "routerDirection", "target", "type"] }, { kind: "component", type: i2.IonLabel, selector: "ion-label", inputs: ["color", "mode", "position"] }, { kind: "component", type: i2.IonModal, selector: "ion-modal" }, { kind: "directive", type: i2.SelectValueAccessor, selector: "ion-select, ion-radio-group, ion-segment, ion-datetime" }, { kind: "directive", type: i3.ɵIonFormlyAttributes, selector: "[ionFormlyAttributes]", inputs: ["ionFormlyAttributes"] }, { kind: "pipe", type: i4.DatePipe, name: "date" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
92
106
|
}
|
|
93
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
107
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.33", ngImport: i0, type: FormlyFieldDatetime, decorators: [{
|
|
94
108
|
type: Component,
|
|
95
109
|
args: [{ selector: 'formly-field-ion-datetime', template: `
|
|
96
|
-
<ion-item
|
|
110
|
+
<ion-item
|
|
111
|
+
[button]="true"
|
|
112
|
+
[detail]="false"
|
|
113
|
+
[disabled]="formControl.disabled"
|
|
114
|
+
[attr.aria-label]="props.label"
|
|
115
|
+
aria-haspopup="dialog"
|
|
116
|
+
[attr.aria-expanded]="isOpen"
|
|
117
|
+
(click)="isOpen = true"
|
|
118
|
+
>
|
|
97
119
|
<ion-label>
|
|
98
|
-
|
|
120
|
+
@if (!props.hideLabel) {
|
|
121
|
+
{{ props.label }}
|
|
122
|
+
@if (props.required && !props.hideRequiredMarker) {
|
|
123
|
+
<span aria-hidden="true">*</span>
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
<p>{{ formControl.value ? (formControl.value | date: displayFormat()) : props.placeholder }}</p>
|
|
99
127
|
</ion-label>
|
|
100
128
|
</ion-item>
|
|
101
129
|
<ion-modal
|
|
@@ -126,7 +154,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
126
154
|
</ion-datetime>
|
|
127
155
|
</ng-template>
|
|
128
156
|
</ion-modal>
|
|
129
|
-
`, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, styles: [".ion-datetime-modal{--width: 310px;--border-radius: 8px}.ion-datetime-modal.ion-datetime-modal-time-date{--height: 440px}.ion-datetime-modal.ion-datetime-modal-date{--height: 390px}.ion-datetime-modal.ion-datetime-modal-time{--height: 260px}formly-field-ion-datetime{display:inherit}formly-field-ion-datetime ion-item{flex:1}\n"] }]
|
|
157
|
+
`, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, standalone: false, styles: [".ion-datetime-modal{--width: 310px;--border-radius: 8px}.ion-datetime-modal.ion-datetime-modal-time-date{--height: 440px}.ion-datetime-modal.ion-datetime-modal-date{--height: 390px}.ion-datetime-modal.ion-datetime-modal-time{--height: 260px}formly-field-ion-datetime{display:inherit}formly-field-ion-datetime ion-item{flex:1}\n"] }]
|
|
130
158
|
}], propDecorators: { datetime: [{
|
|
131
159
|
type: ViewChild,
|
|
132
160
|
args: [IonDatetime]
|
|
@@ -145,18 +173,18 @@ function withFormlyFieldDatetime() {
|
|
|
145
173
|
}
|
|
146
174
|
|
|
147
175
|
class FormlyDatetimeModule {
|
|
148
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
149
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "
|
|
176
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.33", ngImport: i0, type: FormlyDatetimeModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
177
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.33", ngImport: i0, type: FormlyDatetimeModule, declarations: [FormlyFieldDatetime], imports: [CommonModule,
|
|
150
178
|
ReactiveFormsModule,
|
|
151
179
|
IonicModule,
|
|
152
180
|
FormlyFormFieldModule, i1$1.FormlyModule] }); }
|
|
153
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "
|
|
181
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.33", ngImport: i0, type: FormlyDatetimeModule, imports: [CommonModule,
|
|
154
182
|
ReactiveFormsModule,
|
|
155
183
|
IonicModule,
|
|
156
184
|
FormlyFormFieldModule,
|
|
157
185
|
FormlyModule.forChild(withFormlyFieldDatetime())] }); }
|
|
158
186
|
}
|
|
159
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
187
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.33", ngImport: i0, type: FormlyDatetimeModule, decorators: [{
|
|
160
188
|
type: NgModule,
|
|
161
189
|
args: [{
|
|
162
190
|
declarations: [FormlyFieldDatetime],
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ngx-formly-ionic-datetime.mjs","sources":["../../../../src/ui/ionic/datetime/src/datetime.type.ts","../../../../src/ui/ionic/datetime/src/datetime.config.ts","../../../../src/ui/ionic/datetime/src/datetime.module.ts","../../../../src/ui/ionic/datetime/src/ngx-formly-ionic-datetime.ts"],"sourcesContent":["import { Component, ChangeDetectionStrategy, ViewChild, ViewEncapsulation, Type } from '@angular/core';\nimport { IonDatetime } from '@ionic/angular';\nimport { FieldType, FieldTypeConfig, FormlyFieldConfig } from '@ngx-formly/core';\nimport { FormlyFieldProps } from '@ngx-formly/ionic/form-field';\n\ninterface DatetimeProps extends FormlyFieldProps {\n presentation?: 'date' | 'date-time' | 'month' | 'month-year' | 'time' | 'time-date' | 'year';\n locale?: any;\n cancelText?: string;\n doneText?: string;\n dayValues?: number | number[] | string | undefined;\n hourValues?: number | number[] | string | undefined;\n minuteValues?: number | number[] | string | undefined;\n monthValues?: number | number[] | string | undefined;\n yearValues?: number | number[] | string | undefined;\n minDate?: string | undefined;\n maxDate?: string | undefined;\n displayFormat?: string;\n}\n\nexport interface FormlyDatetimeFieldConfig extends FormlyFieldConfig<DatetimeProps> {\n type: 'datetime' | Type<FormlyFieldDatetime>;\n}\n\n@Component({\n selector: 'formly-field-ion-datetime',\n template: `\n <ion-item
|
|
1
|
+
{"version":3,"file":"ngx-formly-ionic-datetime.mjs","sources":["../../../../src/ui/ionic/datetime/src/datetime.type.ts","../../../../src/ui/ionic/datetime/src/datetime.config.ts","../../../../src/ui/ionic/datetime/src/datetime.module.ts","../../../../src/ui/ionic/datetime/src/ngx-formly-ionic-datetime.ts"],"sourcesContent":["import { Component, ChangeDetectionStrategy, ViewChild, ViewEncapsulation, Type } from '@angular/core';\nimport { IonDatetime } from '@ionic/angular';\nimport { FieldType, FieldTypeConfig, FormlyFieldConfig } from '@ngx-formly/core';\nimport { FormlyFieldProps } from '@ngx-formly/ionic/form-field';\n\ninterface DatetimeProps extends FormlyFieldProps {\n presentation?: 'date' | 'date-time' | 'month' | 'month-year' | 'time' | 'time-date' | 'year';\n locale?: any;\n cancelText?: string;\n doneText?: string;\n dayValues?: number | number[] | string | undefined;\n hourValues?: number | number[] | string | undefined;\n minuteValues?: number | number[] | string | undefined;\n monthValues?: number | number[] | string | undefined;\n yearValues?: number | number[] | string | undefined;\n minDate?: string | undefined;\n maxDate?: string | undefined;\n displayFormat?: string;\n}\n\nexport interface FormlyDatetimeFieldConfig extends FormlyFieldConfig<DatetimeProps> {\n type: 'datetime' | Type<FormlyFieldDatetime>;\n}\n\n@Component({\n selector: 'formly-field-ion-datetime',\n template: `\n <ion-item\n [button]=\"true\"\n [detail]=\"false\"\n [disabled]=\"formControl.disabled\"\n [attr.aria-label]=\"props.label\"\n aria-haspopup=\"dialog\"\n [attr.aria-expanded]=\"isOpen\"\n (click)=\"isOpen = true\"\n >\n <ion-label>\n @if (!props.hideLabel) {\n {{ props.label }}\n @if (props.required && !props.hideRequiredMarker) {\n <span aria-hidden=\"true\">*</span>\n }\n }\n <p>{{ formControl.value ? (formControl.value | date: displayFormat()) : props.placeholder }}</p>\n </ion-label>\n </ion-item>\n <ion-modal\n [isOpen]=\"isOpen\"\n (didDismiss)=\"close()\"\n [cssClass]=\"'ion-datetime-modal ion-datetime-modal-' + props.presentation\"\n >\n <ng-template>\n <ion-datetime\n [locale]=\"props.locale\"\n [presentation]=\"props.presentation\"\n [cancelText]=\"props.cancelText\"\n [dayValues]=\"props.dayValues\"\n [doneText]=\"props.doneText\"\n [hourValues]=\"props.hourValues\"\n [minuteValues]=\"props.minuteValues\"\n [monthValues]=\"props.monthValues\"\n [yearValues]=\"props.yearValues\"\n [min]=\"props.minDate ? props.minDate : props.min\"\n [max]=\"props.maxDate ? props.maxDate : props.max\"\n [formControl]=\"formControl\"\n [ionFormlyAttributes]=\"field\"\n >\n <ion-buttons slot=\"buttons\">\n <ion-button (click)=\"reset()\">{{ props.cancelText || 'Cancel' }}</ion-button>\n <ion-button (click)=\"confirm()\">{{ props.doneText || 'Done' }}</ion-button>\n </ion-buttons>\n </ion-datetime>\n </ng-template>\n </ion-modal>\n `,\n changeDetection: ChangeDetectionStrategy.OnPush,\n styleUrls: ['./dattime.type.scss'],\n encapsulation: ViewEncapsulation.None,\n standalone: false,\n})\nexport class FormlyFieldDatetime extends FieldType<FieldTypeConfig<DatetimeProps>> {\n @ViewChild(IonDatetime) datetime!: IonDatetime;\n isOpen = false;\n\n override defaultOptions = {\n props: {\n presentation: 'month-year' as const,\n },\n };\n\n displayFormat() {\n if (this.props.displayFormat) {\n return this.props.displayFormat;\n }\n\n switch (this.props.presentation) {\n case 'date-time':\n case 'time-date':\n return 'short';\n case 'time':\n return 'shortTime';\n case 'month':\n return 'MMMM';\n case 'month-year':\n return 'MMMM, y';\n case 'year':\n return 'y';\n case 'date':\n return 'mediumDate';\n }\n }\n\n confirm() {\n this.datetime?.confirm();\n this.close();\n }\n\n reset() {\n this.datetime?.reset();\n this.close();\n }\n\n close() {\n this.isOpen = false;\n this.formControl.markAsTouched();\n }\n}\n","import { ConfigOption } from '@ngx-formly/core';\nimport { FormlyFieldDatetime } from './datetime.type';\n\nexport function withFormlyFieldDatetime(): ConfigOption {\n return {\n types: [\n {\n name: 'datetime',\n component: FormlyFieldDatetime,\n wrappers: ['form-field'],\n },\n ],\n };\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { FormlyModule } from '@ngx-formly/core';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { IonicModule } from '@ionic/angular';\nimport { FormlyFormFieldModule } from '@ngx-formly/ionic/form-field';\n\nimport { FormlyFieldDatetime } from './datetime.type';\nimport { withFormlyFieldDatetime } from './datetime.config';\n\n@NgModule({\n declarations: [FormlyFieldDatetime],\n imports: [\n CommonModule,\n ReactiveFormsModule,\n IonicModule,\n FormlyFormFieldModule,\n FormlyModule.forChild(withFormlyFieldDatetime()),\n ],\n})\nexport class FormlyDatetimeModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["i1"],"mappings":";;;;;;;;;;;;;AAgFM,MAAO,mBAAoB,SAAQ,SAAyC,CAAA;AAxDlF,IAAA,WAAA,GAAA;;QA0DE,IAAA,CAAA,MAAM,GAAG,KAAK;AAEL,QAAA,IAAA,CAAA,cAAc,GAAG;AACxB,YAAA,KAAK,EAAE;AACL,gBAAA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IAAA,EAAA,CAAA;oBACR,YAAY,EAAE,CAAC,mBAAmB,CAAC;AACnC,oBAAA,OAAO,EAAE;wBACP,YAAY;wBACZ,mBAAmB;wBACnB,WAAW;wBACX,qBAAqB;AACrB,wBAAA,YAAY,CAAC,QAAQ,CAAC,uBAAuB,EAAE,CAAC;AACjD,qBAAA;AACF,iBAAA;;;ACnBD;;AAEG;;;;"}
|
|
@@ -1,31 +1,35 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { Component, Input, Inject, Directive, NgModule } from '@angular/core';
|
|
3
|
-
import * as
|
|
2
|
+
import { Component, DOCUMENT, Input, Inject, Directive, NgModule } from '@angular/core';
|
|
3
|
+
import * as i2 from '@ngx-formly/core';
|
|
4
4
|
import { FieldWrapper, FormlyAttributes, FormlyModule } from '@ngx-formly/core';
|
|
5
|
-
import * as i1 from '@angular
|
|
6
|
-
import { DOCUMENT, CommonModule } from '@angular/common';
|
|
7
|
-
import * as i2 from '@ionic/angular';
|
|
5
|
+
import * as i1 from '@ionic/angular';
|
|
8
6
|
import { IonicModule } from '@ionic/angular';
|
|
7
|
+
import { CommonModule } from '@angular/common';
|
|
9
8
|
import { ReactiveFormsModule } from '@angular/forms';
|
|
10
9
|
|
|
11
10
|
class FormlyWrapperFormField extends FieldWrapper {
|
|
12
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
13
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
11
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.33", ngImport: i0, type: FormlyWrapperFormField, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
12
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.33", type: FormlyWrapperFormField, isStandalone: false, selector: "formly-wrapper-ion-form-field", usesInheritance: true, ngImport: i0, template: `
|
|
14
13
|
<ion-item [lines]="props.itemLines">
|
|
15
14
|
<ng-template #fieldComponent></ng-template>
|
|
16
15
|
</ion-item>
|
|
17
|
-
|
|
18
|
-
<ion-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
16
|
+
@if (props.description) {
|
|
17
|
+
<ion-note class="ion-margin-start">{{ props.description }}</ion-note>
|
|
18
|
+
}
|
|
19
|
+
@if (showError) {
|
|
20
|
+
<ion-item lines="none">
|
|
21
|
+
<ion-label>
|
|
22
|
+
<ion-text color="danger">
|
|
23
|
+
<p>
|
|
24
|
+
<formly-validation-message [field]="field"></formly-validation-message>
|
|
25
|
+
</p>
|
|
26
|
+
</ion-text>
|
|
27
|
+
</ion-label>
|
|
28
|
+
</ion-item>
|
|
29
|
+
}
|
|
30
|
+
`, isInline: true, dependencies: [{ kind: "component", type: i1.IonItem, selector: "ion-item", inputs: ["button", "color", "detail", "detailIcon", "disabled", "download", "href", "lines", "mode", "rel", "routerAnimation", "routerDirection", "target", "type"] }, { kind: "component", type: i1.IonLabel, selector: "ion-label", inputs: ["color", "mode", "position"] }, { kind: "component", type: i1.IonNote, selector: "ion-note", inputs: ["color", "mode"] }, { kind: "component", type: i1.IonText, selector: "ion-text", inputs: ["color", "mode"] }, { kind: "component", type: i2.LegacyFormlyValidationMessage, selector: "formly-validation-message" }] }); }
|
|
27
31
|
}
|
|
28
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
32
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.33", ngImport: i0, type: FormlyWrapperFormField, decorators: [{
|
|
29
33
|
type: Component,
|
|
30
34
|
args: [{
|
|
31
35
|
selector: 'formly-wrapper-ion-form-field',
|
|
@@ -33,16 +37,22 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
33
37
|
<ion-item [lines]="props.itemLines">
|
|
34
38
|
<ng-template #fieldComponent></ng-template>
|
|
35
39
|
</ion-item>
|
|
36
|
-
|
|
37
|
-
<ion-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
40
|
+
@if (props.description) {
|
|
41
|
+
<ion-note class="ion-margin-start">{{ props.description }}</ion-note>
|
|
42
|
+
}
|
|
43
|
+
@if (showError) {
|
|
44
|
+
<ion-item lines="none">
|
|
45
|
+
<ion-label>
|
|
46
|
+
<ion-text color="danger">
|
|
47
|
+
<p>
|
|
48
|
+
<formly-validation-message [field]="field"></formly-validation-message>
|
|
49
|
+
</p>
|
|
50
|
+
</ion-text>
|
|
51
|
+
</ion-label>
|
|
52
|
+
</ion-item>
|
|
53
|
+
}
|
|
45
54
|
`,
|
|
55
|
+
standalone: false,
|
|
46
56
|
}]
|
|
47
57
|
}] });
|
|
48
58
|
|
|
@@ -61,10 +71,10 @@ class IonFormlyAttributes extends FormlyAttributes {
|
|
|
61
71
|
constructor(renderer, elementRef, _document) {
|
|
62
72
|
super(renderer, elementRef, _document);
|
|
63
73
|
}
|
|
64
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
65
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "
|
|
74
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.33", ngImport: i0, type: IonFormlyAttributes, deps: [{ token: i0.Renderer2 }, { token: i0.ElementRef }, { token: DOCUMENT }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
75
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.33", type: IonFormlyAttributes, isStandalone: false, selector: "[ionFormlyAttributes]", inputs: { field: ["ionFormlyAttributes", "field"] }, host: { listeners: { "ionFocus": "onFocus($event)", "ionBlur": "onBlur($event)", "ionChange": "onChange($event)", "ionInput": "onChange($event)" } }, usesInheritance: true, ngImport: i0 }); }
|
|
66
76
|
}
|
|
67
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
77
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.33", ngImport: i0, type: IonFormlyAttributes, decorators: [{
|
|
68
78
|
type: Directive,
|
|
69
79
|
args: [{
|
|
70
80
|
// eslint-disable-next-line
|
|
@@ -75,6 +85,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
75
85
|
'(ionChange)': 'onChange($event)',
|
|
76
86
|
'(ionInput)': 'onChange($event)',
|
|
77
87
|
},
|
|
88
|
+
standalone: false,
|
|
78
89
|
}]
|
|
79
90
|
}], ctorParameters: () => [{ type: i0.Renderer2 }, { type: i0.ElementRef }, { type: undefined, decorators: [{
|
|
80
91
|
type: Inject,
|
|
@@ -85,11 +96,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
85
96
|
}] } });
|
|
86
97
|
|
|
87
98
|
class FormlyFormFieldModule {
|
|
88
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
89
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "
|
|
90
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "
|
|
99
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.33", ngImport: i0, type: FormlyFormFieldModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
100
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.33", ngImport: i0, type: FormlyFormFieldModule, declarations: [FormlyWrapperFormField, IonFormlyAttributes], imports: [CommonModule, ReactiveFormsModule, IonicModule, i2.FormlyModule], exports: [IonFormlyAttributes] }); }
|
|
101
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.33", ngImport: i0, type: FormlyFormFieldModule, imports: [CommonModule, ReactiveFormsModule, IonicModule, FormlyModule.forChild(withFormlyFormField())] }); }
|
|
91
102
|
}
|
|
92
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
103
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.33", ngImport: i0, type: FormlyFormFieldModule, decorators: [{
|
|
93
104
|
type: NgModule,
|
|
94
105
|
args: [{
|
|
95
106
|
declarations: [FormlyWrapperFormField, IonFormlyAttributes],
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ngx-formly-ionic-form-field.mjs","sources":["../../../../src/ui/ionic/form-field/src/form-field.wrapper.ts","../../../../src/ui/ionic/form-field/src/form-field.config.ts","../../../../src/ui/ionic/form-field/src/formly.attributes.ts","../../../../src/ui/ionic/form-field/src/form-field.module.ts","../../../../src/ui/ionic/form-field/src/ngx-formly-ionic-form-field.ts"],"sourcesContent":["import { Component } from '@angular/core';\nimport { IonItem, IonLabel } from '@ionic/angular';\nimport { FieldWrapper, FormlyFieldConfig, FormlyFieldProps as CoreFormlyFieldProps } from '@ngx-formly/core';\n\nexport interface FormlyFieldProps extends CoreFormlyFieldProps {\n hideRequiredMarker?: boolean;\n itemLines?: IonItem['lines'];\n labelPosition?: IonLabel['position'];\n}\n\n@Component({\n selector: 'formly-wrapper-ion-form-field',\n template: `\n <ion-item [lines]=\"props.itemLines\">\n <ng-template #fieldComponent></ng-template>\n </ion-item>\n <ion-
|
|
1
|
+
{"version":3,"file":"ngx-formly-ionic-form-field.mjs","sources":["../../../../src/ui/ionic/form-field/src/form-field.wrapper.ts","../../../../src/ui/ionic/form-field/src/form-field.config.ts","../../../../src/ui/ionic/form-field/src/formly.attributes.ts","../../../../src/ui/ionic/form-field/src/form-field.module.ts","../../../../src/ui/ionic/form-field/src/ngx-formly-ionic-form-field.ts"],"sourcesContent":["import { Component } from '@angular/core';\nimport { IonItem, IonLabel } from '@ionic/angular';\nimport { FieldWrapper, FormlyFieldConfig, FormlyFieldProps as CoreFormlyFieldProps } from '@ngx-formly/core';\n\nexport interface FormlyFieldProps extends CoreFormlyFieldProps {\n hideLabel?: boolean;\n hideRequiredMarker?: boolean;\n itemLines?: IonItem['lines'];\n labelPosition?: IonLabel['position'];\n}\n\n@Component({\n selector: 'formly-wrapper-ion-form-field',\n template: `\n <ion-item [lines]=\"props.itemLines\">\n <ng-template #fieldComponent></ng-template>\n </ion-item>\n @if (props.description) {\n <ion-note class=\"ion-margin-start\">{{ props.description }}</ion-note>\n }\n @if (showError) {\n <ion-item lines=\"none\">\n <ion-label>\n <ion-text color=\"danger\">\n <p>\n <formly-validation-message [field]=\"field\"></formly-validation-message>\n </p>\n </ion-text>\n </ion-label>\n </ion-item>\n }\n `,\n standalone: false,\n})\nexport class FormlyWrapperFormField extends FieldWrapper<FormlyFieldConfig<FormlyFieldProps>> {}\n","import { ConfigOption } from '@ngx-formly/core';\nimport { FormlyWrapperFormField } from './form-field.wrapper';\n\nexport function withFormlyFormField(): ConfigOption {\n return {\n wrappers: [\n {\n name: 'form-field',\n component: FormlyWrapperFormField,\n },\n ],\n };\n}\n","import { Directive, ElementRef, Inject, Input, Renderer2, DOCUMENT } from '@angular/core';\nimport { FormlyAttributes, FormlyFieldConfig } from '@ngx-formly/core';\n\n@Directive({\n // eslint-disable-next-line\n selector: '[ionFormlyAttributes]',\n host: {\n '(ionFocus)': 'onFocus($event)',\n '(ionBlur)': 'onBlur($event)',\n '(ionChange)': 'onChange($event)',\n '(ionInput)': 'onChange($event)',\n },\n standalone: false,\n})\nexport class IonFormlyAttributes extends FormlyAttributes {\n @Input('ionFormlyAttributes') override field: FormlyFieldConfig;\n constructor(renderer: Renderer2, elementRef: ElementRef, @Inject(DOCUMENT) _document: any) {\n super(renderer, elementRef, _document);\n }\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { FormlyModule } from '@ngx-formly/core';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { IonicModule } from '@ionic/angular';\nimport { FormlyWrapperFormField } from './form-field.wrapper';\nimport { IonFormlyAttributes } from './formly.attributes';\nimport { withFormlyFormField } from './form-field.config';\n\n@NgModule({\n declarations: [FormlyWrapperFormField, IonFormlyAttributes],\n exports: [IonFormlyAttributes],\n imports: [CommonModule, ReactiveFormsModule, IonicModule, FormlyModule.forChild(withFormlyFormField())],\n})\nexport class FormlyFormFieldModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["i1"],"mappings":";;;;;;;;;AAkCM,MAAO,sBAAuB,SAAQ,YAAiD,CAAA;+GAAhF,sBAAsB,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAtB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,sBAAsB,EAAA,YAAA,EAAA,KAAA,EAAA,QAAA,EAAA,+BAAA,EAAA,eAAA,EAAA,IAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,EArBvB;;;;;;;;;;;;;;;;;;AAkBT,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,YAAA,EAAA,CAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAAA,EAAA,CAAA,OAAA,EAAA,QAAA,EAAA,UAAA,EAAA,MAAA,EAAA,CAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,YAAA,EAAA,UAAA,EAAA,UAAA,EAAA,MAAA,EAAA,OAAA,EAAA,MAAA,EAAA,KAAA,EAAA,iBAAA,EAAA,iBAAA,EAAA,QAAA,EAAA,MAAA,CAAA,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