@draftbit/core 46.10.3-0bad1e.2 → 46.10.3-177666.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/lib/commonjs/components/Checkbox/CheckboxRow.js +6 -23
- package/lib/commonjs/components/FAB.js +4 -18
- package/lib/commonjs/components/Table/Table.js +123 -0
- package/lib/commonjs/components/Table/TableCell.js +49 -0
- package/lib/commonjs/components/Table/TableCommon.js +30 -0
- package/lib/commonjs/components/Table/TableRow.js +61 -0
- package/lib/commonjs/components/Table/index.js +27 -0
- package/lib/commonjs/constants.js +1 -1
- package/lib/commonjs/index.js +19 -7
- package/lib/commonjs/mappings/NativeBase/Layout.js +25 -14
- package/lib/commonjs/mappings/Table.js +140 -0
- package/lib/module/components/Accordion/AccordionItem.js +25 -4
- package/lib/module/components/Table/Table.js +114 -0
- package/lib/module/components/Table/TableCell.js +41 -0
- package/lib/module/components/Table/TableCommon.js +21 -0
- package/lib/module/components/Table/TableRow.js +53 -0
- package/lib/module/components/Table/index.js +3 -0
- package/lib/module/index.js +1 -1
- package/lib/module/mappings/NativeBase/Layout.js +26 -15
- package/lib/module/mappings/Table.js +133 -0
- package/lib/typescript/src/components/Table/Table.d.ts +19 -0
- package/lib/typescript/src/components/Table/Table.d.ts.map +1 -0
- package/lib/typescript/src/components/Table/TableCell.d.ts +9 -0
- package/lib/typescript/src/components/Table/TableCell.d.ts.map +1 -0
- package/lib/typescript/src/components/Table/TableCommon.d.ts +20 -0
- package/lib/typescript/src/components/Table/TableCommon.d.ts.map +1 -0
- package/lib/typescript/src/components/{DeprecatedCardWrapper.d.ts → Table/TableRow.d.ts} +7 -8
- package/lib/typescript/src/components/Table/TableRow.d.ts.map +1 -0
- package/lib/typescript/src/components/Table/index.d.ts +4 -0
- package/lib/typescript/src/components/Table/index.d.ts.map +1 -0
- package/lib/typescript/src/index.d.ts +1 -1
- package/lib/typescript/src/index.d.ts.map +1 -1
- package/lib/typescript/src/mappings/NativeBase/Layout.d.ts +42 -16
- package/lib/typescript/src/mappings/NativeBase/Layout.d.ts.map +1 -1
- package/lib/typescript/src/mappings/{CardBlock.d.ts → Table.d.ts} +129 -81
- package/lib/typescript/src/mappings/Table.d.ts.map +1 -0
- package/package.json +3 -3
- package/src/components/Table/Table.js +93 -0
- package/src/components/Table/Table.tsx +176 -0
- package/src/components/Table/TableCell.js +31 -0
- package/src/components/Table/TableCell.tsx +63 -0
- package/src/components/Table/TableCommon.js +12 -0
- package/src/components/Table/TableCommon.ts +40 -0
- package/src/components/Table/TableRow.js +37 -0
- package/src/components/Table/TableRow.tsx +77 -0
- package/src/components/Table/index.js +3 -0
- package/src/components/Table/index.tsx +3 -0
- package/src/index.js +1 -1
- package/src/index.tsx +2 -1
- package/src/mappings/NativeBase/Layout.js +34 -11
- package/src/mappings/NativeBase/Layout.ts +40 -11
- package/src/mappings/Table.js +150 -0
- package/src/mappings/Table.ts +170 -0
- package/lib/commonjs/components/Container.js +0 -93
- package/lib/commonjs/components/DeprecatedCardWrapper.js +0 -40
- package/lib/commonjs/components/DeprecatedFAB.js +0 -157
- package/lib/commonjs/components/ProgressIndicator.js +0 -55
- package/lib/commonjs/components/ResizeMode.js +0 -5
- package/lib/commonjs/mappings/CardBlock.js +0 -126
- package/lib/commonjs/mappings/CardContainer.js +0 -108
- package/lib/commonjs/mappings/CardContainerRating.js +0 -130
- package/lib/commonjs/mappings/CardContainerShortImage.js +0 -124
- package/lib/commonjs/mappings/CardInline.js +0 -59
- package/lib/commonjs/mappings/Container.js +0 -37
- package/lib/commonjs/mappings/HeaderLarge.js +0 -34
- package/lib/commonjs/mappings/HeaderMedium.js +0 -60
- package/lib/commonjs/mappings/HeaderOverline.js +0 -60
- package/lib/commonjs/mappings/ProgressIndicator.js +0 -188
- package/lib/module/components/Container.js +0 -83
- package/lib/module/components/DeprecatedCardWrapper.js +0 -32
- package/lib/module/components/DeprecatedFAB.js +0 -147
- package/lib/module/components/ProgressIndicator.js +0 -45
- package/lib/module/components/ResizeMode.js +0 -1
- package/lib/module/mappings/CardBlock.js +0 -119
- package/lib/module/mappings/CardContainer.js +0 -101
- package/lib/module/mappings/CardContainerRating.js +0 -123
- package/lib/module/mappings/CardContainerShortImage.js +0 -117
- package/lib/module/mappings/CardInline.js +0 -52
- package/lib/module/mappings/Container.js +0 -30
- package/lib/module/mappings/HeaderLarge.js +0 -27
- package/lib/module/mappings/HeaderMedium.js +0 -53
- package/lib/module/mappings/HeaderOverline.js +0 -53
- package/lib/module/mappings/ProgressIndicator.js +0 -181
- package/lib/typescript/src/components/Container.d.ts +0 -21
- package/lib/typescript/src/components/Container.d.ts.map +0 -1
- package/lib/typescript/src/components/DeprecatedCardWrapper.d.ts.map +0 -1
- package/lib/typescript/src/components/DeprecatedFAB.d.ts +0 -56
- package/lib/typescript/src/components/DeprecatedFAB.d.ts.map +0 -1
- package/lib/typescript/src/components/ProgressIndicator.d.ts +0 -24
- package/lib/typescript/src/components/ProgressIndicator.d.ts.map +0 -1
- package/lib/typescript/src/components/ResizeMode.d.ts +0 -2
- package/lib/typescript/src/components/ResizeMode.d.ts.map +0 -1
- package/lib/typescript/src/mappings/CardBlock.d.ts.map +0 -1
- package/lib/typescript/src/mappings/CardContainer.d.ts +0 -102
- package/lib/typescript/src/mappings/CardContainer.d.ts.map +0 -1
- package/lib/typescript/src/mappings/CardContainerRating.d.ts +0 -108
- package/lib/typescript/src/mappings/CardContainerRating.d.ts.map +0 -1
- package/lib/typescript/src/mappings/CardContainerShortImage.d.ts +0 -139
- package/lib/typescript/src/mappings/CardContainerShortImage.d.ts.map +0 -1
- package/lib/typescript/src/mappings/CardInline.d.ts +0 -62
- package/lib/typescript/src/mappings/CardInline.d.ts.map +0 -1
- package/lib/typescript/src/mappings/Container.d.ts +0 -55
- package/lib/typescript/src/mappings/Container.d.ts.map +0 -1
- package/lib/typescript/src/mappings/HeaderLarge.d.ts +0 -34
- package/lib/typescript/src/mappings/HeaderLarge.d.ts.map +0 -1
- package/lib/typescript/src/mappings/HeaderMedium.d.ts +0 -53
- package/lib/typescript/src/mappings/HeaderMedium.d.ts.map +0 -1
- package/lib/typescript/src/mappings/HeaderOverline.d.ts +0 -53
- package/lib/typescript/src/mappings/HeaderOverline.d.ts.map +0 -1
- package/lib/typescript/src/mappings/ProgressIndicator.d.ts +0 -181
- package/lib/typescript/src/mappings/ProgressIndicator.d.ts.map +0 -1
- package/src/components/Container.js +0 -43
- package/src/components/Container.tsx +0 -116
- package/src/components/DeprecatedCardWrapper.js +0 -18
- package/src/components/DeprecatedCardWrapper.tsx +0 -46
- package/src/components/DeprecatedFAB.js +0 -114
- package/src/components/DeprecatedFAB.tsx +0 -231
- package/src/components/ProgressIndicator.js +0 -27
- package/src/components/ProgressIndicator.tsx +0 -71
- package/src/components/ResizeMode.js +0 -1
- package/src/components/ResizeMode.ts +0 -7
- package/src/mappings/CardBlock.js +0 -123
- package/src/mappings/CardBlock.ts +0 -136
- package/src/mappings/CardContainer.js +0 -104
- package/src/mappings/CardContainer.ts +0 -116
- package/src/mappings/CardContainerRating.js +0 -126
- package/src/mappings/CardContainerRating.ts +0 -137
- package/src/mappings/CardContainerShortImage.js +0 -120
- package/src/mappings/CardContainerShortImage.ts +0 -130
- package/src/mappings/CardInline.js +0 -52
- package/src/mappings/CardInline.ts +0 -61
- package/src/mappings/Container.js +0 -30
- package/src/mappings/Container.ts +0 -41
- package/src/mappings/HeaderLarge.js +0 -29
- package/src/mappings/HeaderLarge.ts +0 -38
- package/src/mappings/HeaderMedium.js +0 -55
- package/src/mappings/HeaderMedium.ts +0 -63
- package/src/mappings/HeaderOverline.js +0 -55
- package/src/mappings/HeaderOverline.ts +0 -63
- package/src/mappings/ProgressIndicator.js +0 -181
- package/src/mappings/ProgressIndicator.ts +0 -190
|
@@ -1,124 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.SEED_DATA = void 0;
|
|
7
|
-
var _types = require("@draftbit/types");
|
|
8
|
-
const SEED_DATA = [{
|
|
9
|
-
name: "Short Card (Left)",
|
|
10
|
-
tag: "CardContainerShortImage",
|
|
11
|
-
description: "An elevated card with a left aligned image and a title and subtitle",
|
|
12
|
-
category: _types.COMPONENT_TYPES.card,
|
|
13
|
-
stylesPanelSections: _types.BLOCK_STYLES_SECTIONS,
|
|
14
|
-
preview_image_url: "{CLOUDINARY_URL}/Card_ContainerShortLeftImage.png",
|
|
15
|
-
supports_list_render: true,
|
|
16
|
-
props: {
|
|
17
|
-
image: {
|
|
18
|
-
group: _types.GROUPS.data,
|
|
19
|
-
label: "Image",
|
|
20
|
-
description: "Image",
|
|
21
|
-
formType: _types.FORM_TYPES.image,
|
|
22
|
-
propType: _types.PROP_TYPES.ASSET,
|
|
23
|
-
defaultValue: null,
|
|
24
|
-
editable: true,
|
|
25
|
-
required: false
|
|
26
|
-
},
|
|
27
|
-
title: {
|
|
28
|
-
group: _types.GROUPS.data,
|
|
29
|
-
label: "Title",
|
|
30
|
-
description: "Title to display",
|
|
31
|
-
formType: _types.FORM_TYPES.string,
|
|
32
|
-
propType: _types.PROP_TYPES.STRING,
|
|
33
|
-
defaultValue: "Beautiful West Coast Villa",
|
|
34
|
-
editable: true,
|
|
35
|
-
required: false
|
|
36
|
-
},
|
|
37
|
-
subtitle: {
|
|
38
|
-
group: _types.GROUPS.data,
|
|
39
|
-
label: "Subtitle",
|
|
40
|
-
description: "Subtitle to display",
|
|
41
|
-
formType: _types.FORM_TYPES.string,
|
|
42
|
-
propType: _types.PROP_TYPES.STRING,
|
|
43
|
-
defaultValue: "San Diego",
|
|
44
|
-
editable: true,
|
|
45
|
-
required: false
|
|
46
|
-
},
|
|
47
|
-
aspectRatio: {
|
|
48
|
-
group: _types.GROUPS.basic,
|
|
49
|
-
label: "Aspect ratio",
|
|
50
|
-
description: "Aspect ratio of the image",
|
|
51
|
-
formType: _types.FORM_TYPES.aspectRatio,
|
|
52
|
-
propType: _types.PROP_TYPES.STRING,
|
|
53
|
-
defaultValue: null,
|
|
54
|
-
editable: true,
|
|
55
|
-
required: false
|
|
56
|
-
},
|
|
57
|
-
elevation: (0, _types.createElevationType)(2),
|
|
58
|
-
mode: {
|
|
59
|
-
group: _types.GROUPS.uncategorized,
|
|
60
|
-
label: "Image Side",
|
|
61
|
-
description: "The side on which the image is on (left or right)",
|
|
62
|
-
formType: _types.FORM_TYPES.flatArray,
|
|
63
|
-
propType: _types.PROP_TYPES.STRING,
|
|
64
|
-
defaultValue: "left",
|
|
65
|
-
options: ["left", "right"],
|
|
66
|
-
editable: false,
|
|
67
|
-
required: false
|
|
68
|
-
}
|
|
69
|
-
},
|
|
70
|
-
layout: {}
|
|
71
|
-
}, {
|
|
72
|
-
name: "Short Card (Right)",
|
|
73
|
-
tag: "CardContainerShortImage",
|
|
74
|
-
description: "An elevated card with a right aligned image and a title and subtitle",
|
|
75
|
-
category: _types.COMPONENT_TYPES.card,
|
|
76
|
-
stylesPanelSections: _types.BLOCK_STYLES_SECTIONS,
|
|
77
|
-
preview_image_url: "{CLOUDINARY_URL}/Card_ContainerShortRightImage.png",
|
|
78
|
-
supports_list_render: true,
|
|
79
|
-
props: {
|
|
80
|
-
image: {
|
|
81
|
-
group: _types.GROUPS.data,
|
|
82
|
-
label: "Image",
|
|
83
|
-
description: "Image",
|
|
84
|
-
formType: _types.FORM_TYPES.image,
|
|
85
|
-
propType: _types.PROP_TYPES.ASSET,
|
|
86
|
-
defaultValue: null,
|
|
87
|
-
editable: true,
|
|
88
|
-
required: false
|
|
89
|
-
},
|
|
90
|
-
title: {
|
|
91
|
-
group: _types.GROUPS.data,
|
|
92
|
-
label: "Title",
|
|
93
|
-
description: "Title to display",
|
|
94
|
-
formType: _types.FORM_TYPES.string,
|
|
95
|
-
propType: _types.PROP_TYPES.STRING,
|
|
96
|
-
defaultValue: "Beautiful West Coast Villa",
|
|
97
|
-
editable: true,
|
|
98
|
-
required: false
|
|
99
|
-
},
|
|
100
|
-
subtitle: {
|
|
101
|
-
group: _types.GROUPS.data,
|
|
102
|
-
label: "Subtitle",
|
|
103
|
-
description: "Subtitle to display",
|
|
104
|
-
formType: _types.FORM_TYPES.string,
|
|
105
|
-
propType: _types.PROP_TYPES.STRING,
|
|
106
|
-
defaultValue: "San Diego",
|
|
107
|
-
editable: true,
|
|
108
|
-
required: false
|
|
109
|
-
},
|
|
110
|
-
elevation: (0, _types.createElevationType)(2),
|
|
111
|
-
mode: {
|
|
112
|
-
label: "Mode",
|
|
113
|
-
description: "Mode",
|
|
114
|
-
group: _types.GROUPS.uncategorized,
|
|
115
|
-
formType: _types.FORM_TYPES.string,
|
|
116
|
-
propType: _types.PROP_TYPES.STRING,
|
|
117
|
-
defaultValue: "right",
|
|
118
|
-
editable: false,
|
|
119
|
-
required: false
|
|
120
|
-
}
|
|
121
|
-
},
|
|
122
|
-
layout: {}
|
|
123
|
-
}];
|
|
124
|
-
exports.SEED_DATA = SEED_DATA;
|
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.SEED_DATA = void 0;
|
|
7
|
-
var _types = require("@draftbit/types");
|
|
8
|
-
const SEED_DATA = {
|
|
9
|
-
name: "Inline Card",
|
|
10
|
-
tag: "CardInline",
|
|
11
|
-
description: "An elevated card with image and a title and description overlayed, that takes up the full width of its container.",
|
|
12
|
-
category: _types.COMPONENT_TYPES.card,
|
|
13
|
-
stylesPanelSections: _types.BLOCK_STYLES_SECTIONS,
|
|
14
|
-
layout: {},
|
|
15
|
-
props: {
|
|
16
|
-
image: {
|
|
17
|
-
group: _types.GROUPS.data,
|
|
18
|
-
label: "Image",
|
|
19
|
-
description: "Image",
|
|
20
|
-
formType: _types.FORM_TYPES.image,
|
|
21
|
-
propType: _types.PROP_TYPES.ASSET,
|
|
22
|
-
defaultValue: null,
|
|
23
|
-
editable: true,
|
|
24
|
-
required: false
|
|
25
|
-
},
|
|
26
|
-
title: {
|
|
27
|
-
group: _types.GROUPS.data,
|
|
28
|
-
label: "Title",
|
|
29
|
-
description: "Text to display",
|
|
30
|
-
formType: _types.FORM_TYPES.string,
|
|
31
|
-
propType: _types.PROP_TYPES.STRING,
|
|
32
|
-
defaultValue: "Beautiful West Coast Villa",
|
|
33
|
-
editable: true,
|
|
34
|
-
required: false
|
|
35
|
-
},
|
|
36
|
-
subtitle: {
|
|
37
|
-
group: _types.GROUPS.data,
|
|
38
|
-
label: "Subtitle",
|
|
39
|
-
description: "Subtitle text",
|
|
40
|
-
formType: _types.FORM_TYPES.string,
|
|
41
|
-
propType: _types.PROP_TYPES.STRING,
|
|
42
|
-
defaultValue: "San Diego",
|
|
43
|
-
editable: true,
|
|
44
|
-
required: false
|
|
45
|
-
},
|
|
46
|
-
aspectRatio: {
|
|
47
|
-
group: _types.GROUPS.basic,
|
|
48
|
-
label: "Aspect ratio",
|
|
49
|
-
description: "Aspect ratio of the image",
|
|
50
|
-
formType: _types.FORM_TYPES.aspectRatio,
|
|
51
|
-
propType: _types.PROP_TYPES.NUMBER,
|
|
52
|
-
defaultValue: 1.5,
|
|
53
|
-
editable: true,
|
|
54
|
-
required: false
|
|
55
|
-
},
|
|
56
|
-
elevation: (0, _types.createElevationType)(2)
|
|
57
|
-
}
|
|
58
|
-
};
|
|
59
|
-
exports.SEED_DATA = SEED_DATA;
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.SEED_DATA = void 0;
|
|
7
|
-
var _types = require("@draftbit/types");
|
|
8
|
-
const SEED_DATA = {
|
|
9
|
-
name: "Container",
|
|
10
|
-
tag: "Container",
|
|
11
|
-
description: "A container component with gutter padding",
|
|
12
|
-
category: _types.COMPONENT_TYPES.deprecated,
|
|
13
|
-
stylesPanelSections: _types.CONTAINER_COMPONENT_STYLES_SECTIONS,
|
|
14
|
-
layout: {
|
|
15
|
-
height: 250
|
|
16
|
-
},
|
|
17
|
-
props: {
|
|
18
|
-
useThemeGutterPadding: {
|
|
19
|
-
group: _types.GROUPS.basic,
|
|
20
|
-
label: "Use gutter padding",
|
|
21
|
-
description: "When true, uses the theme gutter spacing as the container's horizontal padding",
|
|
22
|
-
formType: _types.FORM_TYPES.boolean,
|
|
23
|
-
propType: _types.PROP_TYPES.BOOLEAN,
|
|
24
|
-
defaultValue: false,
|
|
25
|
-
editable: false,
|
|
26
|
-
required: true
|
|
27
|
-
},
|
|
28
|
-
backgroundImage: (0, _types.createImageProp)({
|
|
29
|
-
label: "Background Image",
|
|
30
|
-
description: "Apply a custom background image",
|
|
31
|
-
defaultValue: null
|
|
32
|
-
}),
|
|
33
|
-
backgroundImageResizeMode: (0, _types.createResizeModeProp)(),
|
|
34
|
-
elevation: (0, _types.createElevationType)(0)
|
|
35
|
-
}
|
|
36
|
-
};
|
|
37
|
-
exports.SEED_DATA = SEED_DATA;
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.SEED_DATA = void 0;
|
|
7
|
-
var _types = require("@draftbit/types");
|
|
8
|
-
const SEED_DATA = [{
|
|
9
|
-
name: "Header Large",
|
|
10
|
-
tag: "HeaderLarge",
|
|
11
|
-
description: "A large header with an optional touchable right aligned text and icon.",
|
|
12
|
-
category: _types.COMPONENT_TYPES.header,
|
|
13
|
-
stylesPanelSections: _types.BLOCK_STYLES_SECTIONS,
|
|
14
|
-
layout: {},
|
|
15
|
-
triggers: [_types.Triggers.OnPress],
|
|
16
|
-
props: {
|
|
17
|
-
onPress: (0, _types.createActionProp)(),
|
|
18
|
-
title: (0, _types.createTextProp)({
|
|
19
|
-
label: "Title",
|
|
20
|
-
description: "Text to display",
|
|
21
|
-
defaultValue: "Title"
|
|
22
|
-
}),
|
|
23
|
-
buttonText: (0, _types.createTextProp)({
|
|
24
|
-
label: "Button text",
|
|
25
|
-
description: "Right aligned button text to display",
|
|
26
|
-
defaultValue: "See All"
|
|
27
|
-
}),
|
|
28
|
-
icon: (0, _types.createIconProp)({
|
|
29
|
-
defaultValue: null,
|
|
30
|
-
required: false
|
|
31
|
-
})
|
|
32
|
-
}
|
|
33
|
-
}];
|
|
34
|
-
exports.SEED_DATA = SEED_DATA;
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.SEED_DATA = void 0;
|
|
7
|
-
var _types = require("@draftbit/types");
|
|
8
|
-
const SEED_DATA = [{
|
|
9
|
-
name: "Header Medium",
|
|
10
|
-
tag: "HeaderMedium",
|
|
11
|
-
description: "A medium header with an optional touchable right aligned text and icon.",
|
|
12
|
-
category: _types.COMPONENT_TYPES.header,
|
|
13
|
-
stylesPanelSections: _types.BLOCK_STYLES_SECTIONS,
|
|
14
|
-
preview_image_url: "{CLOUDINARY_URL}/Header_HeadlineMediumIconText.png",
|
|
15
|
-
supports_list_render: false,
|
|
16
|
-
props: {
|
|
17
|
-
title: {
|
|
18
|
-
group: _types.GROUPS.data,
|
|
19
|
-
label: "Title",
|
|
20
|
-
description: "Text to display",
|
|
21
|
-
formType: _types.FORM_TYPES.string,
|
|
22
|
-
propType: _types.PROP_TYPES.STRING,
|
|
23
|
-
defaultValue: "Title",
|
|
24
|
-
editable: true,
|
|
25
|
-
required: false
|
|
26
|
-
},
|
|
27
|
-
buttonText: {
|
|
28
|
-
group: _types.GROUPS.data,
|
|
29
|
-
label: "Button text",
|
|
30
|
-
description: "Right aligned button text to display",
|
|
31
|
-
formType: _types.FORM_TYPES.string,
|
|
32
|
-
propType: _types.PROP_TYPES.STRING,
|
|
33
|
-
defaultValue: "See All",
|
|
34
|
-
editable: true,
|
|
35
|
-
required: false
|
|
36
|
-
},
|
|
37
|
-
icon: {
|
|
38
|
-
group: _types.GROUPS.basic,
|
|
39
|
-
label: "Icon",
|
|
40
|
-
description: "Name of icon to display",
|
|
41
|
-
formType: _types.FORM_TYPES.icon,
|
|
42
|
-
propType: _types.PROP_TYPES.ASSET,
|
|
43
|
-
defaultValue: null,
|
|
44
|
-
editable: true,
|
|
45
|
-
required: false
|
|
46
|
-
},
|
|
47
|
-
onPress: {
|
|
48
|
-
group: _types.GROUPS.basic,
|
|
49
|
-
label: "Action",
|
|
50
|
-
description: "Action to execute when button pressed",
|
|
51
|
-
editable: true,
|
|
52
|
-
required: false,
|
|
53
|
-
formType: _types.FORM_TYPES.action,
|
|
54
|
-
propType: _types.PROP_TYPES.STRING,
|
|
55
|
-
defaultValue: null
|
|
56
|
-
}
|
|
57
|
-
},
|
|
58
|
-
layout: {}
|
|
59
|
-
}];
|
|
60
|
-
exports.SEED_DATA = SEED_DATA;
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.SEED_DATA = void 0;
|
|
7
|
-
var _types = require("@draftbit/types");
|
|
8
|
-
const SEED_DATA = [{
|
|
9
|
-
name: "Header Overline",
|
|
10
|
-
tag: "HeaderOverline",
|
|
11
|
-
description: "A small header with an optional touchable right aligned text and icon.",
|
|
12
|
-
category: _types.COMPONENT_TYPES.header,
|
|
13
|
-
stylesPanelSections: _types.BLOCK_STYLES_SECTIONS,
|
|
14
|
-
preview_image_url: "{CLOUDINARY_URL}/Header_OverlineIconText.png",
|
|
15
|
-
supports_list_render: false,
|
|
16
|
-
props: {
|
|
17
|
-
title: {
|
|
18
|
-
group: _types.GROUPS.data,
|
|
19
|
-
label: "Title",
|
|
20
|
-
description: "Text to display",
|
|
21
|
-
formType: _types.FORM_TYPES.string,
|
|
22
|
-
propType: _types.PROP_TYPES.STRING,
|
|
23
|
-
defaultValue: "Title",
|
|
24
|
-
editable: true,
|
|
25
|
-
required: false
|
|
26
|
-
},
|
|
27
|
-
buttonText: {
|
|
28
|
-
group: _types.GROUPS.data,
|
|
29
|
-
label: "Button text",
|
|
30
|
-
description: "Right aligned button text to display",
|
|
31
|
-
formType: _types.FORM_TYPES.string,
|
|
32
|
-
propType: _types.PROP_TYPES.STRING,
|
|
33
|
-
defaultValue: "See All",
|
|
34
|
-
editable: true,
|
|
35
|
-
required: false
|
|
36
|
-
},
|
|
37
|
-
icon: {
|
|
38
|
-
group: _types.GROUPS.basic,
|
|
39
|
-
label: "Icon",
|
|
40
|
-
description: "Name of icon to display",
|
|
41
|
-
formType: _types.FORM_TYPES.icon,
|
|
42
|
-
propType: _types.PROP_TYPES.ASSET,
|
|
43
|
-
defaultValue: null,
|
|
44
|
-
editable: true,
|
|
45
|
-
required: false
|
|
46
|
-
},
|
|
47
|
-
onPress: {
|
|
48
|
-
group: _types.GROUPS.basic,
|
|
49
|
-
label: "Action",
|
|
50
|
-
description: "Action to execute when button pressed",
|
|
51
|
-
editable: true,
|
|
52
|
-
required: false,
|
|
53
|
-
formType: _types.FORM_TYPES.action,
|
|
54
|
-
propType: _types.PROP_TYPES.STRING,
|
|
55
|
-
defaultValue: null
|
|
56
|
-
}
|
|
57
|
-
},
|
|
58
|
-
layout: {}
|
|
59
|
-
}];
|
|
60
|
-
exports.SEED_DATA = SEED_DATA;
|
|
@@ -1,188 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.SEED_DATA = void 0;
|
|
7
|
-
var _types = require("@draftbit/types");
|
|
8
|
-
const SEED_DATA = {
|
|
9
|
-
name: "Progress Indicator",
|
|
10
|
-
tag: "ProgressIndicator",
|
|
11
|
-
description: "A component used to show current Step in a process",
|
|
12
|
-
category: _types.COMPONENT_TYPES.deprecated,
|
|
13
|
-
stylesPanelSections: _types.BLOCK_STYLES_SECTIONS,
|
|
14
|
-
preview_image_url: "{CLOUDINARY_URL}/Control_Slider.png",
|
|
15
|
-
supports_list_render: false,
|
|
16
|
-
layout: {},
|
|
17
|
-
props: {
|
|
18
|
-
numberOfSteps: {
|
|
19
|
-
group: _types.GROUPS.data,
|
|
20
|
-
label: "Number of Steps",
|
|
21
|
-
description: "The border radius for the thumb",
|
|
22
|
-
editable: true,
|
|
23
|
-
required: false,
|
|
24
|
-
formType: _types.FORM_TYPES.number,
|
|
25
|
-
propType: _types.PROP_TYPES.NUMBER,
|
|
26
|
-
min: 0,
|
|
27
|
-
max: 10,
|
|
28
|
-
step: 1,
|
|
29
|
-
precision: 0,
|
|
30
|
-
defaultValue: 5
|
|
31
|
-
},
|
|
32
|
-
currentStep: {
|
|
33
|
-
group: _types.GROUPS.data,
|
|
34
|
-
label: "Current Step",
|
|
35
|
-
description: "The step that the user is on",
|
|
36
|
-
editable: true,
|
|
37
|
-
required: false,
|
|
38
|
-
formType: _types.FORM_TYPES.number,
|
|
39
|
-
propType: _types.PROP_TYPES.NUMBER,
|
|
40
|
-
min: 0,
|
|
41
|
-
max: 10,
|
|
42
|
-
step: 1,
|
|
43
|
-
precision: 0,
|
|
44
|
-
defaultValue: 5
|
|
45
|
-
},
|
|
46
|
-
stepIndicatorSize: {
|
|
47
|
-
group: _types.GROUPS.basic,
|
|
48
|
-
label: "Step Size",
|
|
49
|
-
description: "The size of the step circle",
|
|
50
|
-
editable: true,
|
|
51
|
-
required: false,
|
|
52
|
-
formType: _types.FORM_TYPES.number,
|
|
53
|
-
propType: _types.PROP_TYPES.NUMBER,
|
|
54
|
-
min: 10,
|
|
55
|
-
max: 100,
|
|
56
|
-
step: 5,
|
|
57
|
-
precision: 0,
|
|
58
|
-
defaultValue: 25
|
|
59
|
-
},
|
|
60
|
-
stepIndicatorLabelFontSize: {
|
|
61
|
-
group: _types.GROUPS.basic,
|
|
62
|
-
label: "Step Font Size",
|
|
63
|
-
description: "The font size of the step number",
|
|
64
|
-
editable: true,
|
|
65
|
-
required: false,
|
|
66
|
-
formType: _types.FORM_TYPES.number,
|
|
67
|
-
propType: _types.PROP_TYPES.NUMBER,
|
|
68
|
-
min: 6,
|
|
69
|
-
max: 36,
|
|
70
|
-
step: 1,
|
|
71
|
-
precision: 0,
|
|
72
|
-
defaultValue: 15
|
|
73
|
-
},
|
|
74
|
-
currentStepIndicatorLabelFontSize: {
|
|
75
|
-
group: _types.GROUPS.basic,
|
|
76
|
-
label: "Current Step Font Size",
|
|
77
|
-
description: "The font size of the current step number",
|
|
78
|
-
editable: true,
|
|
79
|
-
required: false,
|
|
80
|
-
formType: _types.FORM_TYPES.number,
|
|
81
|
-
propType: _types.PROP_TYPES.NUMBER,
|
|
82
|
-
min: 6,
|
|
83
|
-
max: 36,
|
|
84
|
-
step: 1,
|
|
85
|
-
precision: 0,
|
|
86
|
-
defaultValue: 15
|
|
87
|
-
},
|
|
88
|
-
unfinishedColor: {
|
|
89
|
-
group: _types.GROUPS.basic,
|
|
90
|
-
label: "Unfinished Color",
|
|
91
|
-
description: "The color of the step and divider when the step is either not the current step or not finished",
|
|
92
|
-
editable: true,
|
|
93
|
-
required: false,
|
|
94
|
-
formType: _types.FORM_TYPES.color,
|
|
95
|
-
propType: _types.PROP_TYPES.THEME,
|
|
96
|
-
defaultValue: null
|
|
97
|
-
},
|
|
98
|
-
finishedColor: {
|
|
99
|
-
group: _types.GROUPS.basic,
|
|
100
|
-
label: "Finished Color",
|
|
101
|
-
description: "The color of the step and divider when the step is the current step or finished",
|
|
102
|
-
editable: true,
|
|
103
|
-
required: false,
|
|
104
|
-
formType: _types.FORM_TYPES.color,
|
|
105
|
-
propType: _types.PROP_TYPES.THEME,
|
|
106
|
-
defaultValue: null
|
|
107
|
-
},
|
|
108
|
-
stepNumberUnfinishedColor: {
|
|
109
|
-
group: _types.GROUPS.basic,
|
|
110
|
-
label: "Unfinished Number Color",
|
|
111
|
-
description: "The color of the number within the step when unfinished",
|
|
112
|
-
editable: true,
|
|
113
|
-
required: false,
|
|
114
|
-
formType: _types.FORM_TYPES.color,
|
|
115
|
-
propType: _types.PROP_TYPES.THEME,
|
|
116
|
-
defaultValue: null
|
|
117
|
-
},
|
|
118
|
-
stepNumberFinishedColor: {
|
|
119
|
-
group: _types.GROUPS.basic,
|
|
120
|
-
label: "Finished Number Color",
|
|
121
|
-
description: "The color of the number within the step when finished",
|
|
122
|
-
editable: true,
|
|
123
|
-
required: false,
|
|
124
|
-
formType: _types.FORM_TYPES.color,
|
|
125
|
-
propType: _types.PROP_TYPES.THEME,
|
|
126
|
-
defaultValue: null
|
|
127
|
-
},
|
|
128
|
-
stepIndicatorCurrentColor: {
|
|
129
|
-
group: _types.GROUPS.basic,
|
|
130
|
-
label: "Current Step Color",
|
|
131
|
-
description: "The color of current step circle",
|
|
132
|
-
editable: true,
|
|
133
|
-
required: false,
|
|
134
|
-
formType: _types.FORM_TYPES.color,
|
|
135
|
-
propType: _types.PROP_TYPES.THEME,
|
|
136
|
-
defaultValue: null
|
|
137
|
-
},
|
|
138
|
-
stepIndicatorLabelCurrentColor: {
|
|
139
|
-
group: _types.GROUPS.basic,
|
|
140
|
-
label: "Current Step Number Color",
|
|
141
|
-
description: "The color of current number within the step circle",
|
|
142
|
-
editable: true,
|
|
143
|
-
required: false,
|
|
144
|
-
formType: _types.FORM_TYPES.color,
|
|
145
|
-
propType: _types.PROP_TYPES.THEME,
|
|
146
|
-
defaultValue: null
|
|
147
|
-
},
|
|
148
|
-
stepStrokeCurrentColor: {
|
|
149
|
-
group: _types.GROUPS.basic,
|
|
150
|
-
label: "Current Step Border Color",
|
|
151
|
-
description: "The color of current border color of the step",
|
|
152
|
-
editable: true,
|
|
153
|
-
required: false,
|
|
154
|
-
formType: _types.FORM_TYPES.color,
|
|
155
|
-
propType: _types.PROP_TYPES.THEME,
|
|
156
|
-
defaultValue: null
|
|
157
|
-
},
|
|
158
|
-
currentStepStrokeWidth: {
|
|
159
|
-
group: _types.GROUPS.basic,
|
|
160
|
-
label: "Current Step Border Width",
|
|
161
|
-
description: "The width of the border for the current step",
|
|
162
|
-
editable: true,
|
|
163
|
-
required: false,
|
|
164
|
-
formType: _types.FORM_TYPES.number,
|
|
165
|
-
propType: _types.PROP_TYPES.NUMBER,
|
|
166
|
-
min: 1,
|
|
167
|
-
max: 20,
|
|
168
|
-
step: 1,
|
|
169
|
-
precision: 0,
|
|
170
|
-
defaultValue: 0
|
|
171
|
-
},
|
|
172
|
-
currentStepIndicatorSize: {
|
|
173
|
-
group: _types.GROUPS.basic,
|
|
174
|
-
label: "Current Step Size",
|
|
175
|
-
description: "The size of the current step circle",
|
|
176
|
-
editable: true,
|
|
177
|
-
required: false,
|
|
178
|
-
formType: _types.FORM_TYPES.number,
|
|
179
|
-
propType: _types.PROP_TYPES.NUMBER,
|
|
180
|
-
min: 10,
|
|
181
|
-
max: 100,
|
|
182
|
-
step: 5,
|
|
183
|
-
precision: 0,
|
|
184
|
-
defaultValue: null
|
|
185
|
-
}
|
|
186
|
-
}
|
|
187
|
-
};
|
|
188
|
-
exports.SEED_DATA = SEED_DATA;
|
|
@@ -1,83 +0,0 @@
|
|
|
1
|
-
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
2
|
-
import * as React from "react";
|
|
3
|
-
import { View, ImageBackground, StyleSheet } from "react-native";
|
|
4
|
-
import { withTheme } from "../theming";
|
|
5
|
-
import Elevation from "./Elevation";
|
|
6
|
-
const Container = _ref => {
|
|
7
|
-
let {
|
|
8
|
-
useThemeGutterPadding,
|
|
9
|
-
borderColor,
|
|
10
|
-
borderWidth,
|
|
11
|
-
backgroundColor,
|
|
12
|
-
backgroundImage,
|
|
13
|
-
backgroundImageResizeMode,
|
|
14
|
-
elevation,
|
|
15
|
-
style,
|
|
16
|
-
children,
|
|
17
|
-
theme,
|
|
18
|
-
// eslint-disable-line @typescript-eslint/no-unused-vars
|
|
19
|
-
...rest
|
|
20
|
-
} = _ref;
|
|
21
|
-
const {
|
|
22
|
-
flex,
|
|
23
|
-
flexGrow,
|
|
24
|
-
flexWrap,
|
|
25
|
-
flexBasis,
|
|
26
|
-
flexShrink,
|
|
27
|
-
flexDirection,
|
|
28
|
-
alignContent,
|
|
29
|
-
justifyContent,
|
|
30
|
-
alignItems,
|
|
31
|
-
padding,
|
|
32
|
-
paddingTop,
|
|
33
|
-
paddingBottom,
|
|
34
|
-
paddingLeft,
|
|
35
|
-
paddingRight,
|
|
36
|
-
paddingVertical,
|
|
37
|
-
paddingHorizontal,
|
|
38
|
-
...styleProp
|
|
39
|
-
} = StyleSheet.flatten(style) || {};
|
|
40
|
-
const containerStyle = {
|
|
41
|
-
backgroundColor,
|
|
42
|
-
borderColor,
|
|
43
|
-
borderWidth,
|
|
44
|
-
width: "100%",
|
|
45
|
-
...styleProp
|
|
46
|
-
};
|
|
47
|
-
const innerStyle = {
|
|
48
|
-
flex,
|
|
49
|
-
flexGrow,
|
|
50
|
-
flexWrap,
|
|
51
|
-
flexBasis,
|
|
52
|
-
flexShrink,
|
|
53
|
-
flexDirection,
|
|
54
|
-
alignContent,
|
|
55
|
-
justifyContent,
|
|
56
|
-
alignItems,
|
|
57
|
-
padding,
|
|
58
|
-
paddingTop,
|
|
59
|
-
paddingBottom,
|
|
60
|
-
paddingLeft,
|
|
61
|
-
paddingRight,
|
|
62
|
-
paddingVertical,
|
|
63
|
-
paddingHorizontal: paddingHorizontal || useThemeGutterPadding ? 16 : 0
|
|
64
|
-
};
|
|
65
|
-
const Wrap = elevation ? Elevation : View;
|
|
66
|
-
if (elevation) containerStyle.elevation = elevation;
|
|
67
|
-
return /*#__PURE__*/React.createElement(Wrap, _extends({
|
|
68
|
-
style: [containerStyle, style]
|
|
69
|
-
}, rest), backgroundImage ? /*#__PURE__*/React.createElement(ImageBackground, {
|
|
70
|
-
source: typeof backgroundImage === "string" ? {
|
|
71
|
-
uri: backgroundImage
|
|
72
|
-
} : backgroundImage,
|
|
73
|
-
resizeMode: backgroundImageResizeMode,
|
|
74
|
-
style: {
|
|
75
|
-
flex: 1
|
|
76
|
-
}
|
|
77
|
-
}, /*#__PURE__*/React.createElement(View, {
|
|
78
|
-
style: innerStyle
|
|
79
|
-
}, children)) : /*#__PURE__*/React.createElement(View, {
|
|
80
|
-
style: innerStyle
|
|
81
|
-
}, children));
|
|
82
|
-
};
|
|
83
|
-
export default withTheme(Container);
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
2
|
-
import React from "react";
|
|
3
|
-
import { withTheme } from "../theming";
|
|
4
|
-
import Touchable from "./Touchable";
|
|
5
|
-
const getWidth = numColumns => {
|
|
6
|
-
switch (numColumns) {
|
|
7
|
-
case 1:
|
|
8
|
-
return "33%";
|
|
9
|
-
case 2:
|
|
10
|
-
return "50%";
|
|
11
|
-
default:
|
|
12
|
-
return "100%";
|
|
13
|
-
}
|
|
14
|
-
};
|
|
15
|
-
const Card = _ref => {
|
|
16
|
-
let {
|
|
17
|
-
numColumns = 3,
|
|
18
|
-
children,
|
|
19
|
-
onPress,
|
|
20
|
-
style,
|
|
21
|
-
...rest
|
|
22
|
-
} = _ref;
|
|
23
|
-
const width = getWidth(numColumns);
|
|
24
|
-
return /*#__PURE__*/React.createElement(Touchable, _extends({
|
|
25
|
-
disabled: !onPress,
|
|
26
|
-
onPress: onPress,
|
|
27
|
-
style: [style, {
|
|
28
|
-
width
|
|
29
|
-
}]
|
|
30
|
-
}, rest), children);
|
|
31
|
-
};
|
|
32
|
-
export default withTheme(Card);
|