@dartech/arsenal-ui 0.0.1 → 0.0.2
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/{index.ts → index.d.ts} +3 -3
- package/index.esm.js +1 -0
- package/index.umd.js +1 -0
- package/package.json +5 -2
- package/src/interfaces/common.d.ts +10 -0
- package/src/interfaces/definition.d.ts +117 -0
- package/src/interfaces/{index.ts → index.d.ts} +3 -3
- package/src/interfaces/ui.d.ts +33 -0
- package/src/lib/Alert/Alert.d.ts +53 -0
- package/src/lib/Alert/index.d.ts +1 -0
- package/src/lib/Definition/CreateDefinition/CreateDefinition.d.ts +11 -0
- package/src/lib/Definition/CreateDefinition/{index.ts → index.d.ts} +1 -1
- package/src/lib/Definition/DefinitionFiller/DefinitionFiller.d.ts +8 -0
- package/src/lib/Definition/DefinitionFiller/WidgetDefinitionFiller.d.ts +9 -0
- package/src/lib/Definition/DefinitionFiller/{index.ts → index.d.ts} +2 -2
- package/src/lib/Definition/{index.ts → index.d.ts} +2 -2
- package/src/lib/DemPropertyField/DemPropertyField.d.ts +59 -0
- package/src/lib/DemPropertyField/DemPropertyView/DemPropertyView.d.ts +8 -0
- package/src/lib/DemPropertyField/DemPropertyView/{index.ts → index.d.ts} +1 -1
- package/src/lib/DemPropertyField/MultipleDemField/MultipleDemField.d.ts +9 -0
- package/src/lib/DemPropertyField/MultipleDemField/{index.tsx → index.d.ts} +1 -1
- package/src/lib/DemPropertyField/RestrictedValuesEditor.d.ts +6 -0
- package/src/lib/DemPropertyField/SingleDemField/SingleDemField.d.ts +9 -0
- package/src/lib/DemPropertyField/SingleDemField/{index.ts → index.d.ts} +1 -1
- package/src/lib/DemPropertyField/{index.ts → index.d.ts} +2 -2
- package/src/lib/DemPropertyField/styles.d.ts +2 -0
- package/src/lib/DemPropertyField/widgets/DemBooleanWidget.d.ts +7 -0
- package/src/lib/DemPropertyField/widgets/DemDateTimeWidget.d.ts +9 -0
- package/src/lib/DemPropertyField/widgets/DemDateWidget.d.ts +9 -0
- package/src/lib/DemPropertyField/widgets/DemFieldWidget.d.ts +11 -0
- package/src/lib/DemPropertyField/widgets/DemFloatWidget.d.ts +10 -0
- package/src/lib/DemPropertyField/widgets/DemIntegerWidget.d.ts +10 -0
- package/src/lib/DemPropertyField/widgets/DemJsonWidget.d.ts +9 -0
- package/src/lib/DemPropertyField/widgets/DemStringWidget.d.ts +10 -0
- package/src/lib/DemPropertyField/widgets/DemTimeWidget.d.ts +9 -0
- package/src/lib/DemPropertyField/widgets/{index.ts → index.d.ts} +1 -1
- package/src/lib/Forms/BackButton.d.ts +7 -0
- package/src/lib/Forms/ControlAceEditor.d.ts +20 -0
- package/src/lib/Forms/ControlAutocomplete.d.ts +49 -0
- package/src/lib/Forms/ControlCheckbox.d.ts +30 -0
- package/src/lib/Forms/ControlDebouncedInput.d.ts +4 -0
- package/src/lib/Forms/ControlInput.d.ts +54 -0
- package/src/lib/Forms/ControlNumberInput.d.ts +43 -0
- package/src/lib/Forms/ControlRadioBtn.d.ts +26 -0
- package/src/lib/Forms/ControlSelect.d.ts +66 -0
- package/src/lib/Forms/CopyButton.d.ts +21 -0
- package/src/lib/Forms/{index.ts → index.d.ts} +10 -10
- package/src/lib/InfoItem/InfoItem.d.ts +10 -0
- package/src/lib/InfoItem/{index.ts → index.d.ts} +1 -1
- package/src/lib/InfoItem/styles.d.ts +2 -0
- package/src/lib/JsonPathPicker/JsonPathPicker.d.ts +10 -0
- package/src/lib/JsonPathPicker/PropertyStep.d.ts +11 -0
- package/src/lib/JsonPathPicker/{index.ts → index.d.ts} +1 -1
- package/src/lib/JsonView/JsonView.d.ts +9 -0
- package/src/lib/JsonView/{index.ts → index.d.ts} +1 -1
- package/src/lib/Loader/Loader.d.ts +21 -0
- package/src/lib/Loader/{index.ts → index.d.ts} +1 -1
- package/src/lib/Modals/JsonModalView.d.ts +10 -0
- package/src/lib/Modals/{index.ts → index.d.ts} +1 -1
- package/src/lib/Property/PropertyValueField/BooleanValueField.d.ts +7 -0
- package/src/lib/Property/PropertyValueField/DateTimeValueField.d.ts +9 -0
- package/src/lib/Property/PropertyValueField/DateValueField.d.ts +9 -0
- package/src/lib/Property/PropertyValueField/EntityValueField.d.ts +9 -0
- package/src/lib/Property/PropertyValueField/JsonValueField.d.ts +10 -0
- package/src/lib/Property/PropertyValueField/PropertyValue.d.ts +10 -0
- package/src/lib/Property/PropertyValueField/PropertyValueField.d.ts +9 -0
- package/src/lib/Property/PropertyValueField/StringValueField.d.ts +9 -0
- package/src/lib/Property/PropertyValueField/TimeValueField.d.ts +9 -0
- package/src/lib/Property/PropertyValueField/ValueComponent.d.ts +15 -0
- package/src/lib/Property/PropertyValueField/{index.ts → index.d.ts} +2 -1
- package/src/lib/Property/PropertyWidget/PropertyWidget.d.ts +9 -0
- package/src/lib/Property/PropertyWidget/{index.ts → index.d.ts} +1 -1
- package/src/lib/Property/UpsertProperty/CreatePropertiesList.d.ts +13 -0
- package/src/lib/Property/UpsertProperty/CreatePropertyFormFields.d.ts +10 -0
- package/src/lib/Property/UpsertProperty/CustomPropertyField.d.ts +7 -0
- package/src/lib/Property/UpsertProperty/PropertyAdditionalFields/BigDecimalPropertyFields.d.ts +6 -0
- package/src/lib/Property/UpsertProperty/PropertyAdditionalFields/DateAdditionalFields.d.ts +7 -0
- package/src/lib/Property/UpsertProperty/PropertyAdditionalFields/EntityAdditionalFields.d.ts +8 -0
- package/src/lib/Property/UpsertProperty/PropertyAdditionalFields/EntityReferencePropertyFields.d.ts +6 -0
- package/src/lib/Property/UpsertProperty/PropertyAdditionalFields/PropertyAdditionalFields.d.ts +10 -0
- package/src/lib/Property/UpsertProperty/PropertyAdditionalFields/StringPropertyFields.d.ts +6 -0
- package/src/lib/Property/UpsertProperty/PropertyAdditionalFields/{index.ts → index.d.ts} +1 -1
- package/src/lib/Property/UpsertProperty/{index.ts → index.d.ts} +2 -2
- package/src/lib/Property/UpsertProperty/useCustomFields.d.ts +6 -0
- package/src/lib/Property/ViewPropertiesList/ViewPropertiesList.d.ts +8 -0
- package/src/lib/Property/ViewPropertiesList/{index.ts → index.d.ts} +1 -1
- package/src/lib/Property/ViewProperty/EntityPropertiesShortView.d.ts +9 -0
- package/src/lib/Property/ViewProperty/EntityPropertiesView.d.ts +8 -0
- package/src/lib/Property/ViewProperty/PropertyDataTable.d.ts +7 -0
- package/src/lib/Property/ViewProperty/PropertyItem.d.ts +9 -0
- package/src/lib/Property/ViewProperty/ViewProperty.d.ts +9 -0
- package/src/lib/Property/ViewProperty/{index.ts → index.d.ts} +1 -1
- package/src/lib/Property/{index.ts → index.d.ts} +4 -4
- package/src/lib/Status/Status.d.ts +7 -0
- package/src/lib/Status/{index.ts → index.d.ts} +1 -1
- package/src/lib/Status/styles.d.ts +2 -0
- package/src/lib/Table/Table.d.ts +49 -0
- package/src/lib/Table/TableColumnMenu.d.ts +3 -0
- package/src/lib/Table/TablePagination.d.ts +3 -0
- package/src/lib/Table/index.d.ts +1 -0
- package/src/lib/Table/styles.d.ts +2 -0
- package/src/lib/Table/usePagination.d.ts +5 -0
- package/src/lib/Table/useTableQueryPagination.d.ts +11 -0
- package/src/lib/Table/useTableQuerySorting.d.ts +6 -0
- package/src/lib/Tabs/RouteTabs.d.ts +11 -0
- package/src/lib/Tabs/TabPanel.d.ts +25 -0
- package/src/lib/Tabs/{index.ts → index.d.ts} +2 -2
- package/src/lib/TemplateContent/ExpressionDecorator.d.ts +5 -0
- package/src/lib/TemplateContent/TemplateContentEditor.d.ts +9 -0
- package/src/lib/TemplateContent/{index.ts → index.d.ts} +1 -1
- package/src/lib/{index.ts → index.d.ts} +14 -14
- package/src/utils/common.d.ts +7 -0
- package/src/utils/dem.d.ts +7 -0
- package/src/utils/hooks.d.ts +7 -0
- package/src/utils/{index.ts → index.d.ts} +5 -5
- package/src/utils/ui-utils.d.ts +7 -0
- package/src/utils/validators.d.ts +12 -0
- package/.babelrc +0 -12
- package/.eslintrc.json +0 -22
- package/jest.config.js +0 -9
- package/project.json +0 -69
- package/rollup.config.js +0 -135
- package/src/interfaces/common.ts +0 -12
- package/src/interfaces/definition.ts +0 -143
- package/src/interfaces/ui.ts +0 -35
- package/src/lib/Alert/Alert.tsx +0 -108
- package/src/lib/Alert/index.ts +0 -1
- package/src/lib/Definition/CreateDefinition/CreateDefinition.tsx +0 -74
- package/src/lib/Definition/DefinitionFiller/DefinitionFiller.tsx +0 -85
- package/src/lib/Definition/DefinitionFiller/WidgetDefinitionFiller.tsx +0 -96
- package/src/lib/DemPropertyField/DemPropertyField.tsx +0 -93
- package/src/lib/DemPropertyField/DemPropertyView/DemPropertyView.tsx +0 -44
- package/src/lib/DemPropertyField/MultipleDemField/MultipleDemField.tsx +0 -293
- package/src/lib/DemPropertyField/RestrictedValuesEditor.tsx +0 -63
- package/src/lib/DemPropertyField/SingleDemField/SingleDemField.tsx +0 -156
- package/src/lib/DemPropertyField/styles.ts +0 -50
- package/src/lib/DemPropertyField/widgets/DemBooleanWidget.tsx +0 -26
- package/src/lib/DemPropertyField/widgets/DemDateTimeWidget.tsx +0 -34
- package/src/lib/DemPropertyField/widgets/DemDateWidget.tsx +0 -33
- package/src/lib/DemPropertyField/widgets/DemFieldWidget.tsx +0 -67
- package/src/lib/DemPropertyField/widgets/DemFloatWidget.tsx +0 -49
- package/src/lib/DemPropertyField/widgets/DemIntegerWidget.tsx +0 -63
- package/src/lib/DemPropertyField/widgets/DemJsonWidget.tsx +0 -33
- package/src/lib/DemPropertyField/widgets/DemStringWidget.tsx +0 -35
- package/src/lib/DemPropertyField/widgets/DemTimeWidget.tsx +0 -46
- package/src/lib/Forms/BackButton.tsx +0 -45
- package/src/lib/Forms/ControlAceEditor.tsx +0 -103
- package/src/lib/Forms/ControlAutocomplete.tsx +0 -134
- package/src/lib/Forms/ControlCheckbox.tsx +0 -57
- package/src/lib/Forms/ControlDebouncedInput.tsx +0 -69
- package/src/lib/Forms/ControlInput.tsx +0 -102
- package/src/lib/Forms/ControlNumberInput.tsx +0 -144
- package/src/lib/Forms/ControlRadioBtn.tsx +0 -46
- package/src/lib/Forms/ControlSelect.tsx +0 -135
- package/src/lib/Forms/CopyButton.tsx +0 -49
- package/src/lib/InfoItem/InfoItem.tsx +0 -39
- package/src/lib/InfoItem/styles.ts +0 -17
- package/src/lib/JsonPathPicker/JsonPathPicker.tsx +0 -71
- package/src/lib/JsonPathPicker/PropertyStep.tsx +0 -74
- package/src/lib/JsonView/JsonView.tsx +0 -43
- package/src/lib/Loader/Loader.tsx +0 -41
- package/src/lib/Modals/JsonModalView.tsx +0 -52
- package/src/lib/Property/PropertyValueField/BooleanValueField.tsx +0 -41
- package/src/lib/Property/PropertyValueField/DateTimeValueField.tsx +0 -59
- package/src/lib/Property/PropertyValueField/DateValueField.tsx +0 -59
- package/src/lib/Property/PropertyValueField/EntityValueField.tsx +0 -33
- package/src/lib/Property/PropertyValueField/JsonValueField.tsx +0 -64
- package/src/lib/Property/PropertyValueField/PropertyValue.tsx +0 -97
- package/src/lib/Property/PropertyValueField/PropertyValueField.tsx +0 -86
- package/src/lib/Property/PropertyValueField/StringValueField.tsx +0 -21
- package/src/lib/Property/PropertyValueField/TimeValueField.tsx +0 -68
- package/src/lib/Property/PropertyValueField/ValueComponent.tsx +0 -63
- package/src/lib/Property/PropertyWidget/PropertyWidget.tsx +0 -167
- package/src/lib/Property/UpsertProperty/CreatePropertiesList.tsx +0 -131
- package/src/lib/Property/UpsertProperty/CreatePropertyFormFields.tsx +0 -147
- package/src/lib/Property/UpsertProperty/CustomPropertyField.tsx +0 -40
- package/src/lib/Property/UpsertProperty/PropertyAdditionalFields/BigDecimalPropertyFields.tsx +0 -41
- package/src/lib/Property/UpsertProperty/PropertyAdditionalFields/DateAdditionalFields.tsx +0 -27
- package/src/lib/Property/UpsertProperty/PropertyAdditionalFields/EntityAdditionalFields.tsx +0 -133
- package/src/lib/Property/UpsertProperty/PropertyAdditionalFields/EntityReferencePropertyFields.tsx +0 -46
- package/src/lib/Property/UpsertProperty/PropertyAdditionalFields/PropertyAdditionalFields.tsx +0 -52
- package/src/lib/Property/UpsertProperty/PropertyAdditionalFields/StringPropertyFields.tsx +0 -98
- package/src/lib/Property/UpsertProperty/useCustomFields.ts +0 -22
- package/src/lib/Property/ViewPropertiesList/ViewPropertiesList.tsx +0 -50
- package/src/lib/Property/ViewProperty/EntityPropertiesShortView.tsx +0 -41
- package/src/lib/Property/ViewProperty/EntityPropertiesView.tsx +0 -48
- package/src/lib/Property/ViewProperty/PropertyDataTable.tsx +0 -139
- package/src/lib/Property/ViewProperty/PropertyItem.tsx +0 -46
- package/src/lib/Property/ViewProperty/ViewProperty.tsx +0 -52
- package/src/lib/Status/Status.tsx +0 -15
- package/src/lib/Status/styles.ts +0 -14
- package/src/lib/Table/Table.tsx +0 -116
- package/src/lib/Table/TableColumnMenu.tsx +0 -12
- package/src/lib/Table/TablePagination.tsx +0 -42
- package/src/lib/Table/index.ts +0 -1
- package/src/lib/Table/styles.ts +0 -59
- package/src/lib/Table/usePagination.ts +0 -15
- package/src/lib/Table/useTableQueryPagination.ts +0 -49
- package/src/lib/Table/useTableQuerySorting.ts +0 -52
- package/src/lib/Tabs/RouteTabs.tsx +0 -54
- package/src/lib/Tabs/TabPanel.tsx +0 -42
- package/src/lib/TemplateContent/ExpressionDecorator.tsx +0 -7
- package/src/lib/TemplateContent/TemplateContentEditor.tsx +0 -144
- package/src/utils/common.ts +0 -68
- package/src/utils/dem.ts +0 -78
- package/src/utils/hooks.ts +0 -41
- package/src/utils/ui-utils.tsx +0 -71
- package/src/utils/validators.ts +0 -130
- package/tsconfig.json +0 -24
- package/tsconfig.lib.json +0 -22
- package/tsconfig.spec.json +0 -19
package/src/utils/ui-utils.tsx
DELETED
@@ -1,71 +0,0 @@
|
|
1
|
-
import Box from '@material-ui/core/Box';
|
2
|
-
import CheckCircleIcon from '@material-ui/icons/CheckCircle';
|
3
|
-
import NotInterestedIcon from '@material-ui/icons/NotInterested';
|
4
|
-
import { JsonView, CopyButton, Status } from '../lib';
|
5
|
-
import { format } from 'date-fns';
|
6
|
-
import { getJsonStringValue } from './common';
|
7
|
-
import { TableDataType } from '../interfaces';
|
8
|
-
|
9
|
-
export const formatTableRowValue = ({
|
10
|
-
value,
|
11
|
-
type,
|
12
|
-
copyText,
|
13
|
-
}: {
|
14
|
-
value: unknown;
|
15
|
-
type?: TableDataType;
|
16
|
-
copyText?: string;
|
17
|
-
}) => {
|
18
|
-
switch (type) {
|
19
|
-
case 'JSON_copy':
|
20
|
-
return (
|
21
|
-
<Box width="100%">
|
22
|
-
<Box display="flex" alignItems="center" justifyContent="flex-end" pt={1} mb={2}>
|
23
|
-
<CopyButton copyText={getJsonStringValue(value)} />
|
24
|
-
</Box>
|
25
|
-
<JsonView value={value} />
|
26
|
-
</Box>
|
27
|
-
);
|
28
|
-
case 'JSON':
|
29
|
-
return <JsonView value={value} />;
|
30
|
-
case 'JSON_text':
|
31
|
-
return (
|
32
|
-
<Box width="100%">
|
33
|
-
<Box overflow="hidden" whiteSpace="nowrap">
|
34
|
-
{typeof value === 'object' ? JSON.stringify(value) : value}
|
35
|
-
</Box>
|
36
|
-
</Box>
|
37
|
-
);
|
38
|
-
case 'copy':
|
39
|
-
return (
|
40
|
-
<Box display="flex" alignItems="center" width="100%">
|
41
|
-
<Box mr="auto">{value}</Box>
|
42
|
-
<CopyButton copyText={(copyText ? copyText : value) as string} />
|
43
|
-
</Box>
|
44
|
-
);
|
45
|
-
case 'boolean':
|
46
|
-
return value ? <CheckCircleIcon color="primary" fontSize="small" /> : <NotInterestedIcon fontSize="small" />;
|
47
|
-
case 'date':
|
48
|
-
return value ? (
|
49
|
-
<div>
|
50
|
-
<div>{format(new Date(value as string), 'dd.MM.yyyy')}</div>
|
51
|
-
<div>{format(new Date(value as string), 'HH:mm:ss')}</div>
|
52
|
-
</div>
|
53
|
-
) : (
|
54
|
-
''
|
55
|
-
);
|
56
|
-
case 'status':
|
57
|
-
return (
|
58
|
-
<Status text={value as string} status={value === 'DEPLOYED' || value === 'ACTIVE' ? 'success' : 'default'} />
|
59
|
-
);
|
60
|
-
case 'array':
|
61
|
-
return (
|
62
|
-
<Box>
|
63
|
-
{(value as string[]).map((val, index) => (
|
64
|
-
<Box key={index}>{val}</Box>
|
65
|
-
))}
|
66
|
-
</Box>
|
67
|
-
);
|
68
|
-
default:
|
69
|
-
return <div>{value}</div>;
|
70
|
-
}
|
71
|
-
};
|
package/src/utils/validators.ts
DELETED
@@ -1,130 +0,0 @@
|
|
1
|
-
import { PropertyType } from '../interfaces';
|
2
|
-
|
3
|
-
export const digitsOnly = new RegExp('^[0-9]+$');
|
4
|
-
export const floatsOnly = new RegExp(/^(?!0\d)\d*(\.(\d+)?)?$/);
|
5
|
-
// const numberRegex = /^\s*[+-]?(\d+|\d*\.\d+|\d+\.\d*)([Ee][+-]?\d+)?\s*$/;
|
6
|
-
|
7
|
-
type ValidationResult = {
|
8
|
-
valid: boolean;
|
9
|
-
message?: string;
|
10
|
-
continuable?: boolean;
|
11
|
-
displayOnChange?: boolean;
|
12
|
-
};
|
13
|
-
|
14
|
-
const MAX_SAFE_LONG = BigInt('9223372036854775807');
|
15
|
-
const MIN_SAFE_LONG = BigInt('-9223372036854775808');
|
16
|
-
|
17
|
-
const MAX_SAFE_INTEGER = 2147483647;
|
18
|
-
const MIN_SAFE_INTEGER = -2147483648;
|
19
|
-
|
20
|
-
export function validateInteger(value: string, type: PropertyType): ValidationResult {
|
21
|
-
let transformValue = value + '';
|
22
|
-
|
23
|
-
const rangeValidatingValue = transformValue;
|
24
|
-
|
25
|
-
if (transformValue && transformValue.startsWith('-')) {
|
26
|
-
transformValue = value.substring(1);
|
27
|
-
}
|
28
|
-
|
29
|
-
if (value === '-') {
|
30
|
-
return {
|
31
|
-
valid: false,
|
32
|
-
message: 'Value cannot be -',
|
33
|
-
continuable: true,
|
34
|
-
};
|
35
|
-
}
|
36
|
-
|
37
|
-
if (!transformValue || !value) {
|
38
|
-
return {
|
39
|
-
valid: false,
|
40
|
-
message: 'Please, fill this field',
|
41
|
-
continuable: true,
|
42
|
-
displayOnChange: true,
|
43
|
-
};
|
44
|
-
}
|
45
|
-
|
46
|
-
if (!digitsOnly.test(transformValue)) {
|
47
|
-
return {
|
48
|
-
valid: false,
|
49
|
-
};
|
50
|
-
}
|
51
|
-
|
52
|
-
if (
|
53
|
-
type === PropertyType.LONG &&
|
54
|
-
(BigInt(rangeValidatingValue) > MAX_SAFE_LONG || BigInt(rangeValidatingValue) < MIN_SAFE_LONG)
|
55
|
-
) {
|
56
|
-
return {
|
57
|
-
valid: false,
|
58
|
-
message: 'Out of Long value range',
|
59
|
-
continuable: true,
|
60
|
-
displayOnChange: true,
|
61
|
-
};
|
62
|
-
}
|
63
|
-
|
64
|
-
if (
|
65
|
-
type === PropertyType.INTEGER &&
|
66
|
-
(Number(rangeValidatingValue) > MAX_SAFE_INTEGER || Number(rangeValidatingValue) < MIN_SAFE_INTEGER)
|
67
|
-
) {
|
68
|
-
return {
|
69
|
-
valid: false,
|
70
|
-
message: 'Out of Integer value range',
|
71
|
-
continuable: true,
|
72
|
-
displayOnChange: true,
|
73
|
-
};
|
74
|
-
}
|
75
|
-
|
76
|
-
return {
|
77
|
-
valid: true,
|
78
|
-
};
|
79
|
-
}
|
80
|
-
|
81
|
-
export function validateFloat(value: string): ValidationResult {
|
82
|
-
let transformValue = value + '';
|
83
|
-
|
84
|
-
if (transformValue && transformValue.startsWith('-')) {
|
85
|
-
transformValue = value.substring(1);
|
86
|
-
}
|
87
|
-
|
88
|
-
if (!floatsOnly.test(transformValue)) {
|
89
|
-
return {
|
90
|
-
valid: false,
|
91
|
-
};
|
92
|
-
}
|
93
|
-
|
94
|
-
if (value === '-') {
|
95
|
-
return {
|
96
|
-
valid: false,
|
97
|
-
message: 'Value cannot be -',
|
98
|
-
continuable: true,
|
99
|
-
};
|
100
|
-
}
|
101
|
-
|
102
|
-
if (transformValue === '.') {
|
103
|
-
return {
|
104
|
-
valid: false,
|
105
|
-
message: 'Value cannot be start with .',
|
106
|
-
continuable: false,
|
107
|
-
};
|
108
|
-
}
|
109
|
-
|
110
|
-
if (value.charAt(value.length - 1) === '.') {
|
111
|
-
return {
|
112
|
-
valid: false,
|
113
|
-
message: 'Value cannot end with .',
|
114
|
-
continuable: true,
|
115
|
-
};
|
116
|
-
}
|
117
|
-
|
118
|
-
if (!transformValue || !value) {
|
119
|
-
return {
|
120
|
-
valid: false,
|
121
|
-
message: 'Please, fill this field',
|
122
|
-
continuable: true,
|
123
|
-
displayOnChange: true,
|
124
|
-
};
|
125
|
-
}
|
126
|
-
|
127
|
-
return {
|
128
|
-
valid: true,
|
129
|
-
};
|
130
|
-
}
|
package/tsconfig.json
DELETED
@@ -1,24 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"extends": "../../tsconfig.base.json",
|
3
|
-
"compilerOptions": {
|
4
|
-
"jsx": "react-jsx",
|
5
|
-
"allowJs": true,
|
6
|
-
"esModuleInterop": true,
|
7
|
-
"allowSyntheticDefaultImports": true,
|
8
|
-
"forceConsistentCasingInFileNames": true,
|
9
|
-
"noImplicitOverride": true,
|
10
|
-
"noPropertyAccessFromIndexSignature": true,
|
11
|
-
"noImplicitReturns": true,
|
12
|
-
"noFallthroughCasesInSwitch": true
|
13
|
-
},
|
14
|
-
"files": [],
|
15
|
-
"include": [],
|
16
|
-
"references": [
|
17
|
-
{
|
18
|
-
"path": "./tsconfig.lib.json"
|
19
|
-
},
|
20
|
-
{
|
21
|
-
"path": "./tsconfig.spec.json"
|
22
|
-
}
|
23
|
-
]
|
24
|
-
}
|
package/tsconfig.lib.json
DELETED
@@ -1,22 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"extends": "./tsconfig.json",
|
3
|
-
"compilerOptions": {
|
4
|
-
"outDir": "../../dist/out-tsc",
|
5
|
-
"types": ["node"]
|
6
|
-
},
|
7
|
-
"files": [
|
8
|
-
"../../node_modules/@nrwl/react/typings/cssmodule.d.ts",
|
9
|
-
"../../node_modules/@nrwl/react/typings/image.d.ts"
|
10
|
-
],
|
11
|
-
"exclude": [
|
12
|
-
"**/*.spec.ts",
|
13
|
-
"**/*.test.ts",
|
14
|
-
"**/*.spec.tsx",
|
15
|
-
"**/*.test.tsx",
|
16
|
-
"**/*.spec.js",
|
17
|
-
"**/*.test.js",
|
18
|
-
"**/*.spec.jsx",
|
19
|
-
"**/*.test.jsx"
|
20
|
-
],
|
21
|
-
"include": ["**/*.js", "**/*.jsx", "**/*.ts", "**/*.tsx"]
|
22
|
-
}
|
package/tsconfig.spec.json
DELETED
@@ -1,19 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"extends": "./tsconfig.json",
|
3
|
-
"compilerOptions": {
|
4
|
-
"outDir": "../../dist/out-tsc",
|
5
|
-
"module": "commonjs",
|
6
|
-
"types": ["jest", "node"]
|
7
|
-
},
|
8
|
-
"include": [
|
9
|
-
"**/*.test.ts",
|
10
|
-
"**/*.spec.ts",
|
11
|
-
"**/*.test.tsx",
|
12
|
-
"**/*.spec.tsx",
|
13
|
-
"**/*.test.js",
|
14
|
-
"**/*.spec.js",
|
15
|
-
"**/*.test.jsx",
|
16
|
-
"**/*.spec.jsx",
|
17
|
-
"**/*.d.ts"
|
18
|
-
]
|
19
|
-
}
|