@builttocreate/engine-utils 2.6.0-beta.9 → 2.6.1-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -7,6 +7,7 @@ exports["default"] = void 0;
|
|
|
7
7
|
// Display Fields
|
|
8
8
|
var uniqueId = 'uniqueId';
|
|
9
9
|
var image = 'image';
|
|
10
|
+
var file = 'file';
|
|
10
11
|
var richText = 'richText';
|
|
11
12
|
var block = 'block'; // Data Fields
|
|
12
13
|
|
|
@@ -26,6 +27,7 @@ var chart = 'chart';
|
|
|
26
27
|
var types = {
|
|
27
28
|
uniqueId: uniqueId,
|
|
28
29
|
image: image,
|
|
30
|
+
file: file,
|
|
29
31
|
block: block,
|
|
30
32
|
richText: richText,
|
|
31
33
|
text: text,
|
|
@@ -46,6 +48,7 @@ types.all = Object.keys(types);
|
|
|
46
48
|
types.titles = {
|
|
47
49
|
uniqueId: 'Auto Number',
|
|
48
50
|
image: 'Image',
|
|
51
|
+
file: 'File',
|
|
49
52
|
block: 'Display Text',
|
|
50
53
|
richText: 'Rich Text',
|
|
51
54
|
text: 'Short Text',
|
package/dist/fieldHelper.js
CHANGED
|
@@ -310,6 +310,8 @@ var isFieldEmpty = function isFieldEmpty(fieldType, fieldValue, fieldOptions) {
|
|
|
310
310
|
isEmpty = true;
|
|
311
311
|
} else if (fieldType === _FieldTypes["default"].image && (!fieldValue || fieldValue && fieldValue.length === 0)) {
|
|
312
312
|
isEmpty = true;
|
|
313
|
+
} else if (fieldType === _FieldTypes["default"].file && (!fieldValue || fieldValue && fieldValue.length === 0)) {
|
|
314
|
+
isEmpty = true;
|
|
313
315
|
} else if (fieldType === _FieldTypes["default"].chart && (!fieldValue || fieldValue && fieldValue.length === 0)) {
|
|
314
316
|
isEmpty = true;
|
|
315
317
|
} else if (fieldType === _FieldTypes["default"].table && (!fieldValue || fieldValue && fieldValue.filter(function (item) {
|
package/dist/joyDocHelper.js
CHANGED
|
@@ -41,10 +41,11 @@ var getDefaultJoyDocPage = function getDefaultJoyDocPage() {
|
|
|
41
41
|
width: 816,
|
|
42
42
|
height: 1056,
|
|
43
43
|
rowHeight: 8,
|
|
44
|
-
cols:
|
|
44
|
+
cols: 8,
|
|
45
45
|
fieldPositions: [],
|
|
46
46
|
layout: _PageLayoutModes["default"].grid,
|
|
47
|
-
presentation: _FieldPresentationModes["default"].normal
|
|
47
|
+
presentation: _FieldPresentationModes["default"].normal,
|
|
48
|
+
padding: 24
|
|
48
49
|
}, defaults);
|
|
49
50
|
};
|
|
50
51
|
/**
|
|
@@ -66,7 +67,10 @@ var getDefaultJoyDocFile = function getDefaultJoyDocFile() {
|
|
|
66
67
|
_id: (0, _generateObjectId["default"])(),
|
|
67
68
|
name: 'New File',
|
|
68
69
|
pageOrder: [page._id],
|
|
69
|
-
pages: [page]
|
|
70
|
+
pages: [page],
|
|
71
|
+
styles: {
|
|
72
|
+
margin: 4
|
|
73
|
+
}
|
|
70
74
|
}, defaults);
|
|
71
75
|
};
|
|
72
76
|
/**
|