@formio/js 5.1.0-dev.6000.fab85ea → 5.1.0-dev.6002.16f1966
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/formio.form.js +3 -3
- package/dist/formio.form.min.js +1 -1
- package/dist/formio.full.js +4 -4
- package/dist/formio.full.min.js +1 -1
- package/lib/cjs/components/Components.d.ts +3 -0
- package/lib/cjs/components/_classes/component/editForm/Component.edit.conditional.js +1 -1
- package/lib/cjs/components/_classes/component/editForm/Component.edit.data.js +1 -1
- package/lib/cjs/components/_classes/component/editForm/utils.d.ts +1 -0
- package/lib/cjs/components/_classes/component/editForm/utils.js +3 -0
- package/lib/cjs/components/form/editForm/Form.edit.data.js +1 -1
- package/lib/mjs/components/Components.d.ts +3 -0
- package/lib/mjs/components/_classes/component/editForm/Component.edit.conditional.js +1 -1
- package/lib/mjs/components/_classes/component/editForm/Component.edit.data.js +1 -1
- package/lib/mjs/components/_classes/component/editForm/utils.d.ts +1 -0
- package/lib/mjs/components/_classes/component/editForm/utils.js +3 -0
- package/lib/mjs/components/form/editForm/Form.edit.data.js +1 -1
- package/package.json +1 -1
@@ -2,6 +2,7 @@ export default class Components {
|
|
2
2
|
static _editFormUtils: {
|
3
3
|
sortAndFilterComponents(components: any): any;
|
4
4
|
unifyComponents(objValue: any, srcValue: any): any;
|
5
|
+
tokenVariableDescription(): string;
|
5
6
|
logicVariablesTable(additional: any): {
|
6
7
|
type: string;
|
7
8
|
tag: string;
|
@@ -86,6 +87,7 @@ export default class Components {
|
|
86
87
|
static set EditFormUtils(value: {
|
87
88
|
sortAndFilterComponents(components: any): any;
|
88
89
|
unifyComponents(objValue: any, srcValue: any): any;
|
90
|
+
tokenVariableDescription(): string;
|
89
91
|
logicVariablesTable(additional: any): {
|
90
92
|
type: string;
|
91
93
|
tag: string;
|
@@ -169,6 +171,7 @@ export default class Components {
|
|
169
171
|
static get EditFormUtils(): {
|
170
172
|
sortAndFilterComponents(components: any): any;
|
171
173
|
unifyComponents(objValue: any, srcValue: any): any;
|
174
|
+
tokenVariableDescription(): string;
|
172
175
|
logicVariablesTable(additional: any): {
|
173
176
|
type: string;
|
174
177
|
tag: string;
|
@@ -50,6 +50,6 @@ exports.default = [
|
|
50
50
|
},
|
51
51
|
utils_1.default.javaScriptValue('Advanced Conditions', 'customConditional', 'conditional.json', 110, '<p>You must assign the <strong>show</strong> variable a boolean result.</p>' +
|
52
52
|
'<p><strong>Note: Advanced Conditional logic will override the results of the Simple Conditional logic.</strong></p>' +
|
53
|
-
'<h5>Example</h5><pre>show = !!data.showMe;</pre>', '<p><a href="https://help.form.io/userguide/form-building/logic-and-conditions" target="_blank" rel="noopener noreferrer">Click here for an example</a></p>')
|
53
|
+
'<h5>Example</h5><pre>show = !!data.showMe;</pre>', '<p><a href="https://help.form.io/userguide/form-building/logic-and-conditions" target="_blank" rel="noopener noreferrer">Click here for an example</a></p>', utils_1.default.tokenVariableDescription())
|
54
54
|
];
|
55
55
|
/* eslint-enable quotes, max-len */
|
@@ -140,7 +140,7 @@ exports.default = [
|
|
140
140
|
input: true
|
141
141
|
},
|
142
142
|
utils_1.default.javaScriptValue('Custom Default Value', 'customDefaultValue', 'customDefaultValue', 1000, '<p><h4>Example:</h4><pre>value = data.firstName + " " + data.lastName;</pre></p>', '<p><h4>Example:</h4><pre>{"cat": [{"var": "data.firstName"}, " ", {"var": "data.lastName"}]}</pre>'),
|
143
|
-
utils_1.default.javaScriptValue('Calculated Value', 'calculateValue', 'calculateValue', 1100, '<p><h4>Example:</h4><pre>value = data.a + data.b + data.c;</pre></p>', '<p><h4>Example:</h4><pre>{"+": [{"var": "data.a"}, {"var": "data.b"}, {"var": "data.c"}]}</pre><p><a href="https://help.form.io/userguide/form-building/logic-and-conditions#calculated-values" target="_blank" rel="noopener noreferrer">Click here for an example</a></p>',
|
143
|
+
utils_1.default.javaScriptValue('Calculated Value', 'calculateValue', 'calculateValue', 1100, '<p><h4>Example:</h4><pre>value = data.a + data.b + data.c;</pre></p>', '<p><h4>Example:</h4><pre>{"+": [{"var": "data.a"}, {"var": "data.b"}, {"var": "data.c"}]}</pre><p><a href="https://help.form.io/userguide/form-building/logic-and-conditions#calculated-values" target="_blank" rel="noopener noreferrer">Click here for an example</a></p>', utils_1.default.tokenVariableDescription()),
|
144
144
|
{
|
145
145
|
type: 'checkbox',
|
146
146
|
input: true,
|
@@ -2,6 +2,7 @@ export default EditFormUtils;
|
|
2
2
|
declare namespace EditFormUtils {
|
3
3
|
function sortAndFilterComponents(components: any): any;
|
4
4
|
function unifyComponents(objValue: any, srcValue: any): any;
|
5
|
+
function tokenVariableDescription(): string;
|
5
6
|
function logicVariablesTable(additional: any): {
|
6
7
|
type: string;
|
7
8
|
tag: string;
|
@@ -37,6 +37,9 @@ const EditFormUtils = {
|
|
37
37
|
}
|
38
38
|
return lodash_1.default.isEqual(objValue, srcValue);
|
39
39
|
},
|
40
|
+
tokenVariableDescription() {
|
41
|
+
return '<tr><th>token</th><td>The decoded JWT token for the authenticated user.</td></tr>';
|
42
|
+
},
|
40
43
|
logicVariablesTable(additional) {
|
41
44
|
additional = additional || '';
|
42
45
|
return {
|
@@ -11,7 +11,7 @@ exports.default = [
|
|
11
11
|
{
|
12
12
|
weight: 140,
|
13
13
|
type: 'checkbox',
|
14
|
-
label: '
|
14
|
+
label: 'Clear Value When Hidden',
|
15
15
|
key: 'clearOnHide',
|
16
16
|
defaultValue: true,
|
17
17
|
tooltip: 'When a field is hidden, clear the value.',
|
@@ -2,6 +2,7 @@ export default class Components {
|
|
2
2
|
static _editFormUtils: {
|
3
3
|
sortAndFilterComponents(components: any): any;
|
4
4
|
unifyComponents(objValue: any, srcValue: any): any;
|
5
|
+
tokenVariableDescription(): string;
|
5
6
|
logicVariablesTable(additional: any): {
|
6
7
|
type: string;
|
7
8
|
tag: string;
|
@@ -86,6 +87,7 @@ export default class Components {
|
|
86
87
|
static set EditFormUtils(value: {
|
87
88
|
sortAndFilterComponents(components: any): any;
|
88
89
|
unifyComponents(objValue: any, srcValue: any): any;
|
90
|
+
tokenVariableDescription(): string;
|
89
91
|
logicVariablesTable(additional: any): {
|
90
92
|
type: string;
|
91
93
|
tag: string;
|
@@ -169,6 +171,7 @@ export default class Components {
|
|
169
171
|
static get EditFormUtils(): {
|
170
172
|
sortAndFilterComponents(components: any): any;
|
171
173
|
unifyComponents(objValue: any, srcValue: any): any;
|
174
|
+
tokenVariableDescription(): string;
|
172
175
|
logicVariablesTable(additional: any): {
|
173
176
|
type: string;
|
174
177
|
tag: string;
|
@@ -45,6 +45,6 @@ export default [
|
|
45
45
|
},
|
46
46
|
EditFormUtils.javaScriptValue('Advanced Conditions', 'customConditional', 'conditional.json', 110, '<p>You must assign the <strong>show</strong> variable a boolean result.</p>' +
|
47
47
|
'<p><strong>Note: Advanced Conditional logic will override the results of the Simple Conditional logic.</strong></p>' +
|
48
|
-
'<h5>Example</h5><pre>show = !!data.showMe;</pre>', '<p><a href="https://help.form.io/userguide/form-building/logic-and-conditions" target="_blank" rel="noopener noreferrer">Click here for an example</a></p>')
|
48
|
+
'<h5>Example</h5><pre>show = !!data.showMe;</pre>', '<p><a href="https://help.form.io/userguide/form-building/logic-and-conditions" target="_blank" rel="noopener noreferrer">Click here for an example</a></p>', EditFormUtils.tokenVariableDescription())
|
49
49
|
];
|
50
50
|
/* eslint-enable quotes, max-len */
|
@@ -135,7 +135,7 @@ export default [
|
|
135
135
|
input: true
|
136
136
|
},
|
137
137
|
EditFormUtils.javaScriptValue('Custom Default Value', 'customDefaultValue', 'customDefaultValue', 1000, '<p><h4>Example:</h4><pre>value = data.firstName + " " + data.lastName;</pre></p>', '<p><h4>Example:</h4><pre>{"cat": [{"var": "data.firstName"}, " ", {"var": "data.lastName"}]}</pre>'),
|
138
|
-
EditFormUtils.javaScriptValue('Calculated Value', 'calculateValue', 'calculateValue', 1100, '<p><h4>Example:</h4><pre>value = data.a + data.b + data.c;</pre></p>', '<p><h4>Example:</h4><pre>{"+": [{"var": "data.a"}, {"var": "data.b"}, {"var": "data.c"}]}</pre><p><a href="https://help.form.io/userguide/form-building/logic-and-conditions#calculated-values" target="_blank" rel="noopener noreferrer">Click here for an example</a></p>',
|
138
|
+
EditFormUtils.javaScriptValue('Calculated Value', 'calculateValue', 'calculateValue', 1100, '<p><h4>Example:</h4><pre>value = data.a + data.b + data.c;</pre></p>', '<p><h4>Example:</h4><pre>{"+": [{"var": "data.a"}, {"var": "data.b"}, {"var": "data.c"}]}</pre><p><a href="https://help.form.io/userguide/form-building/logic-and-conditions#calculated-values" target="_blank" rel="noopener noreferrer">Click here for an example</a></p>', EditFormUtils.tokenVariableDescription()),
|
139
139
|
{
|
140
140
|
type: 'checkbox',
|
141
141
|
input: true,
|
@@ -2,6 +2,7 @@ export default EditFormUtils;
|
|
2
2
|
declare namespace EditFormUtils {
|
3
3
|
function sortAndFilterComponents(components: any): any;
|
4
4
|
function unifyComponents(objValue: any, srcValue: any): any;
|
5
|
+
function tokenVariableDescription(): string;
|
5
6
|
function logicVariablesTable(additional: any): {
|
6
7
|
type: string;
|
7
8
|
tag: string;
|
@@ -32,6 +32,9 @@ const EditFormUtils = {
|
|
32
32
|
}
|
33
33
|
return _.isEqual(objValue, srcValue);
|
34
34
|
},
|
35
|
+
tokenVariableDescription() {
|
36
|
+
return '<tr><th>token</th><td>The decoded JWT token for the authenticated user.</td></tr>';
|
37
|
+
},
|
35
38
|
logicVariablesTable(additional) {
|
36
39
|
additional = additional || '';
|
37
40
|
return {
|