@genesislcap/foundation-forms 14.180.0 → 14.180.1-GENC-376.1
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/custom-elements.json +14 -0
- package/dist/dts/jsonforms/renderers/DateControlRenderer.d.ts.map +1 -1
- package/dist/dts/utils/index.d.ts +1 -0
- package/dist/dts/utils/index.d.ts.map +1 -1
- package/dist/dts/utils/types.d.ts +8 -0
- package/dist/dts/utils/types.d.ts.map +1 -0
- package/dist/esm/jsonforms/json-forms.js +2 -2
- package/dist/esm/jsonforms/renderers/DateControlRenderer.js +6 -1
- package/dist/esm/utils/index.js +1 -0
- package/dist/esm/utils/types.js +8 -0
- package/dist/foundation-forms.d.ts +8 -0
- package/docs/api-report.md +10 -0
- package/package.json +14 -14
|
@@ -1058,6 +1058,14 @@
|
|
|
1058
1058
|
"name": "*",
|
|
1059
1059
|
"package": "./validation"
|
|
1060
1060
|
}
|
|
1061
|
+
},
|
|
1062
|
+
{
|
|
1063
|
+
"kind": "js",
|
|
1064
|
+
"name": "*",
|
|
1065
|
+
"declaration": {
|
|
1066
|
+
"name": "*",
|
|
1067
|
+
"package": "./types"
|
|
1068
|
+
}
|
|
1061
1069
|
}
|
|
1062
1070
|
]
|
|
1063
1071
|
},
|
|
@@ -1104,6 +1112,12 @@
|
|
|
1104
1112
|
}
|
|
1105
1113
|
]
|
|
1106
1114
|
},
|
|
1115
|
+
{
|
|
1116
|
+
"kind": "javascript-module",
|
|
1117
|
+
"path": "src/utils/types.ts",
|
|
1118
|
+
"declarations": [],
|
|
1119
|
+
"exports": []
|
|
1120
|
+
},
|
|
1107
1121
|
{
|
|
1108
1122
|
"kind": "javascript-module",
|
|
1109
1123
|
"path": "src/utils/validation.ts",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DateControlRenderer.d.ts","sourceRoot":"","sources":["../../../../src/jsonforms/renderers/DateControlRenderer.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"DateControlRenderer.d.ts","sourceRoot":"","sources":["../../../../src/jsonforms/renderers/DateControlRenderer.ts"],"names":[],"mappings":"AAYA,eAAO,MAAM,2BAA2B,YAAY,MAAM,6DAgCzD,CAAC;AAEF,eAAO,MAAM,wBAAwB,EAAE,GAMtC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/utils/index.ts"],"names":[],"mappings":"AAAA,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC;AACzB,cAAc,eAAe,CAAC;AAC9B,cAAc,cAAc,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/utils/index.ts"],"names":[],"mappings":"AAAA,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC;AACzB,cAAc,eAAe,CAAC;AAC9B,cAAc,cAAc,CAAC;AAC7B,cAAc,SAAS,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/utils/types.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,oBAAY,WAAW;IACrB,IAAI,IAAA;IACJ,QAAQ,IAAA;CACT"}
|
|
@@ -7,9 +7,9 @@ const TIMESTAMP_FIELD = '#/properties/TIMESTAMP';
|
|
|
7
7
|
const template = html `
|
|
8
8
|
<template>
|
|
9
9
|
${when((x) => isDev() && !x.uischema, html `
|
|
10
|
-
|
|
10
|
+
<rapid-button class="clipboard-button" @click=${(x) => x.copyUISchemaToClipboard()}>
|
|
11
11
|
Copy autogenerated UI Schema
|
|
12
|
-
</
|
|
12
|
+
</rapid-button>
|
|
13
13
|
`)}
|
|
14
14
|
${when((x) => x.jsonforms && x.dispatch && x.props, html `
|
|
15
15
|
<dispatch-renderer
|
|
@@ -1,7 +1,12 @@
|
|
|
1
1
|
import { mapStateToControlProps, rankWith } from '@jsonforms/core';
|
|
2
2
|
import { html } from '@microsoft/fast-element';
|
|
3
|
+
import { GenesisType } from '../../utils';
|
|
3
4
|
import { isOneOfDate } from '../testers/isDate';
|
|
4
5
|
import { DATE_CONTROL_RANK } from './RenderersRanks';
|
|
6
|
+
/**
|
|
7
|
+
* @internal
|
|
8
|
+
*/
|
|
9
|
+
const typeSwitch = (control) => { var _a; return ((_a = control.schema) === null || _a === void 0 ? void 0 : _a.genesisType) === GenesisType.DATETIME ? 'datetime-local' : 'date'; };
|
|
5
10
|
export const DateControlRendererTemplate = (prefix = 'zero') => html `
|
|
6
11
|
<template>
|
|
7
12
|
<control-wrapper
|
|
@@ -19,7 +24,7 @@ export const DateControlRendererTemplate = (prefix = 'zero') => html `
|
|
|
19
24
|
timeZone: 'UTC',
|
|
20
25
|
}).format(x.control.data)}
|
|
21
26
|
id=${(x) => x.control.path}
|
|
22
|
-
type="
|
|
27
|
+
type="${(x) => typeSwitch(x.control)}"
|
|
23
28
|
data-test-id=${(x) => x.control.path}
|
|
24
29
|
?required=${(x) => x.control.required}
|
|
25
30
|
?disabled=${(x) => !x.control.enabled}
|
package/dist/esm/utils/index.js
CHANGED
|
@@ -695,6 +695,14 @@ export declare const foundationFormTemplate: ViewTemplate<Form, any>;
|
|
|
695
695
|
/** @public */
|
|
696
696
|
export declare const genesisErrorTranslator: ErrorTranslator;
|
|
697
697
|
|
|
698
|
+
/**
|
|
699
|
+
* @internal
|
|
700
|
+
*/
|
|
701
|
+
export declare enum GenesisType {
|
|
702
|
+
DATE = 0,
|
|
703
|
+
DATETIME = 1
|
|
704
|
+
}
|
|
705
|
+
|
|
698
706
|
/** @internal */
|
|
699
707
|
export declare const getPrefixedForm: (prefix: any) => ViewTemplate<Form, any>;
|
|
700
708
|
|
package/docs/api-report.md
CHANGED
|
@@ -138,6 +138,16 @@ export const foundationFormTemplate: ViewTemplate<Form, any>;
|
|
|
138
138
|
// @public (undocumented)
|
|
139
139
|
export const genesisErrorTranslator: ErrorTranslator;
|
|
140
140
|
|
|
141
|
+
// Warning: (ae-internal-missing-underscore) The name "GenesisType" should be prefixed with an underscore because the declaration is marked as @internal
|
|
142
|
+
//
|
|
143
|
+
// @internal (undocumented)
|
|
144
|
+
export enum GenesisType {
|
|
145
|
+
// (undocumented)
|
|
146
|
+
DATE = 0,
|
|
147
|
+
// (undocumented)
|
|
148
|
+
DATETIME = 1
|
|
149
|
+
}
|
|
150
|
+
|
|
141
151
|
// Warning: (ae-internal-missing-underscore) The name "getPrefixedForm" should be prefixed with an underscore because the declaration is marked as @internal
|
|
142
152
|
//
|
|
143
153
|
// @internal (undocumented)
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@genesislcap/foundation-forms",
|
|
3
3
|
"description": "Genesis Foundation Forms",
|
|
4
|
-
"version": "14.180.
|
|
4
|
+
"version": "14.180.1-GENC-376.1",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"license": "SEE LICENSE IN license.txt",
|
|
7
7
|
"main": "dist/esm/index.js",
|
|
@@ -40,22 +40,22 @@
|
|
|
40
40
|
"test:debug": "genx test --debug"
|
|
41
41
|
},
|
|
42
42
|
"devDependencies": {
|
|
43
|
-
"@genesislcap/foundation-testing": "14.180.
|
|
44
|
-
"@genesislcap/genx": "14.180.
|
|
45
|
-
"@genesislcap/rollup-builder": "14.180.
|
|
46
|
-
"@genesislcap/ts-builder": "14.180.
|
|
47
|
-
"@genesislcap/uvu-playwright-builder": "14.180.
|
|
48
|
-
"@genesislcap/vite-builder": "14.180.
|
|
49
|
-
"@genesislcap/webpack-builder": "14.180.
|
|
43
|
+
"@genesislcap/foundation-testing": "14.180.1-GENC-376.1",
|
|
44
|
+
"@genesislcap/genx": "14.180.1-GENC-376.1",
|
|
45
|
+
"@genesislcap/rollup-builder": "14.180.1-GENC-376.1",
|
|
46
|
+
"@genesislcap/ts-builder": "14.180.1-GENC-376.1",
|
|
47
|
+
"@genesislcap/uvu-playwright-builder": "14.180.1-GENC-376.1",
|
|
48
|
+
"@genesislcap/vite-builder": "14.180.1-GENC-376.1",
|
|
49
|
+
"@genesislcap/webpack-builder": "14.180.1-GENC-376.1",
|
|
50
50
|
"@types/json-schema": "^7.0.11",
|
|
51
51
|
"rimraf": "^3.0.2"
|
|
52
52
|
},
|
|
53
53
|
"dependencies": {
|
|
54
|
-
"@genesislcap/foundation-comms": "14.180.
|
|
55
|
-
"@genesislcap/foundation-criteria": "14.180.
|
|
56
|
-
"@genesislcap/foundation-logger": "14.180.
|
|
57
|
-
"@genesislcap/foundation-ui": "14.180.
|
|
58
|
-
"@genesislcap/foundation-utils": "14.180.
|
|
54
|
+
"@genesislcap/foundation-comms": "14.180.1-GENC-376.1",
|
|
55
|
+
"@genesislcap/foundation-criteria": "14.180.1-GENC-376.1",
|
|
56
|
+
"@genesislcap/foundation-logger": "14.180.1-GENC-376.1",
|
|
57
|
+
"@genesislcap/foundation-ui": "14.180.1-GENC-376.1",
|
|
58
|
+
"@genesislcap/foundation-utils": "14.180.1-GENC-376.1",
|
|
59
59
|
"@json-schema-tools/dereferencer": "^1.6.1",
|
|
60
60
|
"@jsonforms/core": "^3.2.1",
|
|
61
61
|
"@microsoft/fast-components": "^2.30.6",
|
|
@@ -76,5 +76,5 @@
|
|
|
76
76
|
"access": "public"
|
|
77
77
|
},
|
|
78
78
|
"customElements": "dist/custom-elements.json",
|
|
79
|
-
"gitHead": "
|
|
79
|
+
"gitHead": "78e9f228c69c542cd6e3654bfad95f5ed660558d"
|
|
80
80
|
}
|