@researchdatabox/sails-ng-common 0.2.1 → 5.0.0-RC1
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/dist/src/config/base-field-component.model.d.ts +26 -0
- package/dist/src/config/base-field-component.model.js +29 -0
- package/dist/src/config/base-field-component.outline.d.ts +108 -0
- package/dist/src/config/base-field-component.outline.js +3 -0
- package/dist/src/config/component/accordion.model.d.ts +103 -0
- package/dist/src/config/component/accordion.model.js +127 -0
- package/dist/src/config/component/accordion.outline.d.ts +162 -0
- package/dist/src/config/component/accordion.outline.js +13 -0
- package/dist/src/config/component/action-row-layout.model.d.ts +28 -0
- package/dist/src/config/component/action-row-layout.model.js +35 -0
- package/dist/src/config/component/action-row-layout.outline.d.ts +36 -0
- package/dist/src/config/component/action-row-layout.outline.js +6 -0
- package/dist/src/config/component/cancel-button.model.d.ts +48 -0
- package/dist/src/config/component/cancel-button.model.js +58 -0
- package/dist/src/config/component/cancel-button.outline.d.ts +85 -0
- package/dist/src/config/component/cancel-button.outline.js +6 -0
- package/dist/src/config/component/checkbox-input.model.d.ts +67 -0
- package/dist/src/config/component/checkbox-input.model.js +79 -0
- package/dist/src/config/component/checkbox-input.outline.d.ts +93 -0
- package/dist/src/config/component/checkbox-input.outline.js +8 -0
- package/dist/src/config/component/checkbox-tree.model.d.ts +68 -0
- package/dist/src/config/component/checkbox-tree.model.js +80 -0
- package/dist/src/config/component/checkbox-tree.outline.d.ts +105 -0
- package/dist/src/config/component/checkbox-tree.outline.js +8 -0
- package/dist/src/config/component/content.model.d.ts +46 -0
- package/dist/src/config/component/content.model.js +56 -0
- package/dist/src/config/component/content.outline.d.ts +74 -0
- package/dist/src/config/component/content.outline.js +6 -0
- package/dist/src/config/component/data-location.model.d.ts +83 -0
- package/dist/src/config/component/data-location.model.js +95 -0
- package/dist/src/config/component/data-location.outline.d.ts +124 -0
- package/dist/src/config/component/data-location.outline.js +6 -0
- package/dist/src/config/component/date-input.model.d.ts +67 -0
- package/dist/src/config/component/date-input.model.js +80 -0
- package/dist/src/config/component/date-input.outline.d.ts +88 -0
- package/dist/src/config/component/date-input.outline.js +8 -0
- package/dist/src/config/component/default-layout.model.d.ts +22 -0
- package/dist/src/config/component/default-layout.model.js +30 -0
- package/dist/src/config/component/default-layout.outline.d.ts +29 -0
- package/dist/src/config/component/default-layout.outline.js +5 -0
- package/dist/src/config/component/delete-button.model.d.ts +46 -0
- package/dist/src/config/component/delete-button.model.js +48 -0
- package/dist/src/config/component/delete-button.outline.d.ts +89 -0
- package/dist/src/config/component/delete-button.outline.js +5 -0
- package/dist/src/config/component/dropdown-input.model.d.ts +65 -0
- package/dist/src/config/component/dropdown-input.model.js +78 -0
- package/dist/src/config/component/dropdown-input.outline.d.ts +92 -0
- package/dist/src/config/component/dropdown-input.outline.js +8 -0
- package/dist/src/config/component/file-upload.model.d.ts +67 -0
- package/dist/src/config/component/file-upload.model.js +81 -0
- package/dist/src/config/component/file-upload.outline.d.ts +99 -0
- package/dist/src/config/component/file-upload.outline.js +8 -0
- package/dist/src/config/component/group.model.d.ts +61 -0
- package/dist/src/config/component/group.model.js +75 -0
- package/dist/src/config/component/group.outline.d.ts +83 -0
- package/dist/src/config/component/group.outline.js +8 -0
- package/dist/src/config/component/inline-layout.model.d.ts +22 -0
- package/dist/src/config/component/inline-layout.model.js +29 -0
- package/dist/src/config/component/inline-layout.outline.d.ts +29 -0
- package/dist/src/config/component/inline-layout.outline.js +5 -0
- package/dist/src/config/component/integration-status.model.d.ts +49 -0
- package/dist/src/config/component/integration-status.model.js +65 -0
- package/dist/src/config/component/integration-status.outline.d.ts +61 -0
- package/dist/src/config/component/integration-status.outline.js +5 -0
- package/dist/src/config/component/map.model.d.ts +69 -0
- package/dist/src/config/component/map.model.js +86 -0
- package/dist/src/config/component/map.outline.d.ts +110 -0
- package/dist/src/config/component/map.outline.js +8 -0
- package/dist/src/config/component/pdf-list.model.d.ts +68 -0
- package/dist/src/config/component/pdf-list.model.js +71 -0
- package/dist/src/config/component/pdf-list.outline.d.ts +97 -0
- package/dist/src/config/component/pdf-list.outline.js +6 -0
- package/dist/src/config/component/publish-data-location-refresh.model.d.ts +39 -0
- package/dist/src/config/component/publish-data-location-refresh.model.js +52 -0
- package/dist/src/config/component/publish-data-location-refresh.outline.d.ts +58 -0
- package/dist/src/config/component/publish-data-location-refresh.outline.js +5 -0
- package/dist/src/config/component/publish-data-location-selector.model.d.ts +78 -0
- package/dist/src/config/component/publish-data-location-selector.model.js +104 -0
- package/dist/src/config/component/publish-data-location-selector.outline.d.ts +110 -0
- package/dist/src/config/component/publish-data-location-selector.outline.js +6 -0
- package/dist/src/config/component/question-tree.helper.d.ts +58 -0
- package/dist/src/config/component/question-tree.helper.js +291 -0
- package/dist/src/config/component/question-tree.model.d.ts +64 -0
- package/dist/src/config/component/question-tree.model.js +80 -0
- package/dist/src/config/component/question-tree.outline.d.ts +314 -0
- package/dist/src/config/component/question-tree.outline.js +9 -0
- package/dist/src/config/component/radio-input.model.d.ts +65 -0
- package/dist/src/config/component/radio-input.model.js +77 -0
- package/dist/src/config/component/radio-input.outline.d.ts +91 -0
- package/dist/src/config/component/radio-input.outline.js +8 -0
- package/dist/src/config/component/record-metadata-retriever.model.d.ts +41 -0
- package/dist/src/config/component/record-metadata-retriever.model.js +57 -0
- package/dist/src/config/component/record-metadata-retriever.outline.d.ts +53 -0
- package/dist/src/config/component/record-metadata-retriever.outline.js +5 -0
- package/dist/src/config/component/record-selector.model.d.ts +61 -0
- package/dist/src/config/component/record-selector.model.js +61 -0
- package/dist/src/config/component/record-selector.outline.d.ts +91 -0
- package/dist/src/config/component/record-selector.outline.js +6 -0
- package/dist/src/config/component/repeatable.model.d.ts +91 -0
- package/dist/src/config/component/repeatable.model.js +112 -0
- package/dist/src/config/component/repeatable.outline.d.ts +115 -0
- package/dist/src/config/component/repeatable.outline.js +10 -0
- package/dist/src/config/component/reusable.model.d.ts +42 -0
- package/dist/src/config/component/reusable.model.js +57 -0
- package/dist/src/config/component/reusable.outline.d.ts +55 -0
- package/dist/src/config/component/reusable.outline.js +6 -0
- package/dist/src/config/component/rich-text-editor.model.d.ts +65 -0
- package/dist/src/config/component/rich-text-editor.model.js +79 -0
- package/dist/src/config/component/rich-text-editor.outline.d.ts +92 -0
- package/dist/src/config/component/rich-text-editor.outline.js +8 -0
- package/dist/src/config/component/save-button.model.d.ts +49 -0
- package/dist/src/config/component/save-button.model.js +59 -0
- package/dist/src/config/component/save-button.outline.d.ts +90 -0
- package/dist/src/config/component/save-button.outline.js +6 -0
- package/dist/src/config/component/save-status.model.d.ts +42 -0
- package/dist/src/config/component/save-status.model.js +60 -0
- package/dist/src/config/component/save-status.outline.d.ts +58 -0
- package/dist/src/config/component/save-status.outline.js +6 -0
- package/dist/src/config/component/simple-input.model.d.ts +62 -0
- package/dist/src/config/component/simple-input.model.js +75 -0
- package/dist/src/config/component/simple-input.outline.d.ts +86 -0
- package/dist/src/config/component/simple-input.outline.js +9 -0
- package/dist/src/config/component/suggested-validation-summary.model.d.ts +45 -0
- package/dist/src/config/component/suggested-validation-summary.model.js +61 -0
- package/dist/src/config/component/suggested-validation-summary.outline.d.ts +57 -0
- package/dist/src/config/component/suggested-validation-summary.outline.js +5 -0
- package/dist/src/config/component/tab-content.model.d.ts +63 -0
- package/dist/src/config/component/tab-content.model.js +77 -0
- package/dist/src/config/component/tab-content.outline.d.ts +98 -0
- package/dist/src/config/component/tab-content.outline.js +8 -0
- package/dist/src/config/component/tab-nav-button.model.d.ts +45 -0
- package/dist/src/config/component/tab-nav-button.model.js +55 -0
- package/dist/src/config/component/tab-nav-button.outline.d.ts +70 -0
- package/dist/src/config/component/tab-nav-button.outline.js +6 -0
- package/dist/src/config/component/tab.model.d.ts +71 -0
- package/dist/src/config/component/tab.model.js +84 -0
- package/dist/src/config/component/tab.outline.d.ts +112 -0
- package/dist/src/config/component/tab.outline.js +9 -0
- package/dist/src/config/component/text-area.model.d.ts +63 -0
- package/dist/src/config/component/text-area.model.js +76 -0
- package/dist/src/config/component/text-area.outline.d.ts +87 -0
- package/dist/src/config/component/text-area.outline.js +8 -0
- package/dist/src/config/component/typeahead-input.model.d.ts +83 -0
- package/dist/src/config/component/typeahead-input.model.js +97 -0
- package/dist/src/config/component/typeahead-input.outline.d.ts +199 -0
- package/dist/src/config/component/typeahead-input.outline.js +10 -0
- package/dist/src/config/component/validation-summary.model.d.ts +42 -0
- package/dist/src/config/component/validation-summary.model.js +60 -0
- package/dist/src/config/component/validation-summary.outline.d.ts +63 -0
- package/dist/src/config/component/validation-summary.outline.js +6 -0
- package/dist/src/config/dictionary.model.d.ts +648 -0
- package/dist/src/config/dictionary.model.js +181 -0
- package/dist/src/config/dictionary.outline.d.ts +96 -0
- package/dist/src/config/dictionary.outline.js +3 -0
- package/dist/src/config/field-component.model.d.ts +7 -0
- package/dist/src/config/field-component.model.js +11 -0
- package/dist/src/config/field-component.outline.d.ts +20 -0
- package/dist/src/config/field-component.outline.js +3 -0
- package/dist/src/config/field-layout.model.d.ts +19 -0
- package/dist/src/config/field-layout.model.js +23 -0
- package/dist/src/config/field-layout.outline.d.ts +42 -0
- package/dist/src/config/field-layout.outline.js +3 -0
- package/dist/src/config/field-model.model.d.ts +21 -0
- package/dist/src/config/field-model.model.js +24 -0
- package/dist/src/config/field-model.outline.d.ts +63 -0
- package/dist/src/config/field-model.outline.js +3 -0
- package/dist/src/config/field.model.d.ts +12 -0
- package/dist/src/config/field.model.js +12 -0
- package/dist/src/config/field.outline.d.ts +19 -0
- package/dist/src/config/field.outline.js +3 -0
- package/dist/src/config/form-behaviour.outline.d.ts +128 -0
- package/dist/src/config/form-behaviour.outline.js +40 -0
- package/dist/src/config/form-component.model.d.ts +38 -0
- package/dist/src/config/form-component.model.js +36 -0
- package/dist/src/config/form-component.outline.d.ts +305 -0
- package/dist/src/config/form-component.outline.js +27 -0
- package/dist/src/config/form-config.model.d.ts +33 -0
- package/dist/src/config/form-config.model.js +36 -0
- package/dist/src/config/form-config.outline.d.ts +111 -0
- package/dist/src/config/form-config.outline.js +3 -0
- package/dist/src/config/form-override.model.d.ts +146 -0
- package/dist/src/config/form-override.model.js +1523 -0
- package/dist/src/config/form-override.outline.d.ts +15 -0
- package/dist/src/config/form-override.outline.js +3 -0
- package/dist/src/config/form-prehydrate.outline.d.ts +17 -0
- package/dist/src/config/form-prehydrate.outline.js +5 -0
- package/dist/src/config/form-types.model.d.ts +6 -0
- package/dist/src/config/form-types.model.js +23 -0
- package/dist/src/config/form-types.outline.d.ts +48 -0
- package/dist/src/config/form-types.outline.js +137 -0
- package/dist/src/config/helpers.d.ts +31 -0
- package/dist/src/config/helpers.js +122 -0
- package/dist/src/config/names/naming-helpers.d.ts +112 -0
- package/dist/src/config/names/naming-helpers.js +188 -0
- package/dist/src/config/names/query-helpers.d.ts +43 -0
- package/dist/src/config/names/query-helpers.js +59 -0
- package/dist/src/config/shared.outline.d.ts +54 -0
- package/dist/src/config/shared.outline.js +41 -0
- package/dist/src/config/visitor/base.model.d.ts +143 -0
- package/dist/src/config/visitor/base.model.js +336 -0
- package/dist/src/config/visitor/base.outline.d.ts +146 -0
- package/dist/src/config/visitor/base.outline.js +3 -0
- package/dist/src/config/visitor/common.model.d.ts +119 -0
- package/dist/src/config/visitor/common.model.js +422 -0
- package/dist/src/date-format-helpers.d.ts +1 -0
- package/dist/src/date-format-helpers.js +21 -0
- package/dist/src/handlebars-helpers.d.ts +258 -0
- package/dist/src/handlebars-helpers.js +715 -0
- package/dist/src/html-helpers.d.ts +15 -0
- package/dist/src/html-helpers.js +42 -0
- package/dist/src/index.d.ts +118 -3
- package/dist/src/index.js +127 -2
- package/dist/src/jsonata-helpers.d.ts +40 -0
- package/dist/src/jsonata-helpers.js +118 -0
- package/dist/src/logger.interface.d.ts +14 -0
- package/dist/src/logger.interface.js +3 -0
- package/dist/src/record.model.d.ts +23 -0
- package/dist/src/record.model.js +19 -1
- package/dist/src/report.model.d.ts +46 -0
- package/dist/src/status.model.d.ts +22 -0
- package/dist/src/status.model.js +28 -0
- package/dist/src/template.outline.d.ts +82 -0
- package/dist/src/template.outline.js +14 -0
- package/dist/src/translation-helpers.d.ts +26 -0
- package/dist/src/translation-helpers.js +71 -0
- package/dist/src/validation/form.model.d.ts +306 -24
- package/dist/src/validation/form.model.js +29 -1
- package/dist/src/validation/helpers.d.ts +15 -7
- package/dist/src/validation/helpers.js +49 -13
- package/dist/src/validation/validators-support.d.ts +39 -2
- package/dist/src/validation/validators-support.js +162 -12
- package/dist/src/validation/validators.d.ts +28 -0
- package/dist/src/validation/validators.js +531 -0
- package/package.json +51 -34
- package/LICENSE +0 -674
- package/dist/src/validation/index.d.ts +0 -3
- package/dist/src/validation/index.js +0 -20
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import { FieldModelConfig, FieldModelDefinition } from "../field-model.model";
|
|
2
|
+
import { FormComponentDefinition } from "../form-component.model";
|
|
3
|
+
import { FormConfigVisitorOutline } from "../visitor/base.outline";
|
|
4
|
+
import { FieldComponentConfig, FieldComponentDefinition } from "../field-component.model";
|
|
5
|
+
import { AvailableFieldLayoutDefinitionOutlines } from "../dictionary.outline";
|
|
6
|
+
import { DateInputFieldComponentConfigOutline, DateInputFieldComponentDefinitionOutline, DateInputFieldModelConfigOutline, DateInputFieldModelDefinitionOutline, DateInputFormComponentDefinitionOutline, DateInputModelValueType } from "./date-input.outline";
|
|
7
|
+
export declare class DateInputFieldComponentConfig extends FieldComponentConfig implements DateInputFieldComponentConfigOutline {
|
|
8
|
+
placeholder?: string;
|
|
9
|
+
dateFormat?: string;
|
|
10
|
+
showWeekNumbers?: boolean;
|
|
11
|
+
containerClass?: string;
|
|
12
|
+
enableTimePicker?: boolean;
|
|
13
|
+
robustParsing?: boolean;
|
|
14
|
+
bsFullConfig?: any;
|
|
15
|
+
constructor();
|
|
16
|
+
}
|
|
17
|
+
export declare class DateInputFieldComponentDefinition extends FieldComponentDefinition implements DateInputFieldComponentDefinitionOutline {
|
|
18
|
+
class: "DateInputComponent";
|
|
19
|
+
config?: DateInputFieldComponentConfigOutline;
|
|
20
|
+
constructor();
|
|
21
|
+
accept(visitor: FormConfigVisitorOutline): Promise<void>;
|
|
22
|
+
}
|
|
23
|
+
export declare class DateInputFieldModelConfig extends FieldModelConfig<DateInputModelValueType> implements DateInputFieldModelConfigOutline {
|
|
24
|
+
constructor();
|
|
25
|
+
}
|
|
26
|
+
export declare class DateInputFieldModelDefinition extends FieldModelDefinition<DateInputModelValueType> implements DateInputFieldModelDefinitionOutline {
|
|
27
|
+
class: "DateInputModel";
|
|
28
|
+
config?: DateInputFieldModelConfigOutline;
|
|
29
|
+
constructor();
|
|
30
|
+
accept(visitor: FormConfigVisitorOutline): Promise<void>;
|
|
31
|
+
}
|
|
32
|
+
export declare class DateInputFormComponentDefinition extends FormComponentDefinition implements DateInputFormComponentDefinitionOutline {
|
|
33
|
+
component: DateInputFieldComponentDefinitionOutline;
|
|
34
|
+
model?: DateInputFieldModelDefinitionOutline;
|
|
35
|
+
layout?: AvailableFieldLayoutDefinitionOutlines;
|
|
36
|
+
constructor();
|
|
37
|
+
accept(visitor: FormConfigVisitorOutline): Promise<void>;
|
|
38
|
+
}
|
|
39
|
+
export declare const DateInputMap: ({
|
|
40
|
+
kind: "FieldComponentConfigKind";
|
|
41
|
+
def: typeof DateInputFieldComponentConfig;
|
|
42
|
+
class?: undefined;
|
|
43
|
+
} | {
|
|
44
|
+
kind: "FieldComponentDefinitionKind";
|
|
45
|
+
def: typeof DateInputFieldComponentDefinition;
|
|
46
|
+
class: "DateInputComponent";
|
|
47
|
+
} | {
|
|
48
|
+
kind: "FieldModelConfigKind";
|
|
49
|
+
def: typeof DateInputFieldModelConfig;
|
|
50
|
+
class?: undefined;
|
|
51
|
+
} | {
|
|
52
|
+
kind: "FieldModelDefinitionKind";
|
|
53
|
+
def: typeof DateInputFieldModelDefinition;
|
|
54
|
+
class: "DateInputModel";
|
|
55
|
+
} | {
|
|
56
|
+
kind: "FormComponentDefinitionKind";
|
|
57
|
+
def: typeof DateInputFormComponentDefinition;
|
|
58
|
+
class: "DateInputComponent";
|
|
59
|
+
})[];
|
|
60
|
+
export declare const DateInputDefaults: {
|
|
61
|
+
FormComponentDefinitionKind: {
|
|
62
|
+
DateInputComponent: {
|
|
63
|
+
FieldComponentDefinitionKind: "DateInputComponent";
|
|
64
|
+
FieldModelDefinitionKind: "DateInputModel";
|
|
65
|
+
};
|
|
66
|
+
};
|
|
67
|
+
};
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.DateInputDefaults = exports.DateInputMap = exports.DateInputFormComponentDefinition = exports.DateInputFieldModelDefinition = exports.DateInputFieldModelConfig = exports.DateInputFieldComponentDefinition = exports.DateInputFieldComponentConfig = void 0;
|
|
4
|
+
const field_model_model_1 = require("../field-model.model");
|
|
5
|
+
const form_component_model_1 = require("../form-component.model");
|
|
6
|
+
const shared_outline_1 = require("../shared.outline");
|
|
7
|
+
const field_component_model_1 = require("../field-component.model");
|
|
8
|
+
const date_input_outline_1 = require("./date-input.outline");
|
|
9
|
+
/* Date Input Component */
|
|
10
|
+
class DateInputFieldComponentConfig extends field_component_model_1.FieldComponentConfig {
|
|
11
|
+
placeholder = 'yyyy/mm/dd';
|
|
12
|
+
dateFormat = 'YYYY/MM/DD';
|
|
13
|
+
showWeekNumbers = false;
|
|
14
|
+
containerClass = 'theme-dark-blue';
|
|
15
|
+
enableTimePicker = false;
|
|
16
|
+
robustParsing = true;
|
|
17
|
+
bsFullConfig = null;
|
|
18
|
+
constructor() {
|
|
19
|
+
super();
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
exports.DateInputFieldComponentConfig = DateInputFieldComponentConfig;
|
|
23
|
+
class DateInputFieldComponentDefinition extends field_component_model_1.FieldComponentDefinition {
|
|
24
|
+
class = date_input_outline_1.DateInputComponentName;
|
|
25
|
+
config;
|
|
26
|
+
constructor() {
|
|
27
|
+
super();
|
|
28
|
+
}
|
|
29
|
+
async accept(visitor) {
|
|
30
|
+
await visitor.visitDateInputFieldComponentDefinition(this);
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
exports.DateInputFieldComponentDefinition = DateInputFieldComponentDefinition;
|
|
34
|
+
/* Date Input Model */
|
|
35
|
+
class DateInputFieldModelConfig extends field_model_model_1.FieldModelConfig {
|
|
36
|
+
constructor() {
|
|
37
|
+
super();
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
exports.DateInputFieldModelConfig = DateInputFieldModelConfig;
|
|
41
|
+
class DateInputFieldModelDefinition extends field_model_model_1.FieldModelDefinition {
|
|
42
|
+
class = date_input_outline_1.DateInputModelName;
|
|
43
|
+
config;
|
|
44
|
+
constructor() {
|
|
45
|
+
super();
|
|
46
|
+
}
|
|
47
|
+
async accept(visitor) {
|
|
48
|
+
await visitor.visitDateInputFieldModelDefinition(this);
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
exports.DateInputFieldModelDefinition = DateInputFieldModelDefinition;
|
|
52
|
+
/* Date Input Form Component */
|
|
53
|
+
class DateInputFormComponentDefinition extends form_component_model_1.FormComponentDefinition {
|
|
54
|
+
component;
|
|
55
|
+
model;
|
|
56
|
+
layout;
|
|
57
|
+
constructor() {
|
|
58
|
+
super();
|
|
59
|
+
}
|
|
60
|
+
async accept(visitor) {
|
|
61
|
+
await visitor.visitDateInputFormComponentDefinition(this);
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
exports.DateInputFormComponentDefinition = DateInputFormComponentDefinition;
|
|
65
|
+
exports.DateInputMap = [
|
|
66
|
+
{ kind: shared_outline_1.FieldComponentConfigKind, def: DateInputFieldComponentConfig },
|
|
67
|
+
{ kind: shared_outline_1.FieldComponentDefinitionKind, def: DateInputFieldComponentDefinition, class: date_input_outline_1.DateInputComponentName },
|
|
68
|
+
{ kind: shared_outline_1.FieldModelConfigKind, def: DateInputFieldModelConfig },
|
|
69
|
+
{ kind: shared_outline_1.FieldModelDefinitionKind, def: DateInputFieldModelDefinition, class: date_input_outline_1.DateInputModelName },
|
|
70
|
+
{ kind: shared_outline_1.FormComponentDefinitionKind, def: DateInputFormComponentDefinition, class: date_input_outline_1.DateInputComponentName },
|
|
71
|
+
];
|
|
72
|
+
exports.DateInputDefaults = {
|
|
73
|
+
[shared_outline_1.FormComponentDefinitionKind]: {
|
|
74
|
+
[date_input_outline_1.DateInputComponentName]: {
|
|
75
|
+
[shared_outline_1.FieldComponentDefinitionKind]: date_input_outline_1.DateInputComponentName,
|
|
76
|
+
[shared_outline_1.FieldModelDefinitionKind]: date_input_outline_1.DateInputModelName,
|
|
77
|
+
},
|
|
78
|
+
},
|
|
79
|
+
};
|
|
80
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGF0ZS1pbnB1dC5tb2RlbC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3NyYy9jb25maWcvY29tcG9uZW50L2RhdGUtaW5wdXQubW9kZWwudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7O0FBQUEsNERBQTRFO0FBQzVFLGtFQUFnRTtBQUVoRSxzREFLMkI7QUFDM0Isb0VBQXdGO0FBRXhGLDZEQU04QjtBQUU5QiwwQkFBMEI7QUFHMUIsTUFBYSw2QkFBOEIsU0FBUSw0Q0FBb0I7SUFDbkUsV0FBVyxHQUFZLFlBQVksQ0FBQztJQUNwQyxVQUFVLEdBQVksWUFBWSxDQUFDO0lBQ25DLGVBQWUsR0FBYSxLQUFLLENBQUM7SUFDbEMsY0FBYyxHQUFZLGlCQUFpQixDQUFDO0lBQzVDLGdCQUFnQixHQUFhLEtBQUssQ0FBQztJQUNuQyxhQUFhLEdBQWEsSUFBSSxDQUFDO0lBQy9CLFlBQVksR0FBUyxJQUFJLENBQUM7SUFFMUI7UUFDSSxLQUFLLEVBQUUsQ0FBQztJQUNaLENBQUM7Q0FDSjtBQVpELHNFQVlDO0FBR0QsTUFBYSxpQ0FBa0MsU0FBUSxnREFBd0I7SUFDM0UsS0FBSyxHQUFHLDJDQUFzQixDQUFDO0lBQy9CLE1BQU0sQ0FBd0M7SUFFOUM7UUFDSSxLQUFLLEVBQUUsQ0FBQztJQUNaLENBQUM7SUFFRCxLQUFLLENBQUMsTUFBTSxDQUFDLE9BQWlDO1FBQzFDLE1BQU0sT0FBTyxDQUFDLHNDQUFzQyxDQUFDLElBQUksQ0FBQyxDQUFDO0lBQy9ELENBQUM7Q0FDSjtBQVhELDhFQVdDO0FBR0Qsc0JBQXNCO0FBR3RCLE1BQWEseUJBQTBCLFNBQVEsb0NBQXlDO0lBQ3BGO1FBQ0ksS0FBSyxFQUFFLENBQUM7SUFDWixDQUFDO0NBQ0o7QUFKRCw4REFJQztBQUdELE1BQWEsNkJBQThCLFNBQVEsd0NBQTZDO0lBQzVGLEtBQUssR0FBRyx1Q0FBa0IsQ0FBQztJQUMzQixNQUFNLENBQW9DO0lBRTFDO1FBQ0ksS0FBSyxFQUFFLENBQUM7SUFDWixDQUFDO0lBRUQsS0FBSyxDQUFDLE1BQU0sQ0FBQyxPQUFpQztRQUMxQyxNQUFNLE9BQU8sQ0FBQyxrQ0FBa0MsQ0FBQyxJQUFJLENBQUMsQ0FBQztJQUMzRCxDQUFDO0NBQ0o7QUFYRCxzRUFXQztBQUVELCtCQUErQjtBQUUvQixNQUFhLGdDQUFpQyxTQUFRLDhDQUF1QjtJQUNsRSxTQUFTLENBQTRDO0lBQ3JELEtBQUssQ0FBd0M7SUFDN0MsTUFBTSxDQUEwQztJQUV2RDtRQUNJLEtBQUssRUFBRSxDQUFDO0lBQ1osQ0FBQztJQUVELEtBQUssQ0FBQyxNQUFNLENBQUMsT0FBaUM7UUFDMUMsTUFBTSxPQUFPLENBQUMscUNBQXFDLENBQUMsSUFBSSxDQUFDLENBQUM7SUFDOUQsQ0FBQztDQUNKO0FBWkQsNEVBWUM7QUFFWSxRQUFBLFlBQVksR0FBRztJQUN4QixFQUFDLElBQUksRUFBRSx5Q0FBd0IsRUFBRSxHQUFHLEVBQUUsNkJBQTZCLEVBQUM7SUFDcEUsRUFBQyxJQUFJLEVBQUUsNkNBQTRCLEVBQUUsR0FBRyxFQUFFLGlDQUFpQyxFQUFFLEtBQUssRUFBRSwyQ0FBc0IsRUFBQztJQUMzRyxFQUFDLElBQUksRUFBRSxxQ0FBb0IsRUFBRSxHQUFHLEVBQUUseUJBQXlCLEVBQUM7SUFDNUQsRUFBQyxJQUFJLEVBQUUseUNBQXdCLEVBQUUsR0FBRyxFQUFFLDZCQUE2QixFQUFFLEtBQUssRUFBRSx1Q0FBa0IsRUFBQztJQUMvRixFQUFDLElBQUksRUFBRSw0Q0FBMkIsRUFBRSxHQUFHLEVBQUUsZ0NBQWdDLEVBQUUsS0FBSyxFQUFFLDJDQUFzQixFQUFDO0NBQzVHLENBQUM7QUFDVyxRQUFBLGlCQUFpQixHQUFHO0lBQzdCLENBQUMsNENBQTJCLENBQUMsRUFBRTtRQUMzQixDQUFDLDJDQUFzQixDQUFDLEVBQUU7WUFDdEIsQ0FBQyw2Q0FBNEIsQ0FBQyxFQUFFLDJDQUFzQjtZQUN0RCxDQUFDLHlDQUF3QixDQUFDLEVBQUUsdUNBQWtCO1NBQ2pEO0tBQ0o7Q0FDSixDQUFDIn0=
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
import { FieldComponentConfigFrameKindType, FieldComponentConfigKindType, FieldComponentDefinitionFrameKindType, FieldComponentDefinitionKindType, FieldModelConfigFrameKindType, FieldModelConfigKindType, FieldModelDefinitionFrameKindType, FieldModelDefinitionKindType, FormComponentDefinitionFrameKindType, FormComponentDefinitionKindType } from "../shared.outline";
|
|
2
|
+
import { FieldComponentConfigFrame, FieldComponentConfigOutline, FieldComponentDefinitionFrame, FieldComponentDefinitionOutline } from "../field-component.outline";
|
|
3
|
+
import { FieldModelConfigFrame, FieldModelConfigOutline, FieldModelDefinitionFrame, FieldModelDefinitionOutline } from "../field-model.outline";
|
|
4
|
+
import { FormComponentDefinitionFrame, FormComponentDefinitionOutline } from "../form-component.outline";
|
|
5
|
+
import { AvailableFieldLayoutDefinitionFrames, AvailableFieldLayoutDefinitionOutlines } from "../dictionary.outline";
|
|
6
|
+
export declare const DateInputComponentName: "DateInputComponent";
|
|
7
|
+
export type DateInputComponentNameType = typeof DateInputComponentName;
|
|
8
|
+
export interface DateInputFieldComponentConfigFrame extends FieldComponentConfigFrame {
|
|
9
|
+
placeholder?: string;
|
|
10
|
+
dateFormat?: string;
|
|
11
|
+
showWeekNumbers?: boolean;
|
|
12
|
+
containerClass?: string;
|
|
13
|
+
enableTimePicker?: boolean;
|
|
14
|
+
robustParsing?: boolean;
|
|
15
|
+
bsFullConfig?: any;
|
|
16
|
+
}
|
|
17
|
+
export interface DateInputFieldComponentConfigOutline extends DateInputFieldComponentConfigFrame, FieldComponentConfigOutline {
|
|
18
|
+
}
|
|
19
|
+
export interface DateInputFieldComponentDefinitionFrame extends FieldComponentDefinitionFrame {
|
|
20
|
+
class: DateInputComponentNameType;
|
|
21
|
+
config?: DateInputFieldComponentConfigFrame;
|
|
22
|
+
}
|
|
23
|
+
export interface DateInputFieldComponentDefinitionOutline extends DateInputFieldComponentDefinitionFrame, FieldComponentDefinitionOutline {
|
|
24
|
+
class: DateInputComponentNameType;
|
|
25
|
+
config?: DateInputFieldComponentConfigOutline;
|
|
26
|
+
}
|
|
27
|
+
export declare const DateInputModelName: "DateInputModel";
|
|
28
|
+
export type DateInputModelNameType = typeof DateInputModelName;
|
|
29
|
+
export type DateInputModelValueType = Date | null;
|
|
30
|
+
export interface DateInputFieldModelConfigFrame extends FieldModelConfigFrame<DateInputModelValueType> {
|
|
31
|
+
}
|
|
32
|
+
export interface DateInputFieldModelConfigOutline extends DateInputFieldModelConfigFrame, FieldModelConfigOutline<DateInputModelValueType> {
|
|
33
|
+
}
|
|
34
|
+
export interface DateInputFieldModelDefinitionFrame extends FieldModelDefinitionFrame<DateInputModelValueType> {
|
|
35
|
+
class: DateInputModelNameType;
|
|
36
|
+
config?: DateInputFieldModelConfigFrame;
|
|
37
|
+
}
|
|
38
|
+
export interface DateInputFieldModelDefinitionOutline extends DateInputFieldModelDefinitionFrame, FieldModelDefinitionOutline<DateInputModelValueType> {
|
|
39
|
+
class: DateInputModelNameType;
|
|
40
|
+
config?: DateInputFieldModelConfigOutline;
|
|
41
|
+
}
|
|
42
|
+
export interface DateInputFormComponentDefinitionFrame extends FormComponentDefinitionFrame {
|
|
43
|
+
component: DateInputFieldComponentDefinitionFrame;
|
|
44
|
+
model?: DateInputFieldModelDefinitionFrame;
|
|
45
|
+
layout?: AvailableFieldLayoutDefinitionFrames;
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* Configures date entry and its serialised model value.
|
|
49
|
+
*
|
|
50
|
+
* @extensionPoint Use `DateInputComponent` with `DateInputModel` and the documented date configuration properties.
|
|
51
|
+
* @see https://github.com/redbox-mint/redbox-portal/wiki/Configuring-Record-Forms
|
|
52
|
+
*/
|
|
53
|
+
export interface DateInputFormComponentDefinitionOutline extends DateInputFormComponentDefinitionFrame, FormComponentDefinitionOutline {
|
|
54
|
+
component: DateInputFieldComponentDefinitionOutline;
|
|
55
|
+
model?: DateInputFieldModelDefinitionOutline;
|
|
56
|
+
layout?: AvailableFieldLayoutDefinitionOutlines;
|
|
57
|
+
}
|
|
58
|
+
export type DateInputTypes = {
|
|
59
|
+
kind: FieldComponentConfigFrameKindType;
|
|
60
|
+
class: DateInputFieldComponentConfigFrame;
|
|
61
|
+
} | {
|
|
62
|
+
kind: FieldComponentDefinitionFrameKindType;
|
|
63
|
+
class: DateInputFieldComponentDefinitionFrame;
|
|
64
|
+
} | {
|
|
65
|
+
kind: FieldModelConfigFrameKindType;
|
|
66
|
+
class: DateInputFieldModelConfigFrame;
|
|
67
|
+
} | {
|
|
68
|
+
kind: FieldModelDefinitionFrameKindType;
|
|
69
|
+
class: DateInputFieldModelDefinitionFrame;
|
|
70
|
+
} | {
|
|
71
|
+
kind: FormComponentDefinitionFrameKindType;
|
|
72
|
+
class: DateInputFormComponentDefinitionFrame;
|
|
73
|
+
} | {
|
|
74
|
+
kind: FieldComponentConfigKindType;
|
|
75
|
+
class: DateInputFieldComponentConfigOutline;
|
|
76
|
+
} | {
|
|
77
|
+
kind: FieldComponentDefinitionKindType;
|
|
78
|
+
class: DateInputFieldComponentDefinitionOutline;
|
|
79
|
+
} | {
|
|
80
|
+
kind: FieldModelConfigKindType;
|
|
81
|
+
class: DateInputFieldModelConfigOutline;
|
|
82
|
+
} | {
|
|
83
|
+
kind: FieldModelDefinitionKindType;
|
|
84
|
+
class: DateInputFieldModelDefinitionOutline;
|
|
85
|
+
} | {
|
|
86
|
+
kind: FormComponentDefinitionKindType;
|
|
87
|
+
class: DateInputFormComponentDefinitionOutline;
|
|
88
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.DateInputModelName = exports.DateInputComponentName = void 0;
|
|
4
|
+
/* Date Input Component */
|
|
5
|
+
exports.DateInputComponentName = "DateInputComponent";
|
|
6
|
+
/* Date Input Model */
|
|
7
|
+
exports.DateInputModelName = "DateInputModel";
|
|
8
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGF0ZS1pbnB1dC5vdXRsaW5lLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vc3JjL2NvbmZpZy9jb21wb25lbnQvZGF0ZS1pbnB1dC5vdXRsaW5lLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7OztBQXNCQSwwQkFBMEI7QUFDYixRQUFBLHNCQUFzQixHQUFHLG9CQUE2QixDQUFDO0FBMkJwRSxzQkFBc0I7QUFDVCxRQUFBLGtCQUFrQixHQUFHLGdCQUF5QixDQUFDIn0=
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { FieldLayoutConfig, FieldLayoutDefinition } from "../field-layout.model";
|
|
2
|
+
import { FormConfigVisitorOutline } from "../visitor/base.outline";
|
|
3
|
+
import { DefaultFieldLayoutConfigOutline, DefaultFieldLayoutDefinitionOutline } from "./default-layout.outline";
|
|
4
|
+
export declare class DefaultFieldLayoutConfig extends FieldLayoutConfig implements DefaultFieldLayoutConfigOutline {
|
|
5
|
+
constructor();
|
|
6
|
+
}
|
|
7
|
+
export declare class DefaultFieldLayoutDefinition extends FieldLayoutDefinition implements DefaultFieldLayoutDefinitionOutline {
|
|
8
|
+
class: "DefaultLayout";
|
|
9
|
+
config?: DefaultFieldLayoutConfigOutline;
|
|
10
|
+
constructor();
|
|
11
|
+
accept(visitor: FormConfigVisitorOutline): Promise<void>;
|
|
12
|
+
}
|
|
13
|
+
export declare const DefaultLayoutMap: ({
|
|
14
|
+
kind: "FieldLayoutConfigKind";
|
|
15
|
+
def: typeof DefaultFieldLayoutConfig;
|
|
16
|
+
class?: undefined;
|
|
17
|
+
} | {
|
|
18
|
+
kind: "FieldLayoutDefinitionKind";
|
|
19
|
+
def: typeof DefaultFieldLayoutDefinition;
|
|
20
|
+
class: "DefaultLayout";
|
|
21
|
+
})[];
|
|
22
|
+
export declare const DefaultLayoutDefaults: {};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.DefaultLayoutDefaults = exports.DefaultLayoutMap = exports.DefaultFieldLayoutDefinition = exports.DefaultFieldLayoutConfig = void 0;
|
|
4
|
+
const field_layout_model_1 = require("../field-layout.model");
|
|
5
|
+
const default_layout_outline_1 = require("./default-layout.outline");
|
|
6
|
+
const shared_outline_1 = require("../shared.outline");
|
|
7
|
+
/* Default Layout */
|
|
8
|
+
class DefaultFieldLayoutConfig extends field_layout_model_1.FieldLayoutConfig {
|
|
9
|
+
constructor() {
|
|
10
|
+
super();
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
exports.DefaultFieldLayoutConfig = DefaultFieldLayoutConfig;
|
|
14
|
+
class DefaultFieldLayoutDefinition extends field_layout_model_1.FieldLayoutDefinition {
|
|
15
|
+
class = default_layout_outline_1.DefaultLayoutName;
|
|
16
|
+
config;
|
|
17
|
+
constructor() {
|
|
18
|
+
super();
|
|
19
|
+
}
|
|
20
|
+
async accept(visitor) {
|
|
21
|
+
await visitor.visitDefaultFieldLayoutDefinition(this);
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
exports.DefaultFieldLayoutDefinition = DefaultFieldLayoutDefinition;
|
|
25
|
+
exports.DefaultLayoutMap = [
|
|
26
|
+
{ kind: shared_outline_1.FieldLayoutConfigKind, def: DefaultFieldLayoutConfig },
|
|
27
|
+
{ kind: shared_outline_1.FieldLayoutDefinitionKind, def: DefaultFieldLayoutDefinition, class: default_layout_outline_1.DefaultLayoutName },
|
|
28
|
+
];
|
|
29
|
+
exports.DefaultLayoutDefaults = {};
|
|
30
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGVmYXVsdC1sYXlvdXQubW9kZWwuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9zcmMvY29uZmlnL2NvbXBvbmVudC9kZWZhdWx0LWxheW91dC5tb2RlbC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7QUFBQSw4REFBK0U7QUFFL0UscUVBSWtDO0FBQ2xDLHNEQUFtRjtBQUduRixvQkFBb0I7QUFHcEIsTUFBYSx3QkFBeUIsU0FBUSxzQ0FBaUI7SUFDM0Q7UUFDSSxLQUFLLEVBQUUsQ0FBQztJQUNaLENBQUM7Q0FDSjtBQUpELDREQUlDO0FBR0QsTUFBYSw0QkFBNkIsU0FBUSwwQ0FBcUI7SUFDbkUsS0FBSyxHQUFHLDBDQUFpQixDQUFDO0lBQzFCLE1BQU0sQ0FBbUM7SUFFekM7UUFDSSxLQUFLLEVBQUUsQ0FBQztJQUNaLENBQUM7SUFFRCxLQUFLLENBQUMsTUFBTSxDQUFDLE9BQWlDO1FBQzFDLE1BQU0sT0FBTyxDQUFDLGlDQUFpQyxDQUFDLElBQUksQ0FBQyxDQUFDO0lBQzFELENBQUM7Q0FDSjtBQVhELG9FQVdDO0FBRVksUUFBQSxnQkFBZ0IsR0FBRztJQUM1QixFQUFDLElBQUksRUFBRSxzQ0FBcUIsRUFBRSxHQUFHLEVBQUUsd0JBQXdCLEVBQUM7SUFDNUQsRUFBQyxJQUFJLEVBQUUsMENBQXlCLEVBQUUsR0FBRyxFQUFFLDRCQUE0QixFQUFFLEtBQUssRUFBRSwwQ0FBaUIsRUFBQztDQUNqRyxDQUFDO0FBQ1csUUFBQSxxQkFBcUIsR0FBRyxFQUFFLENBQUMifQ==
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { FieldLayoutConfigFrame, FieldLayoutConfigOutline, FieldLayoutDefinitionFrame, FieldLayoutDefinitionOutline } from "../field-layout.outline";
|
|
2
|
+
import { FieldLayoutConfigFrameKindType, FieldLayoutConfigKindType, FieldLayoutDefinitionFrameKindType, FieldLayoutDefinitionKindType } from "../shared.outline";
|
|
3
|
+
export declare const DefaultLayoutName: "DefaultLayout";
|
|
4
|
+
export type DefaultLayoutNameType = typeof DefaultLayoutName;
|
|
5
|
+
export interface DefaultFieldLayoutConfigFrame extends FieldLayoutConfigFrame {
|
|
6
|
+
}
|
|
7
|
+
export interface DefaultFieldLayoutConfigOutline extends DefaultFieldLayoutConfigFrame, FieldLayoutConfigOutline {
|
|
8
|
+
}
|
|
9
|
+
export interface DefaultFieldLayoutDefinitionFrame extends FieldLayoutDefinitionFrame {
|
|
10
|
+
class: DefaultLayoutNameType;
|
|
11
|
+
config?: DefaultFieldLayoutConfigFrame;
|
|
12
|
+
}
|
|
13
|
+
export interface DefaultFieldLayoutDefinitionOutline extends DefaultFieldLayoutDefinitionFrame, FieldLayoutDefinitionOutline {
|
|
14
|
+
class: DefaultLayoutNameType;
|
|
15
|
+
config?: DefaultFieldLayoutConfigOutline;
|
|
16
|
+
}
|
|
17
|
+
export type DefaultLayoutTypes = {
|
|
18
|
+
kind: FieldLayoutConfigFrameKindType;
|
|
19
|
+
class: DefaultFieldLayoutConfigFrame;
|
|
20
|
+
} | {
|
|
21
|
+
kind: FieldLayoutConfigKindType;
|
|
22
|
+
class: DefaultFieldLayoutConfigOutline;
|
|
23
|
+
} | {
|
|
24
|
+
kind: FieldLayoutDefinitionFrameKindType;
|
|
25
|
+
class: DefaultFieldLayoutDefinitionFrame;
|
|
26
|
+
} | {
|
|
27
|
+
kind: FieldLayoutDefinitionKindType;
|
|
28
|
+
class: DefaultFieldLayoutDefinitionOutline;
|
|
29
|
+
};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.DefaultLayoutName = void 0;
|
|
4
|
+
exports.DefaultLayoutName = `DefaultLayout`;
|
|
5
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGVmYXVsdC1sYXlvdXQub3V0bGluZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3NyYy9jb25maWcvY29tcG9uZW50L2RlZmF1bHQtbGF5b3V0Lm91dGxpbmUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7O0FBWWEsUUFBQSxpQkFBaUIsR0FBRyxlQUF3QixDQUFDIn0=
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { FieldComponentConfig, FieldComponentDefinition } from '../field-component.model';
|
|
2
|
+
import { AvailableFieldLayoutDefinitionOutlines } from '../dictionary.outline';
|
|
3
|
+
import { FormComponentDefinition } from '../form-component.model';
|
|
4
|
+
import { FormConfigVisitorOutline } from '../visitor/base.outline';
|
|
5
|
+
import { DeleteButtonFieldComponentConfigOutline, DeleteButtonFieldComponentDefinitionOutline, DeleteButtonFormComponentDefinitionOutline } from './delete-button.outline';
|
|
6
|
+
export declare class DeleteButtonFieldComponentConfig extends FieldComponentConfig implements DeleteButtonFieldComponentConfigOutline {
|
|
7
|
+
confirmationMessage?: string;
|
|
8
|
+
confirmationTitle?: string;
|
|
9
|
+
cancelButtonMessage?: string;
|
|
10
|
+
confirmButtonMessage?: string;
|
|
11
|
+
buttonCssClasses?: string;
|
|
12
|
+
closeOnDelete?: boolean;
|
|
13
|
+
redirectLocation?: string;
|
|
14
|
+
redirectDelaySeconds?: number;
|
|
15
|
+
}
|
|
16
|
+
export declare class DeleteButtonFieldComponentDefinition extends FieldComponentDefinition implements DeleteButtonFieldComponentDefinitionOutline {
|
|
17
|
+
class: "DeleteButtonComponent";
|
|
18
|
+
config?: DeleteButtonFieldComponentConfigOutline;
|
|
19
|
+
accept(visitor: FormConfigVisitorOutline): Promise<void>;
|
|
20
|
+
}
|
|
21
|
+
export declare class DeleteButtonFormComponentDefinition extends FormComponentDefinition implements DeleteButtonFormComponentDefinitionOutline {
|
|
22
|
+
component: DeleteButtonFieldComponentDefinitionOutline;
|
|
23
|
+
model?: never;
|
|
24
|
+
layout?: AvailableFieldLayoutDefinitionOutlines;
|
|
25
|
+
accept(visitor: FormConfigVisitorOutline): Promise<void>;
|
|
26
|
+
}
|
|
27
|
+
export declare const DeleteButtonMap: ({
|
|
28
|
+
kind: "FieldComponentConfigKind";
|
|
29
|
+
def: typeof DeleteButtonFieldComponentConfig;
|
|
30
|
+
class?: undefined;
|
|
31
|
+
} | {
|
|
32
|
+
kind: "FieldComponentDefinitionKind";
|
|
33
|
+
def: typeof DeleteButtonFieldComponentDefinition;
|
|
34
|
+
class: "DeleteButtonComponent";
|
|
35
|
+
} | {
|
|
36
|
+
kind: "FormComponentDefinitionKind";
|
|
37
|
+
def: typeof DeleteButtonFormComponentDefinition;
|
|
38
|
+
class: "DeleteButtonComponent";
|
|
39
|
+
})[];
|
|
40
|
+
export declare const DeleteButtonDefaults: {
|
|
41
|
+
FormComponentDefinitionKind: {
|
|
42
|
+
DeleteButtonComponent: {
|
|
43
|
+
FieldComponentDefinitionKind: "DeleteButtonComponent";
|
|
44
|
+
};
|
|
45
|
+
};
|
|
46
|
+
};
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.DeleteButtonDefaults = exports.DeleteButtonMap = exports.DeleteButtonFormComponentDefinition = exports.DeleteButtonFieldComponentDefinition = exports.DeleteButtonFieldComponentConfig = void 0;
|
|
4
|
+
const field_component_model_1 = require("../field-component.model");
|
|
5
|
+
const form_component_model_1 = require("../form-component.model");
|
|
6
|
+
const shared_outline_1 = require("../shared.outline");
|
|
7
|
+
const delete_button_outline_1 = require("./delete-button.outline");
|
|
8
|
+
class DeleteButtonFieldComponentConfig extends field_component_model_1.FieldComponentConfig {
|
|
9
|
+
confirmationMessage;
|
|
10
|
+
confirmationTitle;
|
|
11
|
+
cancelButtonMessage;
|
|
12
|
+
confirmButtonMessage;
|
|
13
|
+
buttonCssClasses;
|
|
14
|
+
closeOnDelete;
|
|
15
|
+
redirectLocation;
|
|
16
|
+
redirectDelaySeconds;
|
|
17
|
+
}
|
|
18
|
+
exports.DeleteButtonFieldComponentConfig = DeleteButtonFieldComponentConfig;
|
|
19
|
+
class DeleteButtonFieldComponentDefinition extends field_component_model_1.FieldComponentDefinition {
|
|
20
|
+
class = delete_button_outline_1.DeleteButtonComponentName;
|
|
21
|
+
config;
|
|
22
|
+
async accept(visitor) {
|
|
23
|
+
await visitor.visitDeleteButtonFieldComponentDefinition(this);
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
exports.DeleteButtonFieldComponentDefinition = DeleteButtonFieldComponentDefinition;
|
|
27
|
+
class DeleteButtonFormComponentDefinition extends form_component_model_1.FormComponentDefinition {
|
|
28
|
+
component;
|
|
29
|
+
model;
|
|
30
|
+
layout;
|
|
31
|
+
async accept(visitor) {
|
|
32
|
+
await visitor.visitDeleteButtonFormComponentDefinition(this);
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
exports.DeleteButtonFormComponentDefinition = DeleteButtonFormComponentDefinition;
|
|
36
|
+
exports.DeleteButtonMap = [
|
|
37
|
+
{ kind: shared_outline_1.FieldComponentConfigKind, def: DeleteButtonFieldComponentConfig },
|
|
38
|
+
{ kind: shared_outline_1.FieldComponentDefinitionKind, def: DeleteButtonFieldComponentDefinition, class: delete_button_outline_1.DeleteButtonComponentName },
|
|
39
|
+
{ kind: shared_outline_1.FormComponentDefinitionKind, def: DeleteButtonFormComponentDefinition, class: delete_button_outline_1.DeleteButtonComponentName },
|
|
40
|
+
];
|
|
41
|
+
exports.DeleteButtonDefaults = {
|
|
42
|
+
[shared_outline_1.FormComponentDefinitionKind]: {
|
|
43
|
+
[delete_button_outline_1.DeleteButtonComponentName]: {
|
|
44
|
+
[shared_outline_1.FieldComponentDefinitionKind]: delete_button_outline_1.DeleteButtonComponentName,
|
|
45
|
+
},
|
|
46
|
+
},
|
|
47
|
+
};
|
|
48
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGVsZXRlLWJ1dHRvbi5tb2RlbC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3NyYy9jb25maWcvY29tcG9uZW50L2RlbGV0ZS1idXR0b24ubW9kZWwudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7O0FBQUEsb0VBQTBGO0FBRTFGLGtFQUFrRTtBQUVsRSxzREFBd0g7QUFDeEgsbUVBS2lDO0FBRWpDLE1BQWEsZ0NBQWlDLFNBQVEsNENBQW9CO0lBQ3hFLG1CQUFtQixDQUFVO0lBQzdCLGlCQUFpQixDQUFVO0lBQzNCLG1CQUFtQixDQUFVO0lBQzdCLG9CQUFvQixDQUFVO0lBQzlCLGdCQUFnQixDQUFVO0lBQzFCLGFBQWEsQ0FBVztJQUN4QixnQkFBZ0IsQ0FBVTtJQUMxQixvQkFBb0IsQ0FBVTtDQUMvQjtBQVRELDRFQVNDO0FBRUQsTUFBYSxvQ0FDWCxTQUFRLGdEQUF3QjtJQUdoQyxLQUFLLEdBQUcsaURBQXlCLENBQUM7SUFDbEMsTUFBTSxDQUEyQztJQUVqRCxLQUFLLENBQUMsTUFBTSxDQUFDLE9BQWlDO1FBQzVDLE1BQU0sT0FBTyxDQUFDLHlDQUF5QyxDQUFDLElBQUksQ0FBQyxDQUFDO0lBQ2hFLENBQUM7Q0FDRjtBQVZELG9GQVVDO0FBRUQsTUFBYSxtQ0FDWCxTQUFRLDhDQUF1QjtJQUcvQixTQUFTLENBQStDO0lBQ3hELEtBQUssQ0FBUztJQUNkLE1BQU0sQ0FBMEM7SUFFaEQsS0FBSyxDQUFDLE1BQU0sQ0FBQyxPQUFpQztRQUM1QyxNQUFNLE9BQU8sQ0FBQyx3Q0FBd0MsQ0FBQyxJQUFJLENBQUMsQ0FBQztJQUMvRCxDQUFDO0NBQ0Y7QUFYRCxrRkFXQztBQUVZLFFBQUEsZUFBZSxHQUFHO0lBQzdCLEVBQUUsSUFBSSxFQUFFLHlDQUF3QixFQUFFLEdBQUcsRUFBRSxnQ0FBZ0MsRUFBRTtJQUN6RSxFQUFFLElBQUksRUFBRSw2Q0FBNEIsRUFBRSxHQUFHLEVBQUUsb0NBQW9DLEVBQUUsS0FBSyxFQUFFLGlEQUF5QixFQUFFO0lBQ25ILEVBQUUsSUFBSSxFQUFFLDRDQUEyQixFQUFFLEdBQUcsRUFBRSxtQ0FBbUMsRUFBRSxLQUFLLEVBQUUsaURBQXlCLEVBQUU7Q0FDbEgsQ0FBQztBQUVXLFFBQUEsb0JBQW9CLEdBQUc7SUFDbEMsQ0FBQyw0Q0FBMkIsQ0FBQyxFQUFFO1FBQzdCLENBQUMsaURBQXlCLENBQUMsRUFBRTtZQUMzQixDQUFDLDZDQUE0QixDQUFDLEVBQUUsaURBQXlCO1NBQzFEO0tBQ0Y7Q0FDRixDQUFDIn0=
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
import { FieldComponentConfigFrame, FieldComponentConfigOutline, FieldComponentDefinitionFrame, FieldComponentDefinitionOutline } from '../field-component.outline';
|
|
2
|
+
import { FormComponentDefinitionFrame, FormComponentDefinitionOutline } from '../form-component.outline';
|
|
3
|
+
import { AvailableFieldLayoutDefinitionFrames, AvailableFieldLayoutDefinitionOutlines } from '../dictionary.outline';
|
|
4
|
+
import { FieldComponentConfigFrameKindType, FieldComponentConfigKindType, FieldComponentDefinitionFrameKindType, FieldComponentDefinitionKindType, FormComponentDefinitionFrameKindType, FormComponentDefinitionKindType } from '../shared.outline';
|
|
5
|
+
export declare const DeleteButtonComponentName: "DeleteButtonComponent";
|
|
6
|
+
export type DeleteButtonComponentNameType = typeof DeleteButtonComponentName;
|
|
7
|
+
export interface DeleteButtonFieldComponentConfigFrame extends FieldComponentConfigFrame {
|
|
8
|
+
/**
|
|
9
|
+
* An optional confirmation message shown to the user before cancelling.
|
|
10
|
+
* If not set, the cancel action proceeds without confirmation.
|
|
11
|
+
*/
|
|
12
|
+
confirmationMessage?: string;
|
|
13
|
+
/**
|
|
14
|
+
* The title of the confirmation dialog.
|
|
15
|
+
*/
|
|
16
|
+
confirmationTitle?: string;
|
|
17
|
+
/**
|
|
18
|
+
* The label for the cancel button in the confirmation dialog.
|
|
19
|
+
*/
|
|
20
|
+
cancelButtonMessage?: string;
|
|
21
|
+
/**
|
|
22
|
+
* The label for the confirm button in the confirmation dialog.
|
|
23
|
+
*/
|
|
24
|
+
confirmButtonMessage?: string;
|
|
25
|
+
/**
|
|
26
|
+
* CSS classes to apply to the main cancel button element.
|
|
27
|
+
* Example: 'btn-warning' or 'btn btn-warning'.
|
|
28
|
+
*/
|
|
29
|
+
buttonCssClasses?: string;
|
|
30
|
+
/**
|
|
31
|
+
* Whether to 'close' the form by redirecting on a successful delete. Default false.
|
|
32
|
+
*/
|
|
33
|
+
closeOnDelete?: boolean;
|
|
34
|
+
/**
|
|
35
|
+
* The relative url to redirect to on a successful delete if closeOnDelete is true.
|
|
36
|
+
* Leave empty to use the browser's location.back.
|
|
37
|
+
*/
|
|
38
|
+
redirectLocation?: string;
|
|
39
|
+
/**
|
|
40
|
+
* The delay before redirecting on a successful delete if closeOnDelete is true.
|
|
41
|
+
* Default is 3 seconds delay.
|
|
42
|
+
*/
|
|
43
|
+
redirectDelaySeconds?: number;
|
|
44
|
+
}
|
|
45
|
+
export interface DeleteButtonFieldComponentConfigOutline extends DeleteButtonFieldComponentConfigFrame, FieldComponentConfigOutline {
|
|
46
|
+
}
|
|
47
|
+
export interface DeleteButtonFieldComponentDefinitionFrame extends FieldComponentDefinitionFrame {
|
|
48
|
+
class: DeleteButtonComponentNameType;
|
|
49
|
+
config?: DeleteButtonFieldComponentConfigFrame;
|
|
50
|
+
}
|
|
51
|
+
export interface DeleteButtonFieldComponentDefinitionOutline extends DeleteButtonFieldComponentDefinitionFrame, FieldComponentDefinitionOutline {
|
|
52
|
+
class: DeleteButtonComponentNameType;
|
|
53
|
+
config?: DeleteButtonFieldComponentConfigOutline;
|
|
54
|
+
}
|
|
55
|
+
export interface DeleteButtonFormComponentDefinitionFrame extends FormComponentDefinitionFrame {
|
|
56
|
+
component: DeleteButtonFieldComponentDefinitionFrame;
|
|
57
|
+
model?: never;
|
|
58
|
+
layout?: AvailableFieldLayoutDefinitionFrames;
|
|
59
|
+
}
|
|
60
|
+
/**
|
|
61
|
+
* Configures a form action that deletes the current record.
|
|
62
|
+
*
|
|
63
|
+
* @extensionPoint Use `DeleteButtonComponent` in authorised form action areas and retain its confirmation semantics.
|
|
64
|
+
* @see https://github.com/redbox-mint/redbox-portal/wiki/Configuring-Record-Forms
|
|
65
|
+
*/
|
|
66
|
+
export interface DeleteButtonFormComponentDefinitionOutline extends DeleteButtonFormComponentDefinitionFrame, FormComponentDefinitionOutline {
|
|
67
|
+
component: DeleteButtonFieldComponentDefinitionOutline;
|
|
68
|
+
model?: never;
|
|
69
|
+
layout?: AvailableFieldLayoutDefinitionOutlines;
|
|
70
|
+
}
|
|
71
|
+
export type DeleteButtonTypes = {
|
|
72
|
+
kind: FieldComponentConfigFrameKindType;
|
|
73
|
+
class: DeleteButtonFieldComponentConfigFrame;
|
|
74
|
+
} | {
|
|
75
|
+
kind: FieldComponentDefinitionFrameKindType;
|
|
76
|
+
class: DeleteButtonFieldComponentDefinitionFrame;
|
|
77
|
+
} | {
|
|
78
|
+
kind: FormComponentDefinitionFrameKindType;
|
|
79
|
+
class: DeleteButtonFormComponentDefinitionFrame;
|
|
80
|
+
} | {
|
|
81
|
+
kind: FieldComponentConfigKindType;
|
|
82
|
+
class: DeleteButtonFieldComponentConfigOutline;
|
|
83
|
+
} | {
|
|
84
|
+
kind: FieldComponentDefinitionKindType;
|
|
85
|
+
class: DeleteButtonFieldComponentDefinitionOutline;
|
|
86
|
+
} | {
|
|
87
|
+
kind: FormComponentDefinitionKindType;
|
|
88
|
+
class: DeleteButtonFormComponentDefinitionOutline;
|
|
89
|
+
};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.DeleteButtonComponentName = void 0;
|
|
4
|
+
exports.DeleteButtonComponentName = 'DeleteButtonComponent';
|
|
5
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGVsZXRlLWJ1dHRvbi5vdXRsaW5lLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vc3JjL2NvbmZpZy9jb21wb25lbnQvZGVsZXRlLWJ1dHRvbi5vdXRsaW5lLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7OztBQWlCYSxRQUFBLHlCQUF5QixHQUFHLHVCQUFnQyxDQUFDIn0=
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
import { FieldModelConfig, FieldModelDefinition } from "../field-model.model";
|
|
2
|
+
import { FormComponentDefinition } from "../form-component.model";
|
|
3
|
+
import { FormConfigVisitorOutline } from "../visitor/base.outline";
|
|
4
|
+
import { FieldComponentConfig, FieldComponentDefinition } from "../field-component.model";
|
|
5
|
+
import { AvailableFieldLayoutDefinitionOutlines } from "../dictionary.outline";
|
|
6
|
+
import { DropdownInputFieldComponentConfigOutline, DropdownInputFieldComponentDefinitionOutline, DropdownInputFieldModelConfigOutline, DropdownInputFieldModelDefinitionOutline, DropdownInputFormComponentDefinitionOutline, DropdownInputModelValueType, DropdownOption, HistoricalVocabMode } from "./dropdown-input.outline";
|
|
7
|
+
export declare class DropdownInputFieldComponentConfig extends FieldComponentConfig implements DropdownInputFieldComponentConfigOutline {
|
|
8
|
+
placeholder?: string;
|
|
9
|
+
options: DropdownOption[];
|
|
10
|
+
vocabRef?: string;
|
|
11
|
+
inlineVocab?: boolean;
|
|
12
|
+
historicalVocabMode?: HistoricalVocabMode;
|
|
13
|
+
constructor();
|
|
14
|
+
}
|
|
15
|
+
export declare class DropdownInputFieldComponentDefinition extends FieldComponentDefinition implements DropdownInputFieldComponentDefinitionOutline {
|
|
16
|
+
class: "DropdownInputComponent";
|
|
17
|
+
config?: DropdownInputFieldComponentConfigOutline;
|
|
18
|
+
constructor();
|
|
19
|
+
accept(visitor: FormConfigVisitorOutline): Promise<void>;
|
|
20
|
+
}
|
|
21
|
+
export declare class DropdownInputFieldModelConfig extends FieldModelConfig<DropdownInputModelValueType> implements DropdownInputFieldModelConfigOutline {
|
|
22
|
+
constructor();
|
|
23
|
+
}
|
|
24
|
+
export declare class DropdownInputFieldModelDefinition extends FieldModelDefinition<DropdownInputModelValueType> implements DropdownInputFieldModelDefinitionOutline {
|
|
25
|
+
class: "DropdownInputModel";
|
|
26
|
+
config?: DropdownInputFieldModelConfigOutline;
|
|
27
|
+
constructor();
|
|
28
|
+
accept(visitor: FormConfigVisitorOutline): Promise<void>;
|
|
29
|
+
}
|
|
30
|
+
export declare class DropdownInputFormComponentDefinition extends FormComponentDefinition implements DropdownInputFormComponentDefinitionOutline {
|
|
31
|
+
component: DropdownInputFieldComponentDefinitionOutline;
|
|
32
|
+
model?: DropdownInputFieldModelDefinitionOutline;
|
|
33
|
+
layout?: AvailableFieldLayoutDefinitionOutlines;
|
|
34
|
+
constructor();
|
|
35
|
+
accept(visitor: FormConfigVisitorOutline): Promise<void>;
|
|
36
|
+
}
|
|
37
|
+
export declare const DropdownInputMap: ({
|
|
38
|
+
kind: "FieldComponentConfigKind";
|
|
39
|
+
def: typeof DropdownInputFieldComponentConfig;
|
|
40
|
+
class?: undefined;
|
|
41
|
+
} | {
|
|
42
|
+
kind: "FieldComponentDefinitionKind";
|
|
43
|
+
def: typeof DropdownInputFieldComponentDefinition;
|
|
44
|
+
class: "DropdownInputComponent";
|
|
45
|
+
} | {
|
|
46
|
+
kind: "FieldModelConfigKind";
|
|
47
|
+
def: typeof DropdownInputFieldModelConfig;
|
|
48
|
+
class?: undefined;
|
|
49
|
+
} | {
|
|
50
|
+
kind: "FieldModelDefinitionKind";
|
|
51
|
+
def: typeof DropdownInputFieldModelDefinition;
|
|
52
|
+
class: "DropdownInputModel";
|
|
53
|
+
} | {
|
|
54
|
+
kind: "FormComponentDefinitionKind";
|
|
55
|
+
def: typeof DropdownInputFormComponentDefinition;
|
|
56
|
+
class: "DropdownInputComponent";
|
|
57
|
+
})[];
|
|
58
|
+
export declare const DropdownInputDefaults: {
|
|
59
|
+
FormComponentDefinitionKind: {
|
|
60
|
+
DropdownInputComponent: {
|
|
61
|
+
FieldComponentDefinitionKind: "DropdownInputComponent";
|
|
62
|
+
FieldModelDefinitionKind: "DropdownInputModel";
|
|
63
|
+
};
|
|
64
|
+
};
|
|
65
|
+
};
|