ngx-material-entity 18.2.5 → 20.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/fesm2022/ngx-material-entity.mjs +165 -155
- package/fesm2022/ngx-material-entity.mjs.map +1 -1
- package/index.d.ts +4501 -3
- package/package.json +10 -12
- package/classes/base.builder.d.ts +0 -37
- package/classes/entity.model.d.ts +0 -27
- package/components/confirm-dialog/confirm-dialog-data.builder.d.ts +0 -24
- package/components/confirm-dialog/confirm-dialog-data.d.ts +0 -48
- package/components/confirm-dialog/confirm-dialog.component.d.ts +0 -36
- package/components/create-page/create-data.route.d.ts +0 -16
- package/components/create-page/create-page.component.d.ts +0 -141
- package/components/create-page/page-create-data.builder.d.ts +0 -18
- package/components/custom-table/custom-table-configuration.model.d.ts +0 -65
- package/components/custom-table/custom-table.component.d.ts +0 -111
- package/components/edit-page/edit-data.route.d.ts +0 -16
- package/components/edit-page/edit-page.component.d.ts +0 -167
- package/components/edit-page/page-edit-data.builder.d.ts +0 -18
- package/components/form/form.component.d.ts +0 -64
- package/components/input/array/array-date-input/array-date-input.component.d.ts +0 -17
- package/components/input/array/array-date-range-input/array-date-range-input.component.d.ts +0 -25
- package/components/input/array/array-date-time-input/array-date-time-input.component.d.ts +0 -26
- package/components/input/array/array-string-autocomplete-chips/array-string-autocomplete-chips.component.d.ts +0 -30
- package/components/input/array/array-string-chips-input/array-string-chips-input.component.d.ts +0 -36
- package/components/input/array/array-table.class.d.ts +0 -56
- package/components/input/base-input.component.d.ts +0 -64
- package/components/input/boolean/boolean-checkbox-input/boolean-checkbox-input.component.d.ts +0 -10
- package/components/input/boolean/boolean-dropdown-input/boolean-dropdown-input.component.d.ts +0 -13
- package/components/input/boolean/boolean-toggle-input/boolean-toggle-input.component.d.ts +0 -10
- package/components/input/custom/custom.component.d.ts +0 -13
- package/components/input/date/date-input/date-input.component.d.ts +0 -11
- package/components/input/date/date-range-input/date-range-input.component.d.ts +0 -22
- package/components/input/date/date-time-input/date-time-input.component.d.ts +0 -32
- package/components/input/file/file-default-input/file-default-input.component.d.ts +0 -11
- package/components/input/file/file-image-input/file-image-input.component.d.ts +0 -28
- package/components/input/file/file-input/file-input.component.d.ts +0 -45
- package/components/input/input.component.d.ts +0 -590
- package/components/input/number/number-dropdown-input/number-dropdown-input.component.d.ts +0 -24
- package/components/input/number/number-input/number-input.component.d.ts +0 -9
- package/components/input/number/number-slider-input/number-slider-input.component.d.ts +0 -10
- package/components/input/relations/references-many-input/references-many-input.component.d.ts +0 -43
- package/components/input/string/string-autocomplete-input/string-autocomplete-input.component.d.ts +0 -19
- package/components/input/string/string-dropdown-input/string-dropdown-input.component.d.ts +0 -24
- package/components/input/string/string-input/string-input.component.d.ts +0 -9
- package/components/input/string/string-password-input/string-password-input.component.d.ts +0 -31
- package/components/input/string/string-textbox-input/string-textbox-input.component.d.ts +0 -9
- package/components/table/create-dialog/create-data.builder.d.ts +0 -25
- package/components/table/create-dialog/create-entity-data.builder.d.ts +0 -21
- package/components/table/create-dialog/create-entity-data.d.ts +0 -19
- package/components/table/create-dialog/create-entity-dialog.component.d.ts +0 -77
- package/components/table/default.actions.d.ts +0 -25
- package/components/table/display-column-value/base-display-column-value.component.d.ts +0 -15
- package/components/table/display-column-value/display-column-value.component.d.ts +0 -26
- package/components/table/edit-dialog/edit-data.builder.d.ts +0 -44
- package/components/table/edit-dialog/edit-entity-data.d.ts +0 -27
- package/components/table/edit-dialog/edit-entity-dialog.component.d.ts +0 -118
- package/components/table/edit-dialog/edit-entity.builder.d.ts +0 -23
- package/components/table/table-data.builder.d.ts +0 -102
- package/components/table/table-data.d.ts +0 -340
- package/components/table/table.component.d.ts +0 -119
- package/components/tooltip/tooltip.component.d.ts +0 -14
- package/decorators/array/array-decorator-internal.data.d.ts +0 -129
- package/decorators/array/array-decorator.data.d.ts +0 -252
- package/decorators/array/array.decorator.d.ts +0 -9
- package/decorators/base/base-property.decorator.d.ts +0 -9
- package/decorators/base/decorator-types.enum.d.ts +0 -48
- package/decorators/base/dropdown-value.interface.d.ts +0 -14
- package/decorators/base/property-decorator-internal.data.d.ts +0 -41
- package/decorators/base/property-decorator.data.d.ts +0 -88
- package/decorators/boolean/boolean-decorator-internal.data.d.ts +0 -26
- package/decorators/boolean/boolean-decorator.data.d.ts +0 -39
- package/decorators/boolean/boolean.decorator.d.ts +0 -7
- package/decorators/custom/custom-decorator-internal.data.d.ts +0 -17
- package/decorators/custom/custom-decorator.data.d.ts +0 -35
- package/decorators/custom/custom.decorator.d.ts +0 -9
- package/decorators/date/date-decorator-internal.data.d.ts +0 -45
- package/decorators/date/date-decorator.data.d.ts +0 -126
- package/decorators/date/date.decorator.d.ts +0 -7
- package/decorators/file/file-decorator-internal.data.d.ts +0 -93
- package/decorators/file/file-decorator.data.d.ts +0 -88
- package/decorators/file/file.decorator.d.ts +0 -8
- package/decorators/has-many/has-many-decorator-internal.data.d.ts +0 -16
- package/decorators/has-many/has-many-decorator.data.d.ts +0 -34
- package/decorators/has-many/has-many.decorator.d.ts +0 -8
- package/decorators/number/number-decorator-internal.data.d.ts +0 -38
- package/decorators/number/number-decorator.data.d.ts +0 -63
- package/decorators/number/number.decorator.d.ts +0 -7
- package/decorators/object/object-decorator-internal.data.d.ts +0 -23
- package/decorators/object/object-decorator.data.d.ts +0 -42
- package/decorators/object/object.decorator.d.ts +0 -8
- package/decorators/references-many/references-many-decorator-internal.data.d.ts +0 -30
- package/decorators/references-many/references-many-decorator.data.d.ts +0 -63
- package/decorators/references-many/references-many.decorator.d.ts +0 -8
- package/decorators/references-one/references-one-decorator-internal.data.d.ts +0 -16
- package/decorators/references-one/references-one-decorator.data.d.ts +0 -32
- package/decorators/references-one/references-one.decorator.d.ts +0 -8
- package/decorators/string/string-decorator-internal.data.d.ts +0 -56
- package/decorators/string/string-decorator.data.d.ts +0 -116
- package/decorators/string/string.decorator.d.ts +0 -7
- package/default-global-configuration-values.d.ts +0 -13
- package/directives/drag-drop.directive.d.ts +0 -29
- package/directives/dynamic-style-class.directive.d.ts +0 -24
- package/directives/included-in.directive.d.ts +0 -14
- package/directives/number.directive.d.ts +0 -16
- package/directives/password-match.directive.d.ts +0 -14
- package/directives/tooltip.directive.d.ts +0 -42
- package/encapsulation/js-2-xml.utilities.d.ts +0 -14
- package/encapsulation/jszip.utilities.d.ts +0 -12
- package/encapsulation/lodash.utilities.d.ts +0 -60
- package/encapsulation/reflect.utilities.d.ts +0 -59
- package/encapsulation/uuid.utilities.d.ts +0 -10
- package/esm2022/classes/base.builder.mjs +0 -47
- package/esm2022/classes/entity.model.mjs +0 -26
- package/esm2022/components/confirm-dialog/confirm-dialog-data.builder.mjs +0 -57
- package/esm2022/components/confirm-dialog/confirm-dialog-data.mjs +0 -2
- package/esm2022/components/confirm-dialog/confirm-dialog.component.mjs +0 -71
- package/esm2022/components/create-page/create-data.route.mjs +0 -12
- package/esm2022/components/create-page/create-page.component.mjs +0 -276
- package/esm2022/components/create-page/page-create-data.builder.mjs +0 -30
- package/esm2022/components/custom-table/custom-table-configuration.model.mjs +0 -37
- package/esm2022/components/custom-table/custom-table.component.mjs +0 -213
- package/esm2022/components/edit-page/edit-data.route.mjs +0 -12
- package/esm2022/components/edit-page/edit-page.component.mjs +0 -362
- package/esm2022/components/edit-page/page-edit-data.builder.mjs +0 -33
- package/esm2022/components/form/form.component.mjs +0 -106
- package/esm2022/components/input/array/array-date-input/array-date-input.component.mjs +0 -56
- package/esm2022/components/input/array/array-date-range-input/array-date-range-input.component.mjs +0 -82
- package/esm2022/components/input/array/array-date-time-input/array-date-time-input.component.mjs +0 -82
- package/esm2022/components/input/array/array-string-autocomplete-chips/array-string-autocomplete-chips.component.mjs +0 -81
- package/esm2022/components/input/array/array-string-chips-input/array-string-chips-input.component.mjs +0 -74
- package/esm2022/components/input/array/array-table.class.mjs +0 -107
- package/esm2022/components/input/base-input.component.mjs +0 -102
- package/esm2022/components/input/boolean/boolean-checkbox-input/boolean-checkbox-input.component.mjs +0 -29
- package/esm2022/components/input/boolean/boolean-dropdown-input/boolean-dropdown-input.component.mjs +0 -40
- package/esm2022/components/input/boolean/boolean-toggle-input/boolean-toggle-input.component.mjs +0 -29
- package/esm2022/components/input/custom/custom.component.mjs +0 -28
- package/esm2022/components/input/date/date-input/date-input.component.mjs +0 -28
- package/esm2022/components/input/date/date-range-input/date-range-input.component.mjs +0 -84
- package/esm2022/components/input/date/date-time-input/date-time-input.component.mjs +0 -90
- package/esm2022/components/input/file/file-default-input/file-default-input.component.mjs +0 -18
- package/esm2022/components/input/file/file-image-input/file-image-input.component.mjs +0 -104
- package/esm2022/components/input/file/file-input/file-input.component.mjs +0 -228
- package/esm2022/components/input/input.component.mjs +0 -1361
- package/esm2022/components/input/number/number-dropdown-input/number-dropdown-input.component.mjs +0 -65
- package/esm2022/components/input/number/number-input/number-input.component.mjs +0 -23
- package/esm2022/components/input/number/number-slider-input/number-slider-input.component.mjs +0 -27
- package/esm2022/components/input/relations/references-many-input/references-many-input.component.mjs +0 -145
- package/esm2022/components/input/string/string-autocomplete-input/string-autocomplete-input.component.mjs +0 -56
- package/esm2022/components/input/string/string-dropdown-input/string-dropdown-input.component.mjs +0 -65
- package/esm2022/components/input/string/string-input/string-input.component.mjs +0 -23
- package/esm2022/components/input/string/string-password-input/string-password-input.component.mjs +0 -107
- package/esm2022/components/input/string/string-textbox-input/string-textbox-input.component.mjs +0 -24
- package/esm2022/components/table/create-dialog/create-data.builder.mjs +0 -56
- package/esm2022/components/table/create-dialog/create-entity-data.builder.mjs +0 -32
- package/esm2022/components/table/create-dialog/create-entity-data.mjs +0 -2
- package/esm2022/components/table/create-dialog/create-entity-dialog.component.mjs +0 -180
- package/esm2022/components/table/default.actions.mjs +0 -83
- package/esm2022/components/table/display-column-value/base-display-column-value.component.mjs +0 -27
- package/esm2022/components/table/display-column-value/display-column-value.component.mjs +0 -41
- package/esm2022/components/table/edit-dialog/edit-data.builder.mjs +0 -136
- package/esm2022/components/table/edit-dialog/edit-entity-data.mjs +0 -2
- package/esm2022/components/table/edit-dialog/edit-entity-dialog.component.mjs +0 -295
- package/esm2022/components/table/edit-dialog/edit-entity.builder.mjs +0 -39
- package/esm2022/components/table/table-data.builder.mjs +0 -304
- package/esm2022/components/table/table-data.mjs +0 -2
- package/esm2022/components/table/table.component.mjs +0 -324
- package/esm2022/components/tooltip/tooltip.component.mjs +0 -26
- package/esm2022/decorators/array/array-decorator-internal.data.mjs +0 -310
- package/esm2022/decorators/array/array-decorator.data.mjs +0 -51
- package/esm2022/decorators/array/array.decorator.mjs +0 -37
- package/esm2022/decorators/base/base-property.decorator.mjs +0 -17
- package/esm2022/decorators/base/decorator-types.enum.mjs +0 -35
- package/esm2022/decorators/base/dropdown-value.interface.mjs +0 -2
- package/esm2022/decorators/base/property-decorator-internal.data.mjs +0 -101
- package/esm2022/decorators/base/property-decorator.data.mjs +0 -59
- package/esm2022/decorators/boolean/boolean-decorator-internal.data.mjs +0 -45
- package/esm2022/decorators/boolean/boolean-decorator.data.mjs +0 -11
- package/esm2022/decorators/boolean/boolean.decorator.mjs +0 -21
- package/esm2022/decorators/custom/custom-decorator-internal.data.mjs +0 -34
- package/esm2022/decorators/custom/custom-decorator.data.mjs +0 -2
- package/esm2022/decorators/custom/custom.decorator.mjs +0 -13
- package/esm2022/decorators/date/date-decorator-internal.data.mjs +0 -92
- package/esm2022/decorators/date/date-decorator.data.mjs +0 -11
- package/esm2022/decorators/date/date.decorator.mjs +0 -22
- package/esm2022/decorators/file/file-decorator-internal.data.mjs +0 -143
- package/esm2022/decorators/file/file-decorator.data.mjs +0 -59
- package/esm2022/decorators/file/file.decorator.mjs +0 -25
- package/esm2022/decorators/has-many/has-many-decorator-internal.data.mjs +0 -41
- package/esm2022/decorators/has-many/has-many-decorator.data.mjs +0 -2
- package/esm2022/decorators/has-many/has-many.decorator.mjs +0 -13
- package/esm2022/decorators/number/number-decorator-internal.data.mjs +0 -68
- package/esm2022/decorators/number/number-decorator.data.mjs +0 -11
- package/esm2022/decorators/number/number.decorator.mjs +0 -22
- package/esm2022/decorators/object/object-decorator-internal.data.mjs +0 -42
- package/esm2022/decorators/object/object-decorator.data.mjs +0 -22
- package/esm2022/decorators/object/object.decorator.mjs +0 -20
- package/esm2022/decorators/references-many/references-many-decorator-internal.data.mjs +0 -55
- package/esm2022/decorators/references-many/references-many-decorator.data.mjs +0 -2
- package/esm2022/decorators/references-many/references-many.decorator.mjs +0 -13
- package/esm2022/decorators/references-one/references-one-decorator-internal.data.mjs +0 -34
- package/esm2022/decorators/references-one/references-one-decorator.data.mjs +0 -2
- package/esm2022/decorators/references-one/references-one.decorator.mjs +0 -12
- package/esm2022/decorators/string/string-decorator-internal.data.mjs +0 -119
- package/esm2022/decorators/string/string-decorator.data.mjs +0 -11
- package/esm2022/decorators/string/string.decorator.mjs +0 -29
- package/esm2022/default-global-configuration-values.mjs +0 -91
- package/esm2022/directives/drag-drop.directive.mjs +0 -60
- package/esm2022/directives/dynamic-style-class.directive.mjs +0 -51
- package/esm2022/directives/included-in.directive.mjs +0 -33
- package/esm2022/directives/number.directive.mjs +0 -37
- package/esm2022/directives/password-match.directive.mjs +0 -30
- package/esm2022/directives/tooltip.directive.mjs +0 -142
- package/esm2022/encapsulation/js-2-xml.utilities.mjs +0 -17
- package/esm2022/encapsulation/jszip.utilities.mjs +0 -16
- package/esm2022/encapsulation/lodash.utilities.mjs +0 -80
- package/esm2022/encapsulation/reflect.utilities.mjs +0 -79
- package/esm2022/encapsulation/uuid.utilities.mjs +0 -14
- package/esm2022/functions/default-false.function.mjs +0 -9
- package/esm2022/functions/default-style-classes.function.mjs +0 -7
- package/esm2022/functions/default-true.function.mjs +0 -9
- package/esm2022/functions/dropdown-values-to-function.function.mjs +0 -15
- package/esm2022/functions/get-changes-tooltip-content.function.mjs +0 -23
- package/esm2022/functions/get-config-value.function.mjs +0 -14
- package/esm2022/functions/get-validation-error-message.function.mjs +0 -54
- package/esm2022/functions/get-validation-errors-tooltip-content.function.mjs +0 -23
- package/esm2022/functions/is-async-function.function.mjs +0 -9
- package/esm2022/functions/table-column-value-to-sort-value.function.mjs +0 -33
- package/esm2022/global-configuration-values.mjs +0 -27
- package/esm2022/mocks/placeholder-data.png.mjs +0 -3
- package/esm2022/ngx-material-entity.mjs +0 -5
- package/esm2022/public-api.mjs +0 -68
- package/esm2022/services/entity.service.mjs +0 -269
- package/esm2022/services/unsaved-changes.guard.mjs +0 -13
- package/esm2022/utilities/date.utilities.mjs +0 -138
- package/esm2022/utilities/entity.utilities.mjs +0 -611
- package/esm2022/utilities/file.utilities.mjs +0 -172
- package/esm2022/utilities/selection.utilities.mjs +0 -49
- package/esm2022/utilities/validation.utilities.mjs +0 -543
- package/functions/default-false.function.d.ts +0 -6
- package/functions/default-style-classes.function.d.ts +0 -6
- package/functions/default-true.function.d.ts +0 -6
- package/functions/dropdown-values-to-function.function.d.ts +0 -11
- package/functions/get-changes-tooltip-content.function.d.ts +0 -13
- package/functions/get-config-value.function.d.ts +0 -7
- package/functions/get-validation-error-message.function.d.ts +0 -5
- package/functions/get-validation-errors-tooltip-content.function.d.ts +0 -12
- package/functions/is-async-function.function.d.ts +0 -6
- package/functions/table-column-value-to-sort-value.function.d.ts +0 -9
- package/global-configuration-values.d.ts +0 -205
- package/mocks/placeholder-data.png.d.ts +0 -1
- package/public-api.d.ts +0 -60
- package/services/entity.service.d.ts +0 -146
- package/services/unsaved-changes.guard.d.ts +0 -23
- package/utilities/date.utilities.d.ts +0 -92
- package/utilities/entity.utilities.d.ts +0 -236
- package/utilities/file.utilities.d.ts +0 -67
- package/utilities/selection.utilities.d.ts +0 -28
- package/utilities/validation.utilities.d.ts +0 -58
|
@@ -1,129 +0,0 @@
|
|
|
1
|
-
import { DateFilterFn } from '@angular/material/datepicker';
|
|
2
|
-
import { IconDefinition } from '@fortawesome/angular-fontawesome';
|
|
3
|
-
import { AutocompleteStringChipsArrayDecoratorConfig, DateArrayDecoratorConfig, DateRangeArrayDecoratorConfig, DateTimeArrayDecoratorConfig, EditArrayItemDialogData, EntityArrayDecoratorConfig, StringChipsArrayDecoratorConfig } from './array-decorator.data';
|
|
4
|
-
import { BaseEntityType, EntityClassNewable } from '../../classes/entity.model';
|
|
5
|
-
import { ConfirmDialogData } from '../../components/confirm-dialog/confirm-dialog-data';
|
|
6
|
-
import { CreateData, DisplayColumn, DynamicStyleClasses } from '../../components/table/table-data';
|
|
7
|
-
import { NgxGlobalDefaultValues } from '../../global-configuration-values';
|
|
8
|
-
import { Time } from '../../utilities/date.utilities';
|
|
9
|
-
import { DecoratorTypes } from '../base/decorator-types.enum';
|
|
10
|
-
import { DropdownValue } from '../base/dropdown-value.interface';
|
|
11
|
-
import { PropertyDecoratorConfigInternal } from '../base/property-decorator-internal.data';
|
|
12
|
-
import { DateRange } from '../date/date-decorator.data';
|
|
13
|
-
/**
|
|
14
|
-
* The internal dialog data for the entities array edit dialog.
|
|
15
|
-
* Sets default values.
|
|
16
|
-
*/
|
|
17
|
-
export declare class EditArrayItemDialogDataInternal<EntityType extends BaseEntityType<EntityType>> implements EditArrayItemDialogData<EntityType> {
|
|
18
|
-
title: (entity: EntityType) => string;
|
|
19
|
-
confirmButtonLabel: string;
|
|
20
|
-
cancelButtonLabel: string;
|
|
21
|
-
constructor(globalConfig: NgxGlobalDefaultValues, data?: EditArrayItemDialogData<EntityType>);
|
|
22
|
-
}
|
|
23
|
-
/**
|
|
24
|
-
* The internal EntityArrayDecoratorConfig. Sets default values.
|
|
25
|
-
*/
|
|
26
|
-
export declare class EntityArrayDecoratorConfigInternal<EntityType extends BaseEntityType<EntityType>> extends PropertyDecoratorConfigInternal<EntityType[]> implements EntityArrayDecoratorConfig<EntityType> {
|
|
27
|
-
itemType: DecoratorTypes.OBJECT;
|
|
28
|
-
allowDuplicates: boolean;
|
|
29
|
-
duplicatesErrorDialog: ConfirmDialogData;
|
|
30
|
-
EntityClass: EntityClassNewable<EntityType>;
|
|
31
|
-
displayColumns: DisplayColumn<EntityType>[];
|
|
32
|
-
dynamicRowStyleClasses: DynamicStyleClasses<EntityType>;
|
|
33
|
-
createDialogData?: CreateData;
|
|
34
|
-
editDialogData: EditArrayItemDialogDataInternal<EntityType>;
|
|
35
|
-
createInline: boolean;
|
|
36
|
-
missingErrorMessage: string;
|
|
37
|
-
addButtonLabel: string;
|
|
38
|
-
removeButtonLabel: string;
|
|
39
|
-
constructor(data: EntityArrayDecoratorConfig<EntityType>, globalConfig: NgxGlobalDefaultValues);
|
|
40
|
-
}
|
|
41
|
-
/**
|
|
42
|
-
* The internal DateArrayDecoratorConfig. Sets default values.
|
|
43
|
-
*/
|
|
44
|
-
export declare class DateArrayDecoratorConfigInternal extends PropertyDecoratorConfigInternal<Date[]> implements DateArrayDecoratorConfig {
|
|
45
|
-
itemType: DecoratorTypes.DATE;
|
|
46
|
-
allowDuplicates: boolean;
|
|
47
|
-
duplicatesErrorDialog: ConfirmDialogData;
|
|
48
|
-
displayColumns: DisplayColumn<Date>[];
|
|
49
|
-
addButtonLabel: string;
|
|
50
|
-
removeButtonLabel: string;
|
|
51
|
-
missingErrorMessage: string;
|
|
52
|
-
dynamicRowStyleClasses: DynamicStyleClasses<Date>;
|
|
53
|
-
min?: (date?: Date) => Date;
|
|
54
|
-
max?: (date?: Date) => Date;
|
|
55
|
-
filter?: DateFilterFn<Date | null | undefined>;
|
|
56
|
-
constructor(data: DateArrayDecoratorConfig, globalConfig: NgxGlobalDefaultValues);
|
|
57
|
-
}
|
|
58
|
-
/**
|
|
59
|
-
* The internal DateTimeArrayDecoratorConfig. Sets default values.
|
|
60
|
-
*/
|
|
61
|
-
export declare class DateTimeArrayDecoratorConfigInternal extends PropertyDecoratorConfigInternal<Date[]> implements DateTimeArrayDecoratorConfig {
|
|
62
|
-
itemType: DecoratorTypes.DATE_TIME;
|
|
63
|
-
allowDuplicates: boolean;
|
|
64
|
-
duplicatesErrorDialog: ConfirmDialogData;
|
|
65
|
-
displayColumns: DisplayColumn<Date>[];
|
|
66
|
-
addButtonLabel: string;
|
|
67
|
-
removeButtonLabel: string;
|
|
68
|
-
missingErrorMessage: string;
|
|
69
|
-
times: DropdownValue<Time>[];
|
|
70
|
-
timeDisplayName: string;
|
|
71
|
-
dynamicRowStyleClasses: DynamicStyleClasses<Date>;
|
|
72
|
-
minDate?: (date?: Date) => Date;
|
|
73
|
-
maxDate?: (date?: Date) => Date;
|
|
74
|
-
filterDate?: DateFilterFn<Date | null | undefined>;
|
|
75
|
-
minTime?: (date?: Date) => Time;
|
|
76
|
-
maxTime?: (date?: Date) => Time;
|
|
77
|
-
filterTime?: ((time: Time) => boolean) | (() => boolean);
|
|
78
|
-
constructor(data: DateTimeArrayDecoratorConfig, globalConfig: NgxGlobalDefaultValues);
|
|
79
|
-
}
|
|
80
|
-
/**
|
|
81
|
-
* The internal DateRangeArrayDecoratorConfig. Sets default values.
|
|
82
|
-
*/
|
|
83
|
-
export declare class DateRangeArrayDecoratorConfigInternal extends PropertyDecoratorConfigInternal<DateRange[]> implements DateRangeArrayDecoratorConfig {
|
|
84
|
-
itemType: DecoratorTypes.DATE_RANGE;
|
|
85
|
-
allowDuplicates: boolean;
|
|
86
|
-
duplicatesErrorDialog: ConfirmDialogData;
|
|
87
|
-
displayColumns: DisplayColumn<DateRange>[];
|
|
88
|
-
addButtonLabel: string;
|
|
89
|
-
removeButtonLabel: string;
|
|
90
|
-
missingErrorMessage: string;
|
|
91
|
-
placeholderStart: string;
|
|
92
|
-
placeholderEnd: string;
|
|
93
|
-
dynamicRowStyleClasses: DynamicStyleClasses<DateRange>;
|
|
94
|
-
minStart?: (date?: Date) => Date;
|
|
95
|
-
maxStart?: (date?: Date) => Date;
|
|
96
|
-
minEnd?: (date?: Date) => Date;
|
|
97
|
-
maxEnd?: (date?: Date) => Date;
|
|
98
|
-
filter?: DateFilterFn<Date>;
|
|
99
|
-
constructor(data: DateRangeArrayDecoratorConfig, globalConfig: NgxGlobalDefaultValues);
|
|
100
|
-
}
|
|
101
|
-
/**
|
|
102
|
-
* The internal StringChipsArrayDecoratorConfig. Sets default values.
|
|
103
|
-
*/
|
|
104
|
-
export declare class StringChipsArrayDecoratorConfigInternal extends PropertyDecoratorConfigInternal<string[]> implements StringChipsArrayDecoratorConfig {
|
|
105
|
-
itemType: DecoratorTypes.STRING;
|
|
106
|
-
allowDuplicates: boolean;
|
|
107
|
-
duplicatesErrorDialog: ConfirmDialogData;
|
|
108
|
-
deleteIcon: IconDefinition;
|
|
109
|
-
minLength?: number;
|
|
110
|
-
maxLength?: number;
|
|
111
|
-
regex?: RegExp;
|
|
112
|
-
constructor(data: StringChipsArrayDecoratorConfig, globalConfig: NgxGlobalDefaultValues);
|
|
113
|
-
}
|
|
114
|
-
/**
|
|
115
|
-
* The internal AutocompleteStringChipsArrayDecoratorConfig. Sets default values.
|
|
116
|
-
*/
|
|
117
|
-
export declare class AutocompleteStringChipsArrayDecoratorConfigInternal extends PropertyDecoratorConfigInternal<string[]> implements AutocompleteStringChipsArrayDecoratorConfig {
|
|
118
|
-
autocompleteValues: (entity: any) => Promise<string[]>;
|
|
119
|
-
itemType: DecoratorTypes.STRING_AUTOCOMPLETE;
|
|
120
|
-
allowDuplicates: boolean;
|
|
121
|
-
duplicatesErrorDialog: ConfirmDialogData;
|
|
122
|
-
deleteIcon: IconDefinition;
|
|
123
|
-
minLength?: number;
|
|
124
|
-
maxLength?: number;
|
|
125
|
-
regex?: RegExp;
|
|
126
|
-
restrictToOptions?: boolean;
|
|
127
|
-
constructor(data: AutocompleteStringChipsArrayDecoratorConfig, globalConfig: NgxGlobalDefaultValues);
|
|
128
|
-
private autocompleteValuesToFunction;
|
|
129
|
-
}
|
|
@@ -1,252 +0,0 @@
|
|
|
1
|
-
import { DateFilterFn } from '@angular/material/datepicker';
|
|
2
|
-
import { IconDefinition } from '@fortawesome/angular-fontawesome';
|
|
3
|
-
import { BaseEntityType, EntityClassNewable } from '../../classes/entity.model';
|
|
4
|
-
import { ConfirmDialogData } from '../../components/confirm-dialog/confirm-dialog-data';
|
|
5
|
-
import { CreateData, DisplayColumn, DynamicStyleClasses } from '../../components/table/table-data';
|
|
6
|
-
import { Time } from '../../utilities/date.utilities';
|
|
7
|
-
import { DecoratorTypes } from '../base/decorator-types.enum';
|
|
8
|
-
import { DropdownValue } from '../base/dropdown-value.interface';
|
|
9
|
-
import { PropertyDecoratorConfig } from '../base/property-decorator.data';
|
|
10
|
-
import { DateRange } from '../date/date-decorator.data';
|
|
11
|
-
import { StringAutocompleteValues } from '../string/string-decorator.data';
|
|
12
|
-
/**
|
|
13
|
-
* Base definition for the @array metadata.
|
|
14
|
-
*/
|
|
15
|
-
export declare abstract class ArrayDecoratorConfig<ValueType> extends PropertyDecoratorConfig<ValueType> {
|
|
16
|
-
/**
|
|
17
|
-
* The type of the items inside the array.
|
|
18
|
-
*/
|
|
19
|
-
itemType: DecoratorTypes;
|
|
20
|
-
/**
|
|
21
|
-
* Whether or not duplicate values are allowed inside the array.
|
|
22
|
-
* @default false
|
|
23
|
-
*/
|
|
24
|
-
allowDuplicates?: boolean;
|
|
25
|
-
/**
|
|
26
|
-
* The error dialog to display when the user tries to add a duplicate entry.
|
|
27
|
-
*/
|
|
28
|
-
duplicatesErrorDialog?: ConfirmDialogData;
|
|
29
|
-
}
|
|
30
|
-
/**
|
|
31
|
-
* Base definition for the @array table metadata.
|
|
32
|
-
*/
|
|
33
|
-
declare abstract class ArrayTableDecoratorConfig<ValueType> extends ArrayDecoratorConfig<ValueType[]> {
|
|
34
|
-
/**
|
|
35
|
-
* The definition of the columns to display. Consists of the displayName to show in the header of the row
|
|
36
|
-
* and the value, which is a function that generates the value to display inside a column.
|
|
37
|
-
*/
|
|
38
|
-
displayColumns: DisplayColumn<ValueType>[];
|
|
39
|
-
/**
|
|
40
|
-
* Configuration for css classes that should be applied to table rows based on a condition.
|
|
41
|
-
* This could be used to eg. Set the background color to green when an item has the status completed etc.
|
|
42
|
-
* INFO: You need to use ng-deep or apply the styling in the styles.scss.
|
|
43
|
-
* @default () => []
|
|
44
|
-
*/
|
|
45
|
-
dynamicRowStyleClasses?: DynamicStyleClasses<ValueType>;
|
|
46
|
-
/**
|
|
47
|
-
* The error-message to display when the array is required but contains no values.
|
|
48
|
-
*/
|
|
49
|
-
missingErrorMessage?: string;
|
|
50
|
-
/**
|
|
51
|
-
* The label for the add button.
|
|
52
|
-
* @default 'Add'
|
|
53
|
-
*/
|
|
54
|
-
addButtonLabel?: string;
|
|
55
|
-
/**
|
|
56
|
-
* The label for the remove button.
|
|
57
|
-
* @default 'Remove'
|
|
58
|
-
*/
|
|
59
|
-
removeButtonLabel?: string;
|
|
60
|
-
}
|
|
61
|
-
/**
|
|
62
|
-
* The dialog data for the entities array edit dialog.
|
|
63
|
-
*/
|
|
64
|
-
export interface EditArrayItemDialogData<EntityType extends BaseEntityType<EntityType>> {
|
|
65
|
-
/**
|
|
66
|
-
* The title of the default edit-dialog.
|
|
67
|
-
*/
|
|
68
|
-
title?: (entity: EntityType) => string;
|
|
69
|
-
/**
|
|
70
|
-
* The label on the confirm-button of the default edit-dialog or page. Defaults to "Save".
|
|
71
|
-
*/
|
|
72
|
-
confirmButtonLabel?: string;
|
|
73
|
-
/**
|
|
74
|
-
* The label on the cancel-button for the default edit-dialog or page. Defaults to "Cancel".
|
|
75
|
-
*/
|
|
76
|
-
cancelButtonLabel?: string;
|
|
77
|
-
}
|
|
78
|
-
/**
|
|
79
|
-
* Definition for an array of Entities.
|
|
80
|
-
*/
|
|
81
|
-
export interface EntityArrayDecoratorConfig<EntityType extends BaseEntityType<EntityType>> extends ArrayTableDecoratorConfig<EntityType> {
|
|
82
|
-
itemType: DecoratorTypes.OBJECT;
|
|
83
|
-
/**
|
|
84
|
-
* The EntityClass used for generating the create inputs.
|
|
85
|
-
*/
|
|
86
|
-
EntityClass: EntityClassNewable<EntityType>;
|
|
87
|
-
/**
|
|
88
|
-
* The data for the add-item-dialog.
|
|
89
|
-
* Can be omitted when adding items inline.
|
|
90
|
-
*/
|
|
91
|
-
createDialogData?: CreateData;
|
|
92
|
-
/**
|
|
93
|
-
* The data for the edit-item-dialog.
|
|
94
|
-
* Can be omitted when adding items inline.
|
|
95
|
-
*/
|
|
96
|
-
editDialogData?: EditArrayItemDialogData<EntityType>;
|
|
97
|
-
/**
|
|
98
|
-
* Whether or not the form for adding items to the array
|
|
99
|
-
* should be displayed inline.
|
|
100
|
-
* @default true
|
|
101
|
-
*/
|
|
102
|
-
createInline?: boolean;
|
|
103
|
-
}
|
|
104
|
-
/**
|
|
105
|
-
* Definition for an array of Dates.
|
|
106
|
-
*/
|
|
107
|
-
export interface DateArrayDecoratorConfig extends ArrayTableDecoratorConfig<Date> {
|
|
108
|
-
itemType: DecoratorTypes.DATE;
|
|
109
|
-
/**
|
|
110
|
-
* A function to get the minimum value of the date.
|
|
111
|
-
*/
|
|
112
|
-
min?: (date?: Date) => Date;
|
|
113
|
-
/**
|
|
114
|
-
* A function to get the maximum value of the date.
|
|
115
|
-
*/
|
|
116
|
-
max?: (date?: Date) => Date;
|
|
117
|
-
/**
|
|
118
|
-
* A filter function to do more specific filtering. This could be the removal of e.g. All weekends.
|
|
119
|
-
*/
|
|
120
|
-
filter?: DateFilterFn<Date | null | undefined>;
|
|
121
|
-
}
|
|
122
|
-
/**
|
|
123
|
-
* Definition for an array of DateTimes.
|
|
124
|
-
*/
|
|
125
|
-
export interface DateTimeArrayDecoratorConfig extends ArrayTableDecoratorConfig<Date> {
|
|
126
|
-
itemType: DecoratorTypes.DATE_TIME;
|
|
127
|
-
/**
|
|
128
|
-
* The selectable times.
|
|
129
|
-
*/
|
|
130
|
-
times?: DropdownValue<Time>[];
|
|
131
|
-
/**
|
|
132
|
-
* The name to use as a label for the time form field.
|
|
133
|
-
* @default 'Time'
|
|
134
|
-
*/
|
|
135
|
-
timeDisplayName?: string;
|
|
136
|
-
/**
|
|
137
|
-
* A function to get the minimum value of the date.
|
|
138
|
-
*/
|
|
139
|
-
minDate?: (date?: Date) => Date;
|
|
140
|
-
/**
|
|
141
|
-
* A function to get the maximum value of the date.
|
|
142
|
-
*/
|
|
143
|
-
maxDate?: (date?: Date) => Date;
|
|
144
|
-
/**
|
|
145
|
-
* A filter function to do more specific date filtering. This could be the removal of e.g. All weekends.
|
|
146
|
-
*/
|
|
147
|
-
filterDate?: DateFilterFn<Date | null | undefined>;
|
|
148
|
-
/**
|
|
149
|
-
* A function to get the minimum value of the time.
|
|
150
|
-
*/
|
|
151
|
-
minTime?: (date?: Date) => Time;
|
|
152
|
-
/**
|
|
153
|
-
* A function to get the maximum value of the time.
|
|
154
|
-
*/
|
|
155
|
-
maxTime?: (date?: Date) => Time;
|
|
156
|
-
/**
|
|
157
|
-
* A filter function to do more specific time filtering. This could be e.g. The removal of lunch breaks.
|
|
158
|
-
*/
|
|
159
|
-
filterTime?: ((time: Time) => boolean) | (() => boolean);
|
|
160
|
-
}
|
|
161
|
-
/**
|
|
162
|
-
* Definition for an array of DateRanges.
|
|
163
|
-
*/
|
|
164
|
-
export interface DateRangeArrayDecoratorConfig extends ArrayTableDecoratorConfig<DateRange> {
|
|
165
|
-
itemType: DecoratorTypes.DATE_RANGE;
|
|
166
|
-
/**
|
|
167
|
-
* A function to get the minimum value of the start date.
|
|
168
|
-
*/
|
|
169
|
-
minStart?: (date?: Date) => Date;
|
|
170
|
-
/**
|
|
171
|
-
* A function to get the maximum value of the start date.
|
|
172
|
-
*/
|
|
173
|
-
maxStart?: (date?: Date) => Date;
|
|
174
|
-
/**
|
|
175
|
-
* A function to get the minimum value of the end date.
|
|
176
|
-
*/
|
|
177
|
-
minEnd?: (date?: Date) => Date;
|
|
178
|
-
/**
|
|
179
|
-
* A function to get the maximum value of the end date.
|
|
180
|
-
*/
|
|
181
|
-
maxEnd?: (date?: Date) => Date;
|
|
182
|
-
/**
|
|
183
|
-
* A filter function to do more specific filtering on the disallowed end date values. This could be the removal of e.g. All weekends.
|
|
184
|
-
*/
|
|
185
|
-
filter?: DateFilterFn<Date>;
|
|
186
|
-
/**
|
|
187
|
-
* The placeholder for the start date of the date range picker.
|
|
188
|
-
* @default "Start"
|
|
189
|
-
*/
|
|
190
|
-
placeholderStart?: string;
|
|
191
|
-
/**
|
|
192
|
-
* The placeholder for the end date of the date range picker.
|
|
193
|
-
* @default "End"
|
|
194
|
-
*/
|
|
195
|
-
placeholderEnd?: string;
|
|
196
|
-
}
|
|
197
|
-
/**
|
|
198
|
-
* Definition for an array of strings displayed as a chips list.
|
|
199
|
-
*/
|
|
200
|
-
export interface StringChipsArrayDecoratorConfig extends ArrayDecoratorConfig<string[]> {
|
|
201
|
-
itemType: DecoratorTypes.STRING;
|
|
202
|
-
/**
|
|
203
|
-
* The font awesome icon used to remove an entry from the array.
|
|
204
|
-
* @default faCircleMinus
|
|
205
|
-
*/
|
|
206
|
-
deleteIcon?: IconDefinition;
|
|
207
|
-
/**
|
|
208
|
-
* The minimum required length of the string.
|
|
209
|
-
*/
|
|
210
|
-
minLength?: number;
|
|
211
|
-
/**
|
|
212
|
-
* The maximum required length of the string.
|
|
213
|
-
*/
|
|
214
|
-
maxLength?: number;
|
|
215
|
-
/**
|
|
216
|
-
* A regex used for validation.
|
|
217
|
-
*/
|
|
218
|
-
regex?: RegExp;
|
|
219
|
-
}
|
|
220
|
-
/**
|
|
221
|
-
* Definition for an array of autocomplete strings displayed as a chips list.
|
|
222
|
-
*/
|
|
223
|
-
export interface AutocompleteStringChipsArrayDecoratorConfig extends ArrayDecoratorConfig<string[]> {
|
|
224
|
-
itemType: DecoratorTypes.STRING_AUTOCOMPLETE;
|
|
225
|
-
/**
|
|
226
|
-
* The icon used to remove an entry from the array.
|
|
227
|
-
* @default faCircleMinus
|
|
228
|
-
*/
|
|
229
|
-
deleteIcon?: IconDefinition;
|
|
230
|
-
/**
|
|
231
|
-
* The autocomplete values.
|
|
232
|
-
*/
|
|
233
|
-
autocompleteValues: StringAutocompleteValues;
|
|
234
|
-
/**
|
|
235
|
-
* The minimum required length of the string.
|
|
236
|
-
*/
|
|
237
|
-
minLength?: number;
|
|
238
|
-
/**
|
|
239
|
-
* The maximum required length of the string.
|
|
240
|
-
*/
|
|
241
|
-
maxLength?: number;
|
|
242
|
-
/**
|
|
243
|
-
* A regex used for validation.
|
|
244
|
-
*/
|
|
245
|
-
regex?: RegExp;
|
|
246
|
-
/**
|
|
247
|
-
* Whether or not valid inputs should be restricted to the autocomplete options.
|
|
248
|
-
* @default false
|
|
249
|
-
*/
|
|
250
|
-
restrictToOptions?: boolean;
|
|
251
|
-
}
|
|
252
|
-
export {};
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { AutocompleteStringChipsArrayDecoratorConfig, DateArrayDecoratorConfig, DateRangeArrayDecoratorConfig, DateTimeArrayDecoratorConfig, EntityArrayDecoratorConfig, StringChipsArrayDecoratorConfig } from './array-decorator.data';
|
|
2
|
-
import { BaseEntityType } from '../../classes/entity.model';
|
|
3
|
-
/**
|
|
4
|
-
* Decorator for setting and getting array property metadata.
|
|
5
|
-
* @param metadata - The metadata of the array property.
|
|
6
|
-
* @returns The method that defines the metadata.
|
|
7
|
-
* @throws When the given type of the array-items is unknown.
|
|
8
|
-
*/
|
|
9
|
-
export declare function array<EntityType extends BaseEntityType<EntityType>>(metadata: EntityArrayDecoratorConfig<EntityType> | StringChipsArrayDecoratorConfig | AutocompleteStringChipsArrayDecoratorConfig | DateArrayDecoratorConfig | DateTimeArrayDecoratorConfig | DateRangeArrayDecoratorConfig): (target: object, propertyKey: string) => void;
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { DecoratorType, DecoratorTypes } from './decorator-types.enum';
|
|
2
|
-
/**
|
|
3
|
-
* The base decorator for setting metadata on properties.
|
|
4
|
-
* @param metadata - The metadata to define.
|
|
5
|
-
* @param type - The type of metadata.
|
|
6
|
-
* @param metadataKeysToReset - Any metadata keys which values should be set to undefined on reset.
|
|
7
|
-
* @returns The method that sets the metadata.
|
|
8
|
-
*/
|
|
9
|
-
export declare function baseProperty<T extends DecoratorTypes, CustomMetadataType extends Record<string, unknown>>(metadata: DecoratorType<T, CustomMetadataType>, type: T, metadataKeysToReset?: string[]): (target: object, propertyKey: string) => void;
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
import { AutocompleteStringChipsArrayDecoratorConfigInternal, DateArrayDecoratorConfigInternal, DateRangeArrayDecoratorConfigInternal, DateTimeArrayDecoratorConfigInternal, EntityArrayDecoratorConfigInternal, StringChipsArrayDecoratorConfigInternal } from '../array/array-decorator-internal.data';
|
|
2
|
-
import { CheckboxBooleanDecoratorConfigInternal, DropdownBooleanDecoratorConfigInternal, ToggleBooleanDecoratorConfigInternal } from '../boolean/boolean-decorator-internal.data';
|
|
3
|
-
import { CustomDecoratorConfigInternal } from '../custom/custom-decorator-internal.data';
|
|
4
|
-
import { DateRangeDateDecoratorConfigInternal, DateTimeDateDecoratorConfigInternal, DefaultDateDecoratorConfigInternal } from '../date/date-decorator-internal.data';
|
|
5
|
-
import { DefaultFileDecoratorConfigInternal, ImageFileDecoratorConfigInternal } from '../file/file-decorator-internal.data';
|
|
6
|
-
import { HasManyDecoratorConfigInternal } from '../has-many/has-many-decorator-internal.data';
|
|
7
|
-
import { DefaultNumberDecoratorConfigInternal, DropdownNumberDecoratorConfigInternal, SliderNumberDecoratorConfigInternal } from '../number/number-decorator-internal.data';
|
|
8
|
-
import { DefaultObjectDecoratorConfigInternal, DropdownObjectDecoratorConfigInternal } from '../object/object-decorator-internal.data';
|
|
9
|
-
import { ReferencesManyDecoratorConfigInternal } from '../references-many/references-many-decorator-internal.data';
|
|
10
|
-
import { ReferencesOneDecoratorConfigInternal } from '../references-one/references-one-decorator-internal.data';
|
|
11
|
-
import { AutocompleteStringDecoratorConfigInternal, DefaultStringDecoratorConfigInternal, DropdownStringDecoratorConfigInternal, PasswordStringDecoratorConfigInternal, TextboxStringDecoratorConfigInternal } from '../string/string-decorator-internal.data';
|
|
12
|
-
/**
|
|
13
|
-
* The enum Values for all the different DecoratorTypes.
|
|
14
|
-
*/
|
|
15
|
-
export declare enum DecoratorTypes {
|
|
16
|
-
STRING = "string",
|
|
17
|
-
STRING_DROPDOWN = "stringDropdown",
|
|
18
|
-
STRING_AUTOCOMPLETE = "stringAutocomplete",
|
|
19
|
-
STRING_TEXTBOX = "stringTextbox",
|
|
20
|
-
STRING_PASSWORD = "stringPassword",
|
|
21
|
-
NUMBER = "number",
|
|
22
|
-
NUMBER_DROPDOWN = "numberDropdown",
|
|
23
|
-
NUMBER_SLIDER = "numberSlider",
|
|
24
|
-
BOOLEAN_CHECKBOX = "boolean",
|
|
25
|
-
BOOLEAN_TOGGLE = "booleanToggle",
|
|
26
|
-
BOOLEAN_DROPDOWN = "booleanDropdown",
|
|
27
|
-
OBJECT = "object",
|
|
28
|
-
OBJECT_DROPDOWN = "objectDropdown",
|
|
29
|
-
ARRAY = "array",
|
|
30
|
-
ARRAY_DATE = "arrayDate",
|
|
31
|
-
ARRAY_DATE_TIME = "arrayDateTime",
|
|
32
|
-
ARRAY_DATE_RANGE = "arrayDateRange",
|
|
33
|
-
ARRAY_STRING_CHIPS = "arrayStringChips",
|
|
34
|
-
ARRAY_STRING_AUTOCOMPLETE_CHIPS = "arrayStringAutocompleteChips",
|
|
35
|
-
DATE = "date",
|
|
36
|
-
DATE_RANGE = "dateRange",
|
|
37
|
-
DATE_TIME = "dateTime",
|
|
38
|
-
FILE_DEFAULT = "fileDefault",
|
|
39
|
-
FILE_IMAGE = "fileImage",
|
|
40
|
-
REFERENCES_MANY = "referencesMany",
|
|
41
|
-
REFERENCES_ONE = "referencesOne",
|
|
42
|
-
HAS_MANY = "hasMany",
|
|
43
|
-
CUSTOM = "custom"
|
|
44
|
-
}
|
|
45
|
-
/**
|
|
46
|
-
* Gives the metadata-config Type based on the DecoratorTypes enum.
|
|
47
|
-
*/
|
|
48
|
-
export type DecoratorType<T, CustomMetadataType extends Record<string, unknown>> = T extends DecoratorTypes.STRING ? DefaultStringDecoratorConfigInternal : T extends DecoratorTypes.STRING_TEXTBOX ? TextboxStringDecoratorConfigInternal : T extends DecoratorTypes.STRING_DROPDOWN ? DropdownStringDecoratorConfigInternal : T extends DecoratorTypes.STRING_AUTOCOMPLETE ? AutocompleteStringDecoratorConfigInternal : T extends DecoratorTypes.STRING_PASSWORD ? PasswordStringDecoratorConfigInternal : T extends DecoratorTypes.NUMBER ? DefaultNumberDecoratorConfigInternal : T extends DecoratorTypes.NUMBER_DROPDOWN ? DropdownNumberDecoratorConfigInternal : T extends DecoratorTypes.NUMBER_SLIDER ? SliderNumberDecoratorConfigInternal : T extends DecoratorTypes.BOOLEAN_CHECKBOX ? CheckboxBooleanDecoratorConfigInternal : T extends DecoratorTypes.BOOLEAN_TOGGLE ? ToggleBooleanDecoratorConfigInternal : T extends DecoratorTypes.BOOLEAN_DROPDOWN ? DropdownBooleanDecoratorConfigInternal : T extends DecoratorTypes.OBJECT ? DefaultObjectDecoratorConfigInternal<any> : T extends DecoratorTypes.OBJECT_DROPDOWN ? DropdownObjectDecoratorConfigInternal<any> : T extends DecoratorTypes.ARRAY ? EntityArrayDecoratorConfigInternal<any> : T extends DecoratorTypes.ARRAY_DATE ? DateArrayDecoratorConfigInternal : T extends DecoratorTypes.ARRAY_DATE_TIME ? DateTimeArrayDecoratorConfigInternal : T extends DecoratorTypes.ARRAY_DATE_RANGE ? DateRangeArrayDecoratorConfigInternal : T extends DecoratorTypes.ARRAY_STRING_CHIPS ? StringChipsArrayDecoratorConfigInternal : T extends DecoratorTypes.ARRAY_STRING_AUTOCOMPLETE_CHIPS ? AutocompleteStringChipsArrayDecoratorConfigInternal : T extends DecoratorTypes.DATE ? DefaultDateDecoratorConfigInternal : T extends DecoratorTypes.DATE_RANGE ? DateRangeDateDecoratorConfigInternal : T extends DecoratorTypes.DATE_TIME ? DateTimeDateDecoratorConfigInternal : T extends DecoratorTypes.FILE_DEFAULT ? DefaultFileDecoratorConfigInternal : T extends DecoratorTypes.FILE_IMAGE ? ImageFileDecoratorConfigInternal : T extends DecoratorTypes.REFERENCES_MANY ? ReferencesManyDecoratorConfigInternal<any> : T extends DecoratorTypes.REFERENCES_ONE ? ReferencesOneDecoratorConfigInternal<any> : T extends DecoratorTypes.HAS_MANY ? HasManyDecoratorConfigInternal<any, any> : T extends DecoratorTypes.CUSTOM ? CustomDecoratorConfigInternal<any, any, CustomMetadataType, any> : never;
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* The definition for a dropdown value.
|
|
3
|
-
* Consists of the name to display in the dropdown and the actual value.
|
|
4
|
-
*/
|
|
5
|
-
export interface DropdownValue<T> {
|
|
6
|
-
/**
|
|
7
|
-
* The name to display in the dropdown.
|
|
8
|
-
*/
|
|
9
|
-
displayName: string;
|
|
10
|
-
/**
|
|
11
|
-
* The actual value.
|
|
12
|
-
*/
|
|
13
|
-
value: T;
|
|
14
|
-
}
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import { Col, Position, PropertyDecoratorConfig } from './property-decorator.data';
|
|
2
|
-
/**
|
|
3
|
-
* The internal Position. Sets default values and validates user input.
|
|
4
|
-
*/
|
|
5
|
-
declare class PositionInternal implements Position {
|
|
6
|
-
row: number;
|
|
7
|
-
order: number;
|
|
8
|
-
tab: number;
|
|
9
|
-
tabName?: string;
|
|
10
|
-
constructor(data?: Position);
|
|
11
|
-
private validateInput;
|
|
12
|
-
}
|
|
13
|
-
/**
|
|
14
|
-
* The internal PropertyDecoratorConfig. Sets default values.
|
|
15
|
-
*/
|
|
16
|
-
export declare abstract class PropertyDecoratorConfigInternal<ValueType> implements PropertyDecoratorConfig<ValueType> {
|
|
17
|
-
display: (entity: unknown) => boolean;
|
|
18
|
-
displayName: string;
|
|
19
|
-
required: ((entity: unknown) => boolean);
|
|
20
|
-
omitForCreate: boolean;
|
|
21
|
-
omitForUpdate: boolean;
|
|
22
|
-
defaultWidths: [Col, Col, Col];
|
|
23
|
-
position: PositionInternal;
|
|
24
|
-
isReadOnly: (entity: unknown) => boolean;
|
|
25
|
-
default?: () => ValueType;
|
|
26
|
-
change?: (entity: unknown) => void;
|
|
27
|
-
constructor(data: PropertyDecoratorConfig<ValueType>);
|
|
28
|
-
/**
|
|
29
|
-
* Converts the default value to a function or undefined.
|
|
30
|
-
* @param value - The default value provided by the metadata.
|
|
31
|
-
* @returns A function that returns a default value or undefined.
|
|
32
|
-
*/
|
|
33
|
-
protected defaultToFunction(value?: ValueType | (() => ValueType)): (() => ValueType) | undefined;
|
|
34
|
-
/**
|
|
35
|
-
* Converts the given boolean or boolean function to a boolean function.
|
|
36
|
-
* @param value - The value to convert.
|
|
37
|
-
* @returns A function that resolves to a boolean.
|
|
38
|
-
*/
|
|
39
|
-
protected booleanToFunction(value: boolean | ((entity: unknown) => boolean)): (entity: unknown) => boolean;
|
|
40
|
-
}
|
|
41
|
-
export {};
|
|
@@ -1,88 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* A bootstrap column value (a range from 1 - 12).
|
|
3
|
-
*/
|
|
4
|
-
export type Col = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12;
|
|
5
|
-
/**
|
|
6
|
-
* The base options for all propertyDecorators.
|
|
7
|
-
*/
|
|
8
|
-
export declare abstract class PropertyDecoratorConfig<ValueType> {
|
|
9
|
-
/**
|
|
10
|
-
* Whether or not the Property is displayed at all.
|
|
11
|
-
* @default true
|
|
12
|
-
*/
|
|
13
|
-
display?: boolean | ((entity: any) => boolean);
|
|
14
|
-
/**
|
|
15
|
-
* The name of the property used as a label for form fields.
|
|
16
|
-
*/
|
|
17
|
-
displayName: string;
|
|
18
|
-
/**
|
|
19
|
-
* Whether or not the Property is required.
|
|
20
|
-
* @default true
|
|
21
|
-
*/
|
|
22
|
-
required?: boolean | ((entity: any) => boolean);
|
|
23
|
-
/**
|
|
24
|
-
* Whether or not the property gets omitted when creating new Entities.
|
|
25
|
-
* @default false
|
|
26
|
-
*/
|
|
27
|
-
omitForCreate?: boolean;
|
|
28
|
-
/**
|
|
29
|
-
* Whether or not the property gets omitted when updating Entities.
|
|
30
|
-
* @default false
|
|
31
|
-
*/
|
|
32
|
-
omitForUpdate?: boolean;
|
|
33
|
-
/**
|
|
34
|
-
* Defines the width of the input property when used inside the default create or edit dialog.
|
|
35
|
-
* Has 3 values for different breakpoints for simple responsive design based on bootstrap (1-12).
|
|
36
|
-
* The first value sets the columns for the screen size lg, the second for md and the third for sm.
|
|
37
|
-
* @default [6, 6, 12]
|
|
38
|
-
*/
|
|
39
|
-
defaultWidths?: [Col, Col, Col];
|
|
40
|
-
/**
|
|
41
|
-
* Specifies the how to position this property when using default create/edit dialogs.
|
|
42
|
-
* @default { row: -1, order: -1} (Adds the property at the end)
|
|
43
|
-
*/
|
|
44
|
-
position?: Position;
|
|
45
|
-
/**
|
|
46
|
-
* Whether or not this property is readonly.
|
|
47
|
-
* Can either be a boolean or a function returning a boolean.
|
|
48
|
-
*/
|
|
49
|
-
isReadOnly?: boolean | ((entity: any) => boolean);
|
|
50
|
-
/**
|
|
51
|
-
* The value that the property should be prefilled with. Only active in create mode.
|
|
52
|
-
*/
|
|
53
|
-
default?: ValueType | (() => ValueType);
|
|
54
|
-
/**
|
|
55
|
-
* A function that runs just before the inputChangeEvent every time the property is changed.
|
|
56
|
-
*/
|
|
57
|
-
change?: (entity: any) => void;
|
|
58
|
-
}
|
|
59
|
-
/**
|
|
60
|
-
* The options for positioning a property when using default create/edit dialogs.
|
|
61
|
-
*/
|
|
62
|
-
export interface Position {
|
|
63
|
-
/**
|
|
64
|
-
* Specifies a tab in which this property is displayed.
|
|
65
|
-
* If no property has the tab metadata specified no tabs are displayed.
|
|
66
|
-
* Ordering is ascending.
|
|
67
|
-
* @default -1 (sets this property in the first tab)
|
|
68
|
-
*/
|
|
69
|
-
tab?: number;
|
|
70
|
-
/**
|
|
71
|
-
* Specifies the name of the tab. Can only be set by one property in each tab.
|
|
72
|
-
* Requires "tab" to be set.
|
|
73
|
-
* @default `Tab ${numberOfTheTab}`
|
|
74
|
-
*/
|
|
75
|
-
tabName?: string;
|
|
76
|
-
/**
|
|
77
|
-
* Specifies the row in which this property is displayed.
|
|
78
|
-
* Ordering is ascending.
|
|
79
|
-
* @default -1 (sets this property after the last row)
|
|
80
|
-
*/
|
|
81
|
-
row?: number;
|
|
82
|
-
/**
|
|
83
|
-
* Specifies order of the input property inside the specified row.
|
|
84
|
-
* Ordering is ascending.
|
|
85
|
-
* @default -1 (sets this property at the end of the row)
|
|
86
|
-
*/
|
|
87
|
-
order?: number;
|
|
88
|
-
}
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { CheckboxBooleanDecoratorConfig, DropdownBooleanDecoratorConfig, ToggleBooleanDecoratorConfig } from './boolean-decorator.data';
|
|
2
|
-
import { NgxGlobalDefaultValues } from '../../global-configuration-values';
|
|
3
|
-
import { PropertyDecoratorConfigInternal } from '../base/property-decorator-internal.data';
|
|
4
|
-
/**
|
|
5
|
-
* The internal DropdownBooleanDecoratorConfig. Sets default values.
|
|
6
|
-
*/
|
|
7
|
-
export declare class DropdownBooleanDecoratorConfigInternal extends PropertyDecoratorConfigInternal<boolean> implements DropdownBooleanDecoratorConfig {
|
|
8
|
-
displayStyle: 'dropdown';
|
|
9
|
-
dropdownTrue: string;
|
|
10
|
-
dropdownFalse: string;
|
|
11
|
-
constructor(data: DropdownBooleanDecoratorConfig, globalConfig: NgxGlobalDefaultValues);
|
|
12
|
-
}
|
|
13
|
-
/**
|
|
14
|
-
* The internal CheckboxBooleanDecoratorConfig. Sets default values.
|
|
15
|
-
*/
|
|
16
|
-
export declare class CheckboxBooleanDecoratorConfigInternal extends PropertyDecoratorConfigInternal<boolean> implements CheckboxBooleanDecoratorConfig {
|
|
17
|
-
displayStyle: 'checkbox';
|
|
18
|
-
constructor(data: CheckboxBooleanDecoratorConfig);
|
|
19
|
-
}
|
|
20
|
-
/**
|
|
21
|
-
* The internal ToggleBooleanDecoratorConfig. Sets default values.
|
|
22
|
-
*/
|
|
23
|
-
export declare class ToggleBooleanDecoratorConfigInternal extends PropertyDecoratorConfigInternal<boolean> implements ToggleBooleanDecoratorConfig {
|
|
24
|
-
displayStyle: 'toggle';
|
|
25
|
-
constructor(data: ToggleBooleanDecoratorConfig);
|
|
26
|
-
}
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
import { PropertyDecoratorConfig } from '../base/property-decorator.data';
|
|
2
|
-
/**
|
|
3
|
-
* The Definition for the @boolean metadata.
|
|
4
|
-
*/
|
|
5
|
-
declare abstract class BooleanDecoratorConfig extends PropertyDecoratorConfig<boolean> {
|
|
6
|
-
/**
|
|
7
|
-
* Whether to display the booleans as a checkbox, a toggle button or as a dropdown.
|
|
8
|
-
*/
|
|
9
|
-
displayStyle: 'checkbox' | 'dropdown' | 'toggle';
|
|
10
|
-
}
|
|
11
|
-
/**
|
|
12
|
-
* The configuration options for a boolean property displayed in a dropdown.
|
|
13
|
-
*/
|
|
14
|
-
export interface DropdownBooleanDecoratorConfig extends BooleanDecoratorConfig {
|
|
15
|
-
displayStyle: 'dropdown';
|
|
16
|
-
/**
|
|
17
|
-
* The name of the true value if displayStyle dropdown is used.
|
|
18
|
-
* @default 'Yes'
|
|
19
|
-
*/
|
|
20
|
-
dropdownTrue?: string;
|
|
21
|
-
/**
|
|
22
|
-
* The name of the false value if displayStyle dropdown is used.
|
|
23
|
-
* @default 'No'
|
|
24
|
-
*/
|
|
25
|
-
dropdownFalse?: string;
|
|
26
|
-
}
|
|
27
|
-
/**
|
|
28
|
-
* The configuration options for a boolean property displayed as a checkbox.
|
|
29
|
-
*/
|
|
30
|
-
export interface CheckboxBooleanDecoratorConfig extends BooleanDecoratorConfig {
|
|
31
|
-
displayStyle: 'checkbox';
|
|
32
|
-
}
|
|
33
|
-
/**
|
|
34
|
-
* The configuration options for a boolean property displayed as a mat-toggle.
|
|
35
|
-
*/
|
|
36
|
-
export interface ToggleBooleanDecoratorConfig extends BooleanDecoratorConfig {
|
|
37
|
-
displayStyle: 'toggle';
|
|
38
|
-
}
|
|
39
|
-
export {};
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { CheckboxBooleanDecoratorConfig, DropdownBooleanDecoratorConfig, ToggleBooleanDecoratorConfig } from './boolean-decorator.data';
|
|
2
|
-
/**
|
|
3
|
-
* Decorator for setting and getting boolean property metadata.
|
|
4
|
-
* @param metadata - The metadata of the boolean property.
|
|
5
|
-
* @returns The method that defines the metadata.
|
|
6
|
-
*/
|
|
7
|
-
export declare function boolean(metadata: CheckboxBooleanDecoratorConfig | ToggleBooleanDecoratorConfig | DropdownBooleanDecoratorConfig): (target: object, propertyKey: string) => void;
|