@draftbit/core 46.4.4-929d79.2 → 46.4.4-970ba7.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/index.js +84 -8
- package/lib/commonjs/mappings/HtmlElements.js +125 -0
- package/lib/module/components/Accordion/AccordionItem.js +26 -5
- package/lib/module/components/Picker/PickerComponent.web.js +23 -5
- package/lib/module/index.js +2 -2
- package/lib/module/mappings/HtmlElements.js +116 -0
- package/lib/typescript/src/index.d.ts +1 -1
- package/lib/typescript/src/mappings/HtmlElements.d.ts +49 -0
- package/package.json +5 -6
- package/src/index.js +1 -1
- package/src/index.tsx +2 -1
- package/src/mappings/HtmlElements.js +141 -0
- package/src/mappings/HtmlElements.ts +151 -0
- package/lib/commonjs/components/Youtube.js +0 -73
- package/lib/commonjs/mappings/Youtube.js +0 -42
- package/lib/module/components/Youtube.js +0 -59
- package/lib/module/mappings/Youtube.js +0 -33
- package/lib/typescript/src/components/Youtube.d.ts +0 -44
- package/lib/typescript/src/mappings/Youtube.d.ts +0 -36
- package/src/components/Youtube.js +0 -38
- package/src/components/Youtube.tsx +0 -66
- package/src/mappings/Youtube.js +0 -33
- package/src/mappings/Youtube.ts +0 -39
package/lib/commonjs/index.js
CHANGED
|
@@ -3,6 +3,76 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
+
var _exportNames = {
|
|
7
|
+
injectIcon: true,
|
|
8
|
+
withTheme: true,
|
|
9
|
+
ThemeProvider: true,
|
|
10
|
+
Provider: true,
|
|
11
|
+
DefaultTheme: true,
|
|
12
|
+
Link: true,
|
|
13
|
+
Banner: true,
|
|
14
|
+
Button: true,
|
|
15
|
+
ButtonSolid: true,
|
|
16
|
+
ButtonOutline: true,
|
|
17
|
+
Avatar: true,
|
|
18
|
+
CircleImage: true,
|
|
19
|
+
AvatarEdit: true,
|
|
20
|
+
Card: true,
|
|
21
|
+
Carousel: true,
|
|
22
|
+
Checkbox: true,
|
|
23
|
+
CheckboxGroup: true,
|
|
24
|
+
CheckboxRow: true,
|
|
25
|
+
Container: true,
|
|
26
|
+
Divider: true,
|
|
27
|
+
FAB: true,
|
|
28
|
+
FieldSearchBarFull: true,
|
|
29
|
+
IconButton: true,
|
|
30
|
+
Image: true,
|
|
31
|
+
SVG: true,
|
|
32
|
+
NumberInput: true,
|
|
33
|
+
ScreenContainer: true,
|
|
34
|
+
StarRating: true,
|
|
35
|
+
Surface: true,
|
|
36
|
+
Switch: true,
|
|
37
|
+
SwitchRow: true,
|
|
38
|
+
TextField: true,
|
|
39
|
+
ToggleButton: true,
|
|
40
|
+
Touchable: true,
|
|
41
|
+
AccordionGroup: true,
|
|
42
|
+
AccordionItem: true,
|
|
43
|
+
ActionSheet: true,
|
|
44
|
+
ActionSheetItem: true,
|
|
45
|
+
ActionSheetCancel: true,
|
|
46
|
+
Swiper: true,
|
|
47
|
+
SwiperItem: true,
|
|
48
|
+
Center: true,
|
|
49
|
+
Circle: true,
|
|
50
|
+
Square: true,
|
|
51
|
+
Row: true,
|
|
52
|
+
Stack: true,
|
|
53
|
+
Spacer: true,
|
|
54
|
+
RadioButton: true,
|
|
55
|
+
RadioButtonGroup: true,
|
|
56
|
+
RadioButtonRow: true,
|
|
57
|
+
RadioButtonFieldGroup: true,
|
|
58
|
+
CardBlock: true,
|
|
59
|
+
CardContainer: true,
|
|
60
|
+
CardContainerRating: true,
|
|
61
|
+
CardInline: true,
|
|
62
|
+
DatePicker: true,
|
|
63
|
+
HeaderLarge: true,
|
|
64
|
+
HeaderMedium: true,
|
|
65
|
+
HeaderOverline: true,
|
|
66
|
+
Picker: true,
|
|
67
|
+
ProgressBar: true,
|
|
68
|
+
ProgressCircle: true,
|
|
69
|
+
RowBodyIcon: true,
|
|
70
|
+
RowHeadlineImageCaption: true,
|
|
71
|
+
RowHeadlineImageIcon: true,
|
|
72
|
+
Slider: true,
|
|
73
|
+
Stepper: true,
|
|
74
|
+
useAuthState: true
|
|
75
|
+
};
|
|
6
76
|
Object.defineProperty(exports, "AccordionGroup", {
|
|
7
77
|
enumerable: true,
|
|
8
78
|
get: function () {
|
|
@@ -393,12 +463,6 @@ Object.defineProperty(exports, "Touchable", {
|
|
|
393
463
|
return _Touchable.default;
|
|
394
464
|
}
|
|
395
465
|
});
|
|
396
|
-
Object.defineProperty(exports, "Youtube", {
|
|
397
|
-
enumerable: true,
|
|
398
|
-
get: function () {
|
|
399
|
-
return _Youtube.default;
|
|
400
|
-
}
|
|
401
|
-
});
|
|
402
466
|
Object.defineProperty(exports, "injectIcon", {
|
|
403
467
|
enumerable: true,
|
|
404
468
|
get: function () {
|
|
@@ -482,6 +546,20 @@ var _Layout = require("./components/Layout");
|
|
|
482
546
|
|
|
483
547
|
var _index = require("./components/RadioButton/index");
|
|
484
548
|
|
|
549
|
+
var _htmlElements = require("@expo/html-elements");
|
|
550
|
+
|
|
551
|
+
Object.keys(_htmlElements).forEach(function (key) {
|
|
552
|
+
if (key === "default" || key === "__esModule") return;
|
|
553
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
554
|
+
if (key in exports && exports[key] === _htmlElements[key]) return;
|
|
555
|
+
Object.defineProperty(exports, key, {
|
|
556
|
+
enumerable: true,
|
|
557
|
+
get: function () {
|
|
558
|
+
return _htmlElements[key];
|
|
559
|
+
}
|
|
560
|
+
});
|
|
561
|
+
});
|
|
562
|
+
|
|
485
563
|
var _CardBlock = _interopRequireDefault(require("./components/CardBlock"));
|
|
486
564
|
|
|
487
565
|
var _CardContainer = _interopRequireDefault(require("./components/CardContainer"));
|
|
@@ -516,8 +594,6 @@ var _Stepper = _interopRequireDefault(require("./components/Stepper"));
|
|
|
516
594
|
|
|
517
595
|
var _useAuthState = require("./components/useAuthState");
|
|
518
596
|
|
|
519
|
-
var _Youtube = _interopRequireDefault(require("./components/Youtube"));
|
|
520
|
-
|
|
521
597
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
522
598
|
|
|
523
599
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.SEED_DATA = void 0;
|
|
7
|
+
|
|
8
|
+
var _types = require("@draftbit/types");
|
|
9
|
+
|
|
10
|
+
const SEED_DATA_TRIGGERS = [_types.Triggers.OnValueChange];
|
|
11
|
+
const ELEMENT_PROPS = {
|
|
12
|
+
category: _types.COMPONENT_TYPES.element,
|
|
13
|
+
doc_link: "https://www.npmjs.com/package/@expo/html-elements",
|
|
14
|
+
code_link: "https://github.com/expo/expo/tree/master/packages/html-elements",
|
|
15
|
+
stylesPanelSections: [_types.StylesPanelSections.Typography, _types.StylesPanelSections.LayoutSelectedItem, _types.StylesPanelSections.MarginsAndPaddings, _types.StylesPanelSections.Effects],
|
|
16
|
+
layout: {
|
|
17
|
+
margin: 0
|
|
18
|
+
},
|
|
19
|
+
triggers: SEED_DATA_TRIGGERS
|
|
20
|
+
};
|
|
21
|
+
const HEADING_PROPS = { ...ELEMENT_PROPS
|
|
22
|
+
};
|
|
23
|
+
const SEED_DATA = [{
|
|
24
|
+
name: "H1",
|
|
25
|
+
tag: "H1",
|
|
26
|
+
...HEADING_PROPS
|
|
27
|
+
}, {
|
|
28
|
+
name: "H2",
|
|
29
|
+
tag: "H2",
|
|
30
|
+
...HEADING_PROPS
|
|
31
|
+
}, {
|
|
32
|
+
name: "H3",
|
|
33
|
+
tag: "H3",
|
|
34
|
+
...HEADING_PROPS
|
|
35
|
+
}, {
|
|
36
|
+
name: "H4",
|
|
37
|
+
tag: "H4",
|
|
38
|
+
...HEADING_PROPS
|
|
39
|
+
}, {
|
|
40
|
+
name: "H5",
|
|
41
|
+
tag: "H5",
|
|
42
|
+
...HEADING_PROPS
|
|
43
|
+
}, {
|
|
44
|
+
name: "H6",
|
|
45
|
+
tag: "H6",
|
|
46
|
+
...HEADING_PROPS
|
|
47
|
+
}, {
|
|
48
|
+
name: "Anchor",
|
|
49
|
+
tag: "A",
|
|
50
|
+
...ELEMENT_PROPS,
|
|
51
|
+
props: {
|
|
52
|
+
href: (0, _types.createTextProp)({
|
|
53
|
+
label: "href",
|
|
54
|
+
description: "Specify the URL",
|
|
55
|
+
defaultValue: ""
|
|
56
|
+
}),
|
|
57
|
+
target: {
|
|
58
|
+
group: _types.GROUPS.basic,
|
|
59
|
+
label: "target",
|
|
60
|
+
description: "decide where link should open",
|
|
61
|
+
formType: _types.FORM_TYPES.flatArray,
|
|
62
|
+
defaultValue: "_blank",
|
|
63
|
+
options: ["_blank", "_self", "_parent", "_top"]
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
}, {
|
|
67
|
+
name: "Paragraph",
|
|
68
|
+
tag: "P",
|
|
69
|
+
...ELEMENT_PROPS,
|
|
70
|
+
props: {// NOTE - Keeping the props commented until we figure out a way to use this props from draftbit side.
|
|
71
|
+
// strong: createBoolProp({
|
|
72
|
+
// label: "Strong",
|
|
73
|
+
// description: "Strong",
|
|
74
|
+
// }),
|
|
75
|
+
// strike: createBoolProp({
|
|
76
|
+
// label: "Strike",
|
|
77
|
+
// description: "Strike through",
|
|
78
|
+
// }),
|
|
79
|
+
// italic: createBoolProp({
|
|
80
|
+
// label: "Italic",
|
|
81
|
+
// description: "Italic Fonts",
|
|
82
|
+
// }),
|
|
83
|
+
// bold: createBoolProp({
|
|
84
|
+
// label: "Bold",
|
|
85
|
+
// description: "Bold",
|
|
86
|
+
// }),
|
|
87
|
+
}
|
|
88
|
+
}, {
|
|
89
|
+
name: "Code",
|
|
90
|
+
tag: "Code",
|
|
91
|
+
...ELEMENT_PROPS
|
|
92
|
+
}, {
|
|
93
|
+
name: "Pre",
|
|
94
|
+
tag: "Pre",
|
|
95
|
+
...ELEMENT_PROPS
|
|
96
|
+
}, {
|
|
97
|
+
name: "Mark",
|
|
98
|
+
tag: "Mark",
|
|
99
|
+
...ELEMENT_PROPS
|
|
100
|
+
}, {
|
|
101
|
+
name: "BR",
|
|
102
|
+
tag: "BR",
|
|
103
|
+
...ELEMENT_PROPS
|
|
104
|
+
}, {
|
|
105
|
+
name: "BlockQuote",
|
|
106
|
+
tag: "BlockQuote",
|
|
107
|
+
...ELEMENT_PROPS
|
|
108
|
+
}, {
|
|
109
|
+
name: "Time",
|
|
110
|
+
tag: "Time",
|
|
111
|
+
...ELEMENT_PROPS
|
|
112
|
+
}, {
|
|
113
|
+
name: "UL",
|
|
114
|
+
tag: "UL",
|
|
115
|
+
...ELEMENT_PROPS
|
|
116
|
+
}, {
|
|
117
|
+
name: "LI",
|
|
118
|
+
tag: "LI",
|
|
119
|
+
...ELEMENT_PROPS
|
|
120
|
+
}, {
|
|
121
|
+
name: "HR",
|
|
122
|
+
tag: "HR",
|
|
123
|
+
...ELEMENT_PROPS
|
|
124
|
+
}];
|
|
125
|
+
exports.SEED_DATA = SEED_DATA;
|
|
@@ -1,5 +1,3 @@
|
|
|
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
|
-
|
|
3
1
|
import * as React from "react";
|
|
4
2
|
import { Pressable, StyleSheet, View } from "react-native";
|
|
5
3
|
import Text from "../Text";
|
|
@@ -20,9 +18,10 @@ const AccordionItem = _ref => {
|
|
|
20
18
|
textStyles,
|
|
21
19
|
viewStyles
|
|
22
20
|
} = extractStyles(style);
|
|
23
|
-
return /*#__PURE__*/React.createElement(Pressable,
|
|
24
|
-
style: [styles.container, viewStyles]
|
|
25
|
-
|
|
21
|
+
return /*#__PURE__*/React.createElement(Pressable, {
|
|
22
|
+
style: [styles.container, viewStyles],
|
|
23
|
+
...rest
|
|
24
|
+
}, /*#__PURE__*/React.createElement(View, {
|
|
26
25
|
style: styles.row
|
|
27
26
|
}, icon ? /*#__PURE__*/React.createElement(Icon, {
|
|
28
27
|
name: icon,
|
|
@@ -36,6 +35,28 @@ const AccordionItem = _ref => {
|
|
|
36
35
|
}, label))));
|
|
37
36
|
};
|
|
38
37
|
|
|
38
|
+
const styles = StyleSheet.create({
|
|
39
|
+
container: {
|
|
40
|
+
padding: 8
|
|
41
|
+
},
|
|
42
|
+
row: {
|
|
43
|
+
flexDirection: "row",
|
|
44
|
+
alignItems: "center",
|
|
45
|
+
paddingLeft: 8
|
|
46
|
+
},
|
|
47
|
+
item: {
|
|
48
|
+
marginVertical: 6,
|
|
49
|
+
paddingLeft: 8
|
|
50
|
+
},
|
|
51
|
+
content: {
|
|
52
|
+
flex: 1,
|
|
53
|
+
justifyContent: "center"
|
|
54
|
+
}
|
|
55
|
+
});
|
|
56
|
+
export default withTheme(AccordionItem);xtStyles
|
|
57
|
+
}, label))));
|
|
58
|
+
};
|
|
59
|
+
|
|
39
60
|
const styles = StyleSheet.create({
|
|
40
61
|
container: {
|
|
41
62
|
padding: 8
|
|
@@ -1,5 +1,3 @@
|
|
|
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
|
-
|
|
3
1
|
import * as React from "react";
|
|
4
2
|
import { View, StyleSheet } from "react-native";
|
|
5
3
|
import { Picker as NativePicker } from "@react-native-picker/picker";
|
|
@@ -10,8 +8,6 @@ import TextField from "../TextField";
|
|
|
10
8
|
import Touchable from "../Touchable";
|
|
11
9
|
|
|
12
10
|
const Picker = _ref => {
|
|
13
|
-
var _options$find$label, _options$find;
|
|
14
|
-
|
|
15
11
|
let {
|
|
16
12
|
style,
|
|
17
13
|
options,
|
|
@@ -21,6 +17,9 @@ const Picker = _ref => {
|
|
|
21
17
|
onValueChange: onValueChangeOverride = () => {},
|
|
22
18
|
...props
|
|
23
19
|
} = _ref;
|
|
20
|
+
|
|
21
|
+
var _a, _b;
|
|
22
|
+
|
|
24
23
|
const {
|
|
25
24
|
viewStyles: {
|
|
26
25
|
borderRadius,
|
|
@@ -67,7 +66,7 @@ const Picker = _ref => {
|
|
|
67
66
|
};
|
|
68
67
|
|
|
69
68
|
const stylesWithoutMargin = style && omit(StyleSheet.flatten(style), ["margin", "marginTop", "marginRight", "marginBottom", "marginLeft"]);
|
|
70
|
-
const selectedLabel = selectedValue && ((
|
|
69
|
+
const selectedLabel = selectedValue && ((_b = (_a = options.find(o => o.value === selectedValue)) === null || _a === void 0 ? void 0 : _a.label) !== null && _b !== void 0 ? _b : selectedValue);
|
|
71
70
|
return /*#__PURE__*/React.createElement(Touchable, {
|
|
72
71
|
disabled: disabled,
|
|
73
72
|
onPress: toggleFocus,
|
|
@@ -90,6 +89,25 @@ const Picker = _ref => {
|
|
|
90
89
|
label: o.label,
|
|
91
90
|
value: o.value,
|
|
92
91
|
key: o.value
|
|
92
|
+
}))), /*#__PURE__*/React.createElement(View, {
|
|
93
|
+
pointerEvents: "none"
|
|
94
|
+
}, /*#__PURE__*/React.createElement(TextField, { ...props,
|
|
95
|
+
value: selectedLabel,
|
|
96
|
+
placeholder: placeholder,
|
|
97
|
+
// @ts-ignore
|
|
98
|
+
ref: textField,
|
|
99
|
+
disabled: disabled,
|
|
100
|
+
// @ts-expect-error
|
|
101
|
+
style: stylesWithoutMargin
|
|
102
|
+
}))));
|
|
103
|
+
};
|
|
104
|
+
|
|
105
|
+
const styles = StyleSheet.create({
|
|
106
|
+
container: {
|
|
107
|
+
alignSelf: "stretch"
|
|
108
|
+
}
|
|
109
|
+
});
|
|
110
|
+
export default withTheme(Picker); key: o.value
|
|
93
111
|
}))), /*#__PURE__*/React.createElement(View, {
|
|
94
112
|
pointerEvents: "none"
|
|
95
113
|
}, /*#__PURE__*/React.createElement(TextField, _extends({}, props, {
|
package/lib/module/index.js
CHANGED
|
@@ -31,6 +31,7 @@ export { ActionSheet, ActionSheetItem, ActionSheetCancel } from "./components/Ac
|
|
|
31
31
|
export { Swiper, SwiperItem } from "./components/Swiper";
|
|
32
32
|
export { Center, Circle, Square, Row, Stack, Spacer } from "./components/Layout";
|
|
33
33
|
export { RadioButton, RadioButtonGroup, RadioButtonRow, RadioButtonFieldGroup } from "./components/RadioButton/index";
|
|
34
|
+
export * from "@expo/html-elements";
|
|
34
35
|
/* Deprecated: Fix or Delete! */
|
|
35
36
|
|
|
36
37
|
export { default as CardBlock } from "./components/CardBlock";
|
|
@@ -49,5 +50,4 @@ export { default as RowHeadlineImageCaption } from "./components/RowHeadlineImag
|
|
|
49
50
|
export { default as RowHeadlineImageIcon } from "./components/RowHeadlineImageIcon";
|
|
50
51
|
export { default as Slider } from "./components/Slider";
|
|
51
52
|
export { default as Stepper } from "./components/Stepper";
|
|
52
|
-
export { useAuthState } from "./components/useAuthState";
|
|
53
|
-
export { default as Youtube } from "./components/Youtube"; // a comment to fix sourcemap comment issue
|
|
53
|
+
export { useAuthState } from "./components/useAuthState"; // a comment to fix sourcemap comment issue
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
import { COMPONENT_TYPES, createTextProp, FORM_TYPES, GROUPS, StylesPanelSections, Triggers } from "@draftbit/types";
|
|
2
|
+
const SEED_DATA_TRIGGERS = [Triggers.OnValueChange];
|
|
3
|
+
const ELEMENT_PROPS = {
|
|
4
|
+
category: COMPONENT_TYPES.element,
|
|
5
|
+
doc_link: "https://www.npmjs.com/package/@expo/html-elements",
|
|
6
|
+
code_link: "https://github.com/expo/expo/tree/master/packages/html-elements",
|
|
7
|
+
stylesPanelSections: [StylesPanelSections.Typography, StylesPanelSections.LayoutSelectedItem, StylesPanelSections.MarginsAndPaddings, StylesPanelSections.Effects],
|
|
8
|
+
layout: {
|
|
9
|
+
margin: 0
|
|
10
|
+
},
|
|
11
|
+
triggers: SEED_DATA_TRIGGERS
|
|
12
|
+
};
|
|
13
|
+
const HEADING_PROPS = { ...ELEMENT_PROPS
|
|
14
|
+
};
|
|
15
|
+
export const SEED_DATA = [{
|
|
16
|
+
name: "H1",
|
|
17
|
+
tag: "H1",
|
|
18
|
+
...HEADING_PROPS
|
|
19
|
+
}, {
|
|
20
|
+
name: "H2",
|
|
21
|
+
tag: "H2",
|
|
22
|
+
...HEADING_PROPS
|
|
23
|
+
}, {
|
|
24
|
+
name: "H3",
|
|
25
|
+
tag: "H3",
|
|
26
|
+
...HEADING_PROPS
|
|
27
|
+
}, {
|
|
28
|
+
name: "H4",
|
|
29
|
+
tag: "H4",
|
|
30
|
+
...HEADING_PROPS
|
|
31
|
+
}, {
|
|
32
|
+
name: "H5",
|
|
33
|
+
tag: "H5",
|
|
34
|
+
...HEADING_PROPS
|
|
35
|
+
}, {
|
|
36
|
+
name: "H6",
|
|
37
|
+
tag: "H6",
|
|
38
|
+
...HEADING_PROPS
|
|
39
|
+
}, {
|
|
40
|
+
name: "Anchor",
|
|
41
|
+
tag: "A",
|
|
42
|
+
...ELEMENT_PROPS,
|
|
43
|
+
props: {
|
|
44
|
+
href: createTextProp({
|
|
45
|
+
label: "href",
|
|
46
|
+
description: "Specify the URL",
|
|
47
|
+
defaultValue: ""
|
|
48
|
+
}),
|
|
49
|
+
target: {
|
|
50
|
+
group: GROUPS.basic,
|
|
51
|
+
label: "target",
|
|
52
|
+
description: "decide where link should open",
|
|
53
|
+
formType: FORM_TYPES.flatArray,
|
|
54
|
+
defaultValue: "_blank",
|
|
55
|
+
options: ["_blank", "_self", "_parent", "_top"]
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
}, {
|
|
59
|
+
name: "Paragraph",
|
|
60
|
+
tag: "P",
|
|
61
|
+
...ELEMENT_PROPS,
|
|
62
|
+
props: {// NOTE - Keeping the props commented until we figure out a way to use this props from draftbit side.
|
|
63
|
+
// strong: createBoolProp({
|
|
64
|
+
// label: "Strong",
|
|
65
|
+
// description: "Strong",
|
|
66
|
+
// }),
|
|
67
|
+
// strike: createBoolProp({
|
|
68
|
+
// label: "Strike",
|
|
69
|
+
// description: "Strike through",
|
|
70
|
+
// }),
|
|
71
|
+
// italic: createBoolProp({
|
|
72
|
+
// label: "Italic",
|
|
73
|
+
// description: "Italic Fonts",
|
|
74
|
+
// }),
|
|
75
|
+
// bold: createBoolProp({
|
|
76
|
+
// label: "Bold",
|
|
77
|
+
// description: "Bold",
|
|
78
|
+
// }),
|
|
79
|
+
}
|
|
80
|
+
}, {
|
|
81
|
+
name: "Code",
|
|
82
|
+
tag: "Code",
|
|
83
|
+
...ELEMENT_PROPS
|
|
84
|
+
}, {
|
|
85
|
+
name: "Pre",
|
|
86
|
+
tag: "Pre",
|
|
87
|
+
...ELEMENT_PROPS
|
|
88
|
+
}, {
|
|
89
|
+
name: "Mark",
|
|
90
|
+
tag: "Mark",
|
|
91
|
+
...ELEMENT_PROPS
|
|
92
|
+
}, {
|
|
93
|
+
name: "BR",
|
|
94
|
+
tag: "BR",
|
|
95
|
+
...ELEMENT_PROPS
|
|
96
|
+
}, {
|
|
97
|
+
name: "BlockQuote",
|
|
98
|
+
tag: "BlockQuote",
|
|
99
|
+
...ELEMENT_PROPS
|
|
100
|
+
}, {
|
|
101
|
+
name: "Time",
|
|
102
|
+
tag: "Time",
|
|
103
|
+
...ELEMENT_PROPS
|
|
104
|
+
}, {
|
|
105
|
+
name: "UL",
|
|
106
|
+
tag: "UL",
|
|
107
|
+
...ELEMENT_PROPS
|
|
108
|
+
}, {
|
|
109
|
+
name: "LI",
|
|
110
|
+
tag: "LI",
|
|
111
|
+
...ELEMENT_PROPS
|
|
112
|
+
}, {
|
|
113
|
+
name: "HR",
|
|
114
|
+
tag: "HR",
|
|
115
|
+
...ELEMENT_PROPS
|
|
116
|
+
}];
|
|
@@ -31,6 +31,7 @@ export { ActionSheet, ActionSheetItem, ActionSheetCancel, } from "./components/A
|
|
|
31
31
|
export { Swiper, SwiperItem } from "./components/Swiper";
|
|
32
32
|
export { Center, Circle, Square, Row, Stack, Spacer, } from "./components/Layout";
|
|
33
33
|
export { RadioButton, RadioButtonGroup, RadioButtonRow, RadioButtonFieldGroup, } from "./components/RadioButton/index";
|
|
34
|
+
export * from "@expo/html-elements";
|
|
34
35
|
export { default as CardBlock } from "./components/CardBlock";
|
|
35
36
|
export { default as CardContainer } from "./components/CardContainer";
|
|
36
37
|
export { default as CardContainerRating } from "./components/CardContainerRating";
|
|
@@ -48,4 +49,3 @@ export { default as RowHeadlineImageIcon } from "./components/RowHeadlineImageIc
|
|
|
48
49
|
export { default as Slider } from "./components/Slider";
|
|
49
50
|
export { default as Stepper } from "./components/Stepper";
|
|
50
51
|
export { useAuthState } from "./components/useAuthState";
|
|
51
|
-
export { default as Youtube } from "./components/Youtube";
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
export declare const SEED_DATA: ({
|
|
2
|
+
category: string;
|
|
3
|
+
doc_link: string;
|
|
4
|
+
code_link: string;
|
|
5
|
+
stylesPanelSections: string[];
|
|
6
|
+
layout: {
|
|
7
|
+
margin: number;
|
|
8
|
+
};
|
|
9
|
+
triggers: string[];
|
|
10
|
+
name: string;
|
|
11
|
+
tag: string;
|
|
12
|
+
} | {
|
|
13
|
+
props: {
|
|
14
|
+
href: any;
|
|
15
|
+
target: {
|
|
16
|
+
group: string;
|
|
17
|
+
label: string;
|
|
18
|
+
description: string;
|
|
19
|
+
formType: string;
|
|
20
|
+
defaultValue: string;
|
|
21
|
+
options: string[];
|
|
22
|
+
};
|
|
23
|
+
};
|
|
24
|
+
category: string;
|
|
25
|
+
doc_link: string;
|
|
26
|
+
code_link: string;
|
|
27
|
+
stylesPanelSections: string[];
|
|
28
|
+
layout: {
|
|
29
|
+
margin: number;
|
|
30
|
+
};
|
|
31
|
+
triggers: string[];
|
|
32
|
+
name: string;
|
|
33
|
+
tag: string;
|
|
34
|
+
} | {
|
|
35
|
+
props: {
|
|
36
|
+
href?: undefined;
|
|
37
|
+
target?: undefined;
|
|
38
|
+
};
|
|
39
|
+
category: string;
|
|
40
|
+
doc_link: string;
|
|
41
|
+
code_link: string;
|
|
42
|
+
stylesPanelSections: string[];
|
|
43
|
+
layout: {
|
|
44
|
+
margin: number;
|
|
45
|
+
};
|
|
46
|
+
triggers: string[];
|
|
47
|
+
name: string;
|
|
48
|
+
tag: string;
|
|
49
|
+
})[];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@draftbit/core",
|
|
3
|
-
"version": "46.4.4-
|
|
3
|
+
"version": "46.4.4-970ba7.2+970ba75",
|
|
4
4
|
"description": "Core (non-native) Components",
|
|
5
5
|
"main": "lib/commonjs/index.js",
|
|
6
6
|
"module": "lib/module/index.js",
|
|
@@ -41,7 +41,8 @@
|
|
|
41
41
|
"dependencies": {
|
|
42
42
|
"@date-io/date-fns": "^1.3.13",
|
|
43
43
|
"@draftbit/react-theme-provider": "^2.1.1",
|
|
44
|
-
"@draftbit/types": "^46.4.4-
|
|
44
|
+
"@draftbit/types": "^46.4.4-970ba7.2+970ba75",
|
|
45
|
+
"@expo/html-elements": "^0.2.0",
|
|
45
46
|
"@material-ui/core": "^4.11.0",
|
|
46
47
|
"@material-ui/pickers": "^3.2.10",
|
|
47
48
|
"@react-native-community/slider": "4.2.3",
|
|
@@ -56,9 +57,7 @@
|
|
|
56
57
|
"react-native-modal-datetime-picker": "^13.0.0",
|
|
57
58
|
"react-native-svg": "12.3.0",
|
|
58
59
|
"react-native-typography": "^1.4.1",
|
|
59
|
-
"react-native-web-swiper": "^2.2.3"
|
|
60
|
-
"react-native-web-webview": "^1.0.2",
|
|
61
|
-
"react-native-youtube-iframe": "^2.2.2"
|
|
60
|
+
"react-native-web-swiper": "^2.2.3"
|
|
62
61
|
},
|
|
63
62
|
"devDependencies": {
|
|
64
63
|
"@types/color": "^3.0.1",
|
|
@@ -83,5 +82,5 @@
|
|
|
83
82
|
]
|
|
84
83
|
]
|
|
85
84
|
},
|
|
86
|
-
"gitHead": "
|
|
85
|
+
"gitHead": "970ba755854683bedbdd39b0de3b6b64cc2f496f"
|
|
87
86
|
}
|
package/src/index.js
CHANGED
|
@@ -31,6 +31,7 @@ export { ActionSheet, ActionSheetItem, ActionSheetCancel, } from "./components/A
|
|
|
31
31
|
export { Swiper, SwiperItem } from "./components/Swiper";
|
|
32
32
|
export { Center, Circle, Square, Row, Stack, Spacer, } from "./components/Layout";
|
|
33
33
|
export { RadioButton, RadioButtonGroup, RadioButtonRow, RadioButtonFieldGroup, } from "./components/RadioButton/index";
|
|
34
|
+
export * from "@expo/html-elements";
|
|
34
35
|
/* Deprecated: Fix or Delete! */
|
|
35
36
|
export { default as CardBlock } from "./components/CardBlock";
|
|
36
37
|
export { default as CardContainer } from "./components/CardContainer";
|
|
@@ -49,5 +50,4 @@ export { default as RowHeadlineImageIcon } from "./components/RowHeadlineImageIc
|
|
|
49
50
|
export { default as Slider } from "./components/Slider";
|
|
50
51
|
export { default as Stepper } from "./components/Stepper";
|
|
51
52
|
export { useAuthState } from "./components/useAuthState";
|
|
52
|
-
export { default as Youtube } from "./components/Youtube";
|
|
53
53
|
// a comment to fix sourcemap comment issue
|
package/src/index.tsx
CHANGED
|
@@ -51,6 +51,8 @@ export {
|
|
|
51
51
|
RadioButtonFieldGroup,
|
|
52
52
|
} from "./components/RadioButton/index";
|
|
53
53
|
|
|
54
|
+
export * from "@expo/html-elements";
|
|
55
|
+
|
|
54
56
|
/* Deprecated: Fix or Delete! */
|
|
55
57
|
export { default as CardBlock } from "./components/CardBlock";
|
|
56
58
|
export { default as CardContainer } from "./components/CardContainer";
|
|
@@ -69,6 +71,5 @@ export { default as RowHeadlineImageIcon } from "./components/RowHeadlineImageIc
|
|
|
69
71
|
export { default as Slider } from "./components/Slider";
|
|
70
72
|
export { default as Stepper } from "./components/Stepper";
|
|
71
73
|
export { useAuthState } from "./components/useAuthState";
|
|
72
|
-
export { default as Youtube } from "./components/Youtube";
|
|
73
74
|
|
|
74
75
|
// a comment to fix sourcemap comment issue
|