@draftbit/core 43.6.1 → 43.6.2-62239f.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.
- package/lib/commonjs/components/IconButton.js +5 -20
- package/lib/commonjs/components/IconButton.js.map +1 -1
- package/lib/commonjs/components/RadioButton/RadioButton.js +15 -3
- package/lib/commonjs/components/Switch.js +22 -10
- package/lib/commonjs/mappings/RadioButtonGroup.js.map +1 -1
- package/lib/commonjs/mappings/Video.js +3 -3
- package/lib/commonjs/mappings/Video.js.map +1 -1
- package/lib/module/components/Checkbox/index.js.map +1 -1
- package/lib/module/mappings/HeaderMedium.js.map +1 -1
- package/lib/module/mappings/Video.js +3 -3
- package/lib/module/mappings/Video.js.map +1 -1
- package/package.json +2 -2
- package/src/mappings/Video.js +3 -3
- package/src/mappings/Video.ts +3 -3
|
@@ -15,6 +15,8 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
|
|
|
15
15
|
|
|
16
16
|
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; }
|
|
17
17
|
|
|
18
|
+
function _extends() { _extends = Object.assign || 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); }
|
|
19
|
+
|
|
18
20
|
const IconButton = _ref => {
|
|
19
21
|
let {
|
|
20
22
|
Icon,
|
|
@@ -29,7 +31,7 @@ const IconButton = _ref => {
|
|
|
29
31
|
...props
|
|
30
32
|
} = _ref;
|
|
31
33
|
const iconColor = customColor || theme.colors.primary;
|
|
32
|
-
return /*#__PURE__*/React.createElement(_reactNative.Pressable, {
|
|
34
|
+
return /*#__PURE__*/React.createElement(_reactNative.Pressable, _extends({
|
|
33
35
|
onPress: onPress,
|
|
34
36
|
disabled: disabled || loading,
|
|
35
37
|
style: _ref2 => {
|
|
@@ -43,9 +45,8 @@ const IconButton = _ref => {
|
|
|
43
45
|
alignItems: "center",
|
|
44
46
|
justifyContent: "center"
|
|
45
47
|
}, style];
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
}, /*#__PURE__*/React.createElement(_reactNative.View, null, icon && !loading ? /*#__PURE__*/React.createElement(Icon, {
|
|
48
|
+
}
|
|
49
|
+
}, props), /*#__PURE__*/React.createElement(_reactNative.View, null, icon && !loading ? /*#__PURE__*/React.createElement(Icon, {
|
|
49
50
|
name: icon,
|
|
50
51
|
size: size - 2,
|
|
51
52
|
color: iconColor
|
|
@@ -70,21 +71,5 @@ const styles = _reactNative.StyleSheet.create({
|
|
|
70
71
|
|
|
71
72
|
var _default = (0, _theming.withTheme)(IconButton);
|
|
72
73
|
|
|
73
|
-
exports.default = _default;
|
|
74
|
-
//# sourceMappingURL=IconButton.js.map({
|
|
75
|
-
container: {
|
|
76
|
-
alignItems: "center",
|
|
77
|
-
justifyContent: "center",
|
|
78
|
-
..._reactNative.Platform.select({
|
|
79
|
-
web: {
|
|
80
|
-
cursor: "pointer",
|
|
81
|
-
userSelect: "none"
|
|
82
|
-
}
|
|
83
|
-
})
|
|
84
|
-
}
|
|
85
|
-
});
|
|
86
|
-
|
|
87
|
-
var _default = (0, _theming.withTheme)(IconButton);
|
|
88
|
-
|
|
89
74
|
exports.default = _default;
|
|
90
75
|
//# sourceMappingURL=IconButton.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["IconButton.
|
|
1
|
+
{"version":3,"sources":["IconButton.tsx"],"names":["IconButton","Icon","icon","color","customColor","size","disabled","loading","onPress","theme","style","props","iconColor","colors","primary","pressed","styles","container","opacity","width","height","alignItems","justifyContent","StyleSheet","create","Platform","select","web","cursor","userSelect"],"mappings":";;;;;;;AAAA;;AACA;;AAUA;;;;;;;;AAgBA,MAAMA,UAA2B,GAAG,QAW9B;AAAA,MAX+B;AACnCC,IAAAA,IADmC;AAEnCC,IAAAA,IAFmC;AAGnCC,IAAAA,KAAK,EAAEC,WAH4B;AAInCC,IAAAA,IAAI,GAAG,EAJ4B;AAKnCC,IAAAA,QAAQ,GAAG,KALwB;AAMnCC,IAAAA,OAAO,GAAG,KANyB;AAOnCC,IAAAA,OAPmC;AAQnCC,IAAAA,KARmC;AASnCC,IAAAA,KATmC;AAUnC,OAAGC;AAVgC,GAW/B;AACJ,QAAMC,SAAS,GAAGR,WAAW,IAAIK,KAAK,CAACI,MAAN,CAAaC,OAA9C;AAEA,sBACE,oBAAC,sBAAD;AACE,IAAA,OAAO,EAAEN,OADX;AAEE,IAAA,QAAQ,EAAEF,QAAQ,IAAIC,OAFxB;AAGE,IAAA,KAAK,EAAE,SAAiB;AAAA,UAAhB;AAAEQ,QAAAA;AAAF,OAAgB;AACtB,aAAO,CACLC,MAAM,CAACC,SADF,EAEL;AACEC,QAAAA,OAAO,EAAEH,OAAO,IAAIT,QAAX,GAAsB,IAAtB,GAA6B,CADxC;AAEEa,QAAAA,KAAK,EAAEd,IAFT;AAGEe,QAAAA,MAAM,EAAEf,IAHV;AAIEgB,QAAAA,UAAU,EAAE,QAJd;AAKEC,QAAAA,cAAc,EAAE;AALlB,OAFK,EASLZ,KATK,CAAP;AAWD;AAfH,KAgBMC,KAhBN,gBAkBE,oBAAC,iBAAD,QACGT,IAAI,IAAI,CAACK,OAAT,gBACC,oBAAC,IAAD;AAAM,IAAA,IAAI,EAAEL,IAAZ;AAAkB,IAAA,IAAI,EAAEG,IAAI,GAAG,CAA/B;AAAkC,IAAA,KAAK,EAAEO;AAAzC,IADD,GAEG,IAHN,EAIGL,OAAO,gBAAG,oBAAC,8BAAD;AAAmB,IAAA,IAAI,EAAC,OAAxB;AAAgC,IAAA,KAAK,EAAEK;AAAvC,IAAH,GAA0D,IAJpE,CAlBF,CADF;AA2BD,CAzCD;;AA2CA,MAAMI,MAAM,GAAGO,wBAAWC,MAAX,CAAkB;AAC/BP,EAAAA,SAAS,EAAE;AACTI,IAAAA,UAAU,EAAE,QADH;AAETC,IAAAA,cAAc,EAAE,QAFP;AAGT,OAAGG,sBAASC,MAAT,CAAgB;AACjBC,MAAAA,GAAG,EAAE;AACHC,QAAAA,MAAM,EAAE,SADL;AAEHC,QAAAA,UAAU,EAAE;AAFT;AADY,KAAhB;AAHM;AADoB,CAAlB,CAAf;;eAae,wBAAU7B,UAAV,C","sourcesContent":["import * as React from \"react\";\nimport {\n View,\n StyleSheet,\n ActivityIndicator,\n StyleProp,\n ViewStyle,\n Pressable,\n PressableProps,\n Platform,\n} from \"react-native\";\nimport { withTheme } from \"../theming\";\nimport type { Theme } from \"../styles/DefaultTheme\";\nimport type { IconSlot } from \"../interfaces/Icon\";\n\ntype Props = {\n icon?: string;\n color?: string;\n size?: number;\n disabled?: boolean;\n loading?: boolean;\n onPress: () => void;\n theme: Theme;\n style?: StyleProp<ViewStyle>;\n} & PressableProps &\n IconSlot;\n\nconst IconButton: React.FC<Props> = ({\n Icon,\n icon,\n color: customColor,\n size = 32,\n disabled = false,\n loading = false,\n onPress,\n theme,\n style,\n ...props\n}) => {\n const iconColor = customColor || theme.colors.primary;\n\n return (\n <Pressable\n onPress={onPress}\n disabled={disabled || loading}\n style={({ pressed }) => {\n return [\n styles.container,\n {\n opacity: pressed || disabled ? 0.75 : 1,\n width: size,\n height: size,\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n style,\n ];\n }}\n {...props}\n >\n <View>\n {icon && !loading ? (\n <Icon name={icon} size={size - 2} color={iconColor} />\n ) : null}\n {loading ? <ActivityIndicator size=\"small\" color={iconColor} /> : null}\n </View>\n </Pressable>\n );\n};\n\nconst styles = StyleSheet.create({\n container: {\n alignItems: \"center\",\n justifyContent: \"center\",\n ...Platform.select({\n web: {\n cursor: \"pointer\",\n userSelect: \"none\",\n },\n }),\n },\n});\n\nexport default withTheme(IconButton);\n"]}
|
|
@@ -21,8 +21,6 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
|
|
|
21
21
|
|
|
22
22
|
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; }
|
|
23
23
|
|
|
24
|
-
function _extends() { _extends = Object.assign || 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); }
|
|
25
|
-
|
|
26
24
|
const RadioButton = _ref => {
|
|
27
25
|
let {
|
|
28
26
|
Icon,
|
|
@@ -51,7 +49,21 @@ const RadioButton = _ref => {
|
|
|
51
49
|
onValueChange === null || onValueChange === void 0 ? void 0 : onValueChange(realValue);
|
|
52
50
|
};
|
|
53
51
|
|
|
54
|
-
return /*#__PURE__*/React.createElement(_IconButton.default,
|
|
52
|
+
return /*#__PURE__*/React.createElement(_IconButton.default, {
|
|
53
|
+
Icon: Icon,
|
|
54
|
+
icon: isSelected ? selectedIcon : unselectedIcon,
|
|
55
|
+
color: isSelected ? color : unselectedColor,
|
|
56
|
+
disabled: disabled,
|
|
57
|
+
onPress: handlePress,
|
|
58
|
+
size: size,
|
|
59
|
+
style: style,
|
|
60
|
+
...rest
|
|
61
|
+
});
|
|
62
|
+
};
|
|
63
|
+
|
|
64
|
+
var _default = RadioButton;
|
|
65
|
+
exports.default = _default;
|
|
66
|
+
//# sourceMappingURL=RadioButton.js.maptends({
|
|
55
67
|
Icon: Icon,
|
|
56
68
|
icon: isSelected ? selectedIcon : unselectedIcon,
|
|
57
69
|
color: isSelected ? color : unselectedColor,
|
|
@@ -23,8 +23,6 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
|
|
|
23
23
|
|
|
24
24
|
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; }
|
|
25
25
|
|
|
26
|
-
function _extends() { _extends = Object.assign || 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); }
|
|
27
|
-
|
|
28
26
|
function Switch(_ref) {
|
|
29
27
|
let {
|
|
30
28
|
value,
|
|
@@ -57,23 +55,24 @@ function Switch(_ref) {
|
|
|
57
55
|
setChecked(Boolean(defaultValue));
|
|
58
56
|
}
|
|
59
57
|
}, [defaultValue, previousDefaultValue]);
|
|
60
|
-
return /*#__PURE__*/React.createElement(_reactNative.Switch,
|
|
58
|
+
return /*#__PURE__*/React.createElement(_reactNative.Switch, {
|
|
61
59
|
value: checked,
|
|
62
60
|
disabled: disabled,
|
|
63
61
|
trackColor: {
|
|
64
62
|
false: inactiveTrackThemeColor,
|
|
65
63
|
true: activeTrackThemeColor
|
|
66
64
|
},
|
|
67
|
-
thumbColor: value ? activeThumbThemeColor : inactiveThumbThemeColor
|
|
68
|
-
|
|
65
|
+
thumbColor: value ? activeThumbThemeColor : inactiveThumbThemeColor,
|
|
66
|
+
// @ts-ignore react-native-web only
|
|
69
67
|
activeThumbColor: activeThumbThemeColor,
|
|
70
68
|
ios_backgroundColor: inactiveTrackThemeColor,
|
|
71
69
|
style: style,
|
|
72
70
|
onValueChange: bool => {
|
|
73
71
|
setChecked(bool);
|
|
74
72
|
onValueChange && onValueChange(bool);
|
|
75
|
-
}
|
|
76
|
-
|
|
73
|
+
},
|
|
74
|
+
...rest
|
|
75
|
+
});
|
|
77
76
|
}
|
|
78
77
|
|
|
79
78
|
function Row(_ref2) {
|
|
@@ -103,7 +102,7 @@ function Row(_ref2) {
|
|
|
103
102
|
setChecked(defaultValue);
|
|
104
103
|
}
|
|
105
104
|
}, [defaultValue]);
|
|
106
|
-
return /*#__PURE__*/React.createElement(_FormRow.default,
|
|
105
|
+
return /*#__PURE__*/React.createElement(_FormRow.default, {
|
|
107
106
|
disabled: disabled,
|
|
108
107
|
onPress: () => {
|
|
109
108
|
setChecked(!checked);
|
|
@@ -111,8 +110,9 @@ function Row(_ref2) {
|
|
|
111
110
|
},
|
|
112
111
|
label: label,
|
|
113
112
|
direction: direction,
|
|
114
|
-
style: style
|
|
115
|
-
|
|
113
|
+
style: style,
|
|
114
|
+
...rest
|
|
115
|
+
}, /*#__PURE__*/React.createElement(Switch, {
|
|
116
116
|
theme: theme,
|
|
117
117
|
value: checked,
|
|
118
118
|
disabled: disabled,
|
|
@@ -129,5 +129,17 @@ exports.SwitchRow = SwitchRow;
|
|
|
129
129
|
|
|
130
130
|
var _default = (0, _theming.withTheme)(Switch);
|
|
131
131
|
|
|
132
|
+
exports.default = _default;
|
|
133
|
+
//# sourceMappingURL=Switch.js.map inactiveTrackColor: inactiveTrackColor,
|
|
134
|
+
activeThumbColor: activeThumbColor,
|
|
135
|
+
inactiveThumbColor: inactiveThumbColor
|
|
136
|
+
}));
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
const SwitchRow = (0, _theming.withTheme)(Row);
|
|
140
|
+
exports.SwitchRow = SwitchRow;
|
|
141
|
+
|
|
142
|
+
var _default = (0, _theming.withTheme)(Switch);
|
|
143
|
+
|
|
132
144
|
exports.default = _default;
|
|
133
145
|
//# sourceMappingURL=Switch.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["RadioButtonGroup.
|
|
1
|
+
{"version":3,"sources":["RadioButtonGroup.ts"],"names":["SEED_DATA","name","tag","category","COMPONENT_TYPES","input","layout","triggers","Triggers","OnValueChange","props","direction","fieldName","handlerPropName","valuePropName","defaultValue"],"mappings":";;;;;;;AAAA;;AAOO,MAAMA,SAAS,GAAG;AACvBC,EAAAA,IAAI,EAAE,oBADiB;AAEvBC,EAAAA,GAAG,EAAE,kBAFkB;AAGvBC,EAAAA,QAAQ,EAAEC,uBAAgBC,KAHH;AAIvBC,EAAAA,MAAM,EAAE,EAJe;AAKvBC,EAAAA,QAAQ,EAAE,CAACC,gBAASC,aAAV,CALa;AAMvBC,EAAAA,KAAK,EAAE;AACLC,IAAAA,SAAS,EAAE,iCADN;AAELC,IAAAA,SAAS,EAAE,gCAAoB;AAC7BC,MAAAA,eAAe,EAAE,eADY;AAE7BC,MAAAA,aAAa,EAAE,OAFc;AAG7BC,MAAAA,YAAY,EAAE;AAHe,KAApB;AAFN;AANgB,CAAlB","sourcesContent":["import {\n COMPONENT_TYPES,\n createFieldNameProp,\n createDirectionProp,\n Triggers,\n} from \"@draftbit/types\";\n\nexport const SEED_DATA = {\n name: \"Radio Button Group\",\n tag: \"RadioButtonGroup\",\n category: COMPONENT_TYPES.input,\n layout: {},\n triggers: [Triggers.OnValueChange],\n props: {\n direction: createDirectionProp(),\n fieldName: createFieldNameProp({\n handlerPropName: \"onValueChange\",\n valuePropName: \"value\",\n defaultValue: \"radioButtonGroupValue\",\n }),\n },\n};\n"]}
|
|
@@ -24,15 +24,15 @@ const SEED_DATA = {
|
|
|
24
24
|
defaultValue: "http://static.draftbit.com/videos/intro-to-draftbit.mp4"
|
|
25
25
|
}),
|
|
26
26
|
usePoster: (0, _types.createStaticBoolProp)({
|
|
27
|
-
label: "Thumbnail",
|
|
27
|
+
label: "Use Thumbnail",
|
|
28
28
|
description: "Show a thumbnail before the video starts.",
|
|
29
29
|
defaultValue: false
|
|
30
30
|
}),
|
|
31
31
|
posterSource: (0, _types.createSourceProp)({
|
|
32
32
|
label: "Thumbnail Source",
|
|
33
33
|
description: "The optional image to display over the video while it is loading.",
|
|
34
|
-
defaultValue:
|
|
35
|
-
|
|
34
|
+
defaultValue: null,
|
|
35
|
+
required: false
|
|
36
36
|
}),
|
|
37
37
|
resizeMode: (0, _types.createResizeModeProp)(),
|
|
38
38
|
isMuted: (0, _types.createStaticBoolProp)({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["Video.ts"],"names":["SEED_DATA","name","tag","description","doc_link","code_link","category","COMPONENT_TYPES","media","layout","height","props","source","label","defaultValue","usePoster","posterSource","
|
|
1
|
+
{"version":3,"sources":["Video.ts"],"names":["SEED_DATA","name","tag","description","doc_link","code_link","category","COMPONENT_TYPES","media","layout","height","props","source","label","defaultValue","usePoster","posterSource","required","resizeMode","isMuted","useNativeControls","shouldPlay","isLooping","positionMillis","min","step","precision","group","GROUPS","basic","rate","max","volume"],"mappings":";;;;;;;AAAA;;AASO,MAAMA,SAAS,G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mB,IAAAA,SAAS,EAAE,iCAAqB;AAC9BT,MAAAA,KAAK,EAAE,YADuB;AAE9BV,MAAAA,WAAW,EAAE;AAFiB,KAArB,CAjCN;AAqCLoB,IAAAA,cAAc,EAAE,6BAAiB;AAC/BV,MAAAA,KAAK,EAAE,gBADwB;AAE/BV,MAAAA,WAAW,EAAE,2CAFkB;AAG/BqB,MAAAA,GAAG,EAAE,CAH0B;AAI/BC,MAAAA,IAAI,EAAE,IAJyB;AAK/BC,MAAAA,SAAS,EAAE,CALoB;AAM/BC,MAAAA,KAAK,EAAEC,cAAOC;AANiB,KAAjB,CArCX;AA6CLC,IAAAA,IAAI,EAAE,6BAAiB;AACrBjB,MAAAA,KAAK,EAAE,eADc;AAErBV,MAAAA,WAAW,EACT,sFAHmB;AAIrBqB,MAAAA,GAAG,EAAE,CAJgB;AAKrBO,MAAAA,GAAG,EAAE,EALgB;AAMrBN,MAAAA,IAAI,EAAE,IANe;AAOrBC,MAAAA,SAAS,EAAE,CAPU;AAQrBC,MAAAA,KAAK,EAAEC,cAAOC;AARO,KAAjB,CA7CD;AAuDLG,IAAAA,MAAM,EAAE,6BAAiB;AACvBnB,MAAAA,KAAK,EAAE,QADgB;AAEvBV,MAAAA,WAAW,EACT,0HAHqB;AAIvBqB,MAAAA,GAAG,EAAE,CAJkB;AAKvBO,MAAAA,GAAG,EAAE,CALkB;AAMvBN,MAAAA,IAAI,EAAE,GANiB;AAOvBC,MAAAA,SAAS,EAAE,CAPY;AAQvBC,MAAAA,KAAK,EAAEC,cAAOC;AARS,KAAjB;AAvDH;AAXgB,CAAlB","sourcesContent":["import {\n COMPONENT_TYPES,\n createStaticBoolProp,\n createSourceProp,\n createResizeModeProp,\n createNumberProp,\n GROUPS,\n} from \"@draftbit/types\";\n\nexport const SEED_DATA = {\n name: \"Video\",\n tag: \"Video\",\n description: \"Given a URL, display a video\",\n doc_link: \"https://docs.expo.io/versions/latest/sdk/video/\",\n code_link:\n \"https://github.com/expo/expo/blob/master/packages/expo-av/src/Video.tsx\",\n category: COMPONENT_TYPES.media,\n layout: {\n height: 215,\n },\n props: {\n source: createSourceProp({\n label: \"Source\",\n description: \"The source of the video data to display.\",\n defaultValue: \"http://static.draftbit.com/videos/intro-to-draftbit.mp4\",\n }),\n usePoster: createStaticBoolProp({\n label: \"Use Thumbnail\",\n description: \"Show a thumbnail before the video starts.\",\n defaultValue: false,\n }),\n posterSource: createSourceProp({\n label: \"Thumbnail Source\",\n description:\n \"The optional image to display over the video while it is loading.\",\n defaultValue: null,\n required: false,\n }),\n resizeMode: createResizeModeProp(),\n isMuted: createStaticBoolProp({\n label: \"Mute Audio\",\n description: \"Mute the audio of the video.\",\n }),\n useNativeControls: createStaticBoolProp({\n label: \"Use Native Controls\",\n description:\n \"Display the playback controls, allowing users to play or pause the video.\",\n defaultValue: true,\n }),\n shouldPlay: createStaticBoolProp({\n label: \"Play Automatically\",\n description: \"Start playing the video after loading is finished.\",\n }),\n isLooping: createStaticBoolProp({\n label: \"Loop Video\",\n description: \"Automatically replay the video.\",\n }),\n positionMillis: createNumberProp({\n label: \"Starting Point\",\n description: \"Set a certian starting point of the video\",\n min: 0,\n step: 0.01,\n precision: 2,\n group: GROUPS.basic,\n }),\n rate: createNumberProp({\n label: \"Playback Rate\",\n description:\n \"The playback rate of the media. This value must be between 0.0 and 32.0 (Default: 1)\",\n min: 0,\n max: 32,\n step: 0.25,\n precision: 2,\n group: GROUPS.basic,\n }),\n volume: createNumberProp({\n label: \"Volume\",\n description:\n \"The volume of the audio for this media. This value must be between 0.0 (silence) and 1.0 (maximum volume). (Default: .5)\",\n min: 0,\n max: 1,\n step: 0.1,\n precision: 1,\n group: GROUPS.basic,\n }),\n },\n};\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["index.
|
|
1
|
+
{"version":3,"sources":["index.js"],"names":["default","Checkbox","CheckboxGroup","CheckboxRow"],"mappings":"AAAA,SAASA,OAAO,IAAIC,QAApB,QAAoC,YAApC;AACA,SAASD,OAAO,IAAIE,aAApB,QAAyC,iBAAzC;AACA,SAASF,OAAO,IAAIG,WAApB,QAAuC,eAAvC","sourcesContent":["export { default as Checkbox } from \"./Checkbox\";\nexport { default as CheckboxGroup } from \"./CheckboxGroup\";\nexport { default as CheckboxRow } from \"./CheckboxRow\";\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["HeaderMedium.
|
|
1
|
+
{"version":3,"sources":["HeaderMedium.js"],"names":["GROUPS","COMPONENT_TYPES","FORM_TYPES","PROP_TYPES","SEED_DATA","name","tag","description","category","header","preview_image_url","supports_list_render","props","title","group","data","label","formType","string","propType","STRING","defaultValue","editable","required","buttonText","icon","basic","ASSET","onPress","action","layout"],"mappings":"AAAA,SAASA,MAAT,EAAiBC,eAAjB,EAAkCC,UAAlC,EAA8CC,UAA9C,QAAiE,iBAAjE;AACA,OAAO,MAAMC,SAAS,GAAG,CACrB;AACIC,EAAAA,IAAI,EAAE,eADV;AAEIC,EAAAA,GAAG,EAAE,cAFT;AAGIC,EAAAA,WAAW,EAAE,yEAHjB;AAIIC,EAAAA,QAAQ,EAAEP,eAAe,CAACQ,MAJ9B;AAKIC,EAAAA,iBAAiB,EAAE,oDALvB;AAMIC,EAAAA,oBAAoB,EAAE,KAN1B;AAOIC,EAAAA,KAAK,EAAE;AACHC,IAAAA,KAAK,EAAE;AACHC,MAAAA,KAAK,EAAEd,MAAM,CAACe,IADX;AAEHC,MAAAA,KAAK,EAAE,OAFJ;AAGHT,MAAAA,WAAW,EAAE,iBAHV;AAIHU,MAAAA,QAAQ,EAAEf,UAAU,CAACgB,MAJlB;AAKHC,MAAAA,QAAQ,EAAEhB,UAAU,CAACiB,MALlB;AAMHC,MAAAA,YAAY,EAAE,OANX;AAOHC,MAAAA,QAAQ,EAAE,IAPP;AAQHC,MAAAA,QAAQ,EAAE;AARP,KADJ;AAWHC,IAAAA,UAAU,EAAE;AACRV,MAAAA,KAAK,EAAEd,MAAM,CAACe,IADN;AAERC,MAAAA,KAAK,EAAE,aAFC;AAGRT,MAAAA,WAAW,EAAE,sCAHL;AAIRU,MAAAA,QAAQ,EAAEf,UAAU,CAACgB,MAJb;AAKRC,MAAAA,QAAQ,EAAEhB,UAAU,CAACiB,MALb;AAMRC,MAAAA,YAAY,EAAE,SANN;AAORC,MAAAA,QAAQ,EAAE,IAPF;AAQRC,MAAAA,QAAQ,EAAE;AARF,KAXT;AAqBHE,IAAAA,IAAI,EAAE;AACFX,MAAAA,KAAK,EAAEd,MAAM,CAAC0B,KADZ;AAEFV,MAAAA,KAAK,EAAE,MAFL;AAGFT,MAAAA,WAAW,EAAE,yBAHX;AAIFU,MAAAA,QAAQ,EAAEf,UAAU,CAACuB,IAJnB;AAKFN,MAAAA,QAAQ,EAAEhB,UAAU,CAACwB,KALnB;AAMFN,MAAAA,YAAY,EAAE,IANZ;AAOFC,MAAAA,QAAQ,EAAE,IAPR;AAQFC,MAAAA,QAAQ,EAAE;AARR,KArBH;AA+BHK,IAAAA,OAAO,EAAE;AACLd,MAAAA,KAAK,EAAEd,MAAM,CAAC0B,KADT;AAELV,MAAAA,KAAK,EAAE,QAFF;AAGLT,MAAAA,WAAW,EAAE,uCAHR;AAILe,MAAAA,QAAQ,EAAE,IAJL;AAKLC,MAAAA,QAAQ,EAAE,KALL;AAMLN,MAAAA,QAAQ,EAAEf,UAAU,CAAC2B,MANhB;AAOLV,MAAAA,QAAQ,EAAEhB,UAAU,CAACiB,MAPhB;AAQLC,MAAAA,YAAY,EAAE;AART;AA/BN,GAPX;AAiDIS,EAAAA,MAAM,EAAE;AAjDZ,CADqB,CAAlB","sourcesContent":["import { GROUPS, COMPONENT_TYPES, FORM_TYPES, PROP_TYPES, } from \"@draftbit/types\";\nexport const SEED_DATA = [\n {\n name: \"Header Medium\",\n tag: \"HeaderMedium\",\n description: \"A medium header with an optional touchable right aligned text and icon.\",\n category: COMPONENT_TYPES.header,\n preview_image_url: \"{CLOUDINARY_URL}/Header_HeadlineMediumIconText.png\",\n supports_list_render: false,\n props: {\n title: {\n group: GROUPS.data,\n label: \"Title\",\n description: \"Text to display\",\n formType: FORM_TYPES.string,\n propType: PROP_TYPES.STRING,\n defaultValue: \"Title\",\n editable: true,\n required: false,\n },\n buttonText: {\n group: GROUPS.data,\n label: \"Button text\",\n description: \"Right aligned button text to display\",\n formType: FORM_TYPES.string,\n propType: PROP_TYPES.STRING,\n defaultValue: \"See All\",\n editable: true,\n required: false,\n },\n icon: {\n group: GROUPS.basic,\n label: \"Icon\",\n description: \"Name of icon to display\",\n formType: FORM_TYPES.icon,\n propType: PROP_TYPES.ASSET,\n defaultValue: null,\n editable: true,\n required: false,\n },\n onPress: {\n group: GROUPS.basic,\n label: \"Action\",\n description: \"Action to execute when button pressed\",\n editable: true,\n required: false,\n formType: FORM_TYPES.action,\n propType: PROP_TYPES.STRING,\n defaultValue: null,\n },\n },\n layout: {},\n },\n];\n"]}
|
|
@@ -16,15 +16,15 @@ export const SEED_DATA = {
|
|
|
16
16
|
defaultValue: "http://static.draftbit.com/videos/intro-to-draftbit.mp4"
|
|
17
17
|
}),
|
|
18
18
|
usePoster: createStaticBoolProp({
|
|
19
|
-
label: "Thumbnail",
|
|
19
|
+
label: "Use Thumbnail",
|
|
20
20
|
description: "Show a thumbnail before the video starts.",
|
|
21
21
|
defaultValue: false
|
|
22
22
|
}),
|
|
23
23
|
posterSource: createSourceProp({
|
|
24
24
|
label: "Thumbnail Source",
|
|
25
25
|
description: "The optional image to display over the video while it is loading.",
|
|
26
|
-
defaultValue:
|
|
27
|
-
|
|
26
|
+
defaultValue: null,
|
|
27
|
+
required: false
|
|
28
28
|
}),
|
|
29
29
|
resizeMode: createResizeModeProp(),
|
|
30
30
|
isMuted: createStaticBoolProp({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["Video.ts"],"names":["COMPONENT_TYPES","createStaticBoolProp","createSourceProp","createResizeModeProp","createNumberProp","GROUPS","SEED_DATA","name","tag","description","doc_link","code_link","category","media","layout","height","props","source","label","defaultValue","usePoster","posterSource","
|
|
1
|
+
{"version":3,"sources":["Video.ts"],"names":["COMPONENT_TYPES","createStaticBoolProp","createSourceProp","createResizeModeProp","createNumberProp","GROUPS","SEED_DATA","name","tag","description","doc_link","code_link","category","media","layout","height","props","source","label","defaultValue","usePoster","posterSource","required","resizeMode","isMuted","useNativeControls","shouldPlay","isLooping","positionMillis","min","step","precision","group","basic","rate","max","volume"],"mappings":"AAAA,SACEA,eADF,EAEEC,oBAFF,EAGEC,gBAHF,EAIEC,oBAJF,EAKEC,gBALF,EAMEC,MANF,QAOO,iBAPP;AASA,OAAO,MAAMC,SAAS,GAAG;AACvBC,EAAAA,IAAI,EAAE,OADiB;AAEvBC,EAAAA,GAAG,EAAE,OAFkB;AAGvBC,EAAAA,WAAW,EAAE,8BAHU;AAIvBC,EAAAA,QAAQ,EAAE,iDAJa;AAKvBC,EAAAA,SAAS,EACP,yEANqB;AAOvBC,EAAAA,QAAQ,EAAEZ,eAAe,CAACa,KAPH;AAQvBC,EAAAA,MAAM,EAAE;AACNC,IAAAA,MAAM,EAAE;AADF,GARe;AAWvBC,EAAAA,KAAK,EAAE;AACLC,IAAAA,MAAM,EAAEf,gBAAgB,CAAC;AACvBgB,MAAAA,KAAK,EAAE,QADgB;AAEvBT,MAAAA,WAAW,EAAE,0CAFU;AAGvBU,MAAAA,YAAY,EAAE;AAHS,KAAD,CADnB;AAMLC,IAAAA,SAAS,EAAEnB,oBAAoB,CAAC;AAC9BiB,MAAAA,KAAK,EAAE,eADuB;AAE9BT,MAAAA,WAAW,EAAE,2CAFiB;AAG9BU,MAAAA,YAAY,EAAE;AAHgB,KAAD,CAN1B;AAWLE,IAAAA,YAAY,EAAEnB,gBAAgB,CAAC;AAC7BgB,MAAAA,KAAK,EAAE,kBADsB;AAE7BT,MAAAA,WAAW,EACT,mEAH2B;AAI7BU,MAAAA,YAAY,EAAE,IAJe;AAK7BG,MAAAA,QAAQ,EAAE;AALmB,KAAD,CAXz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AgB,CAAC;AACvBc,MAAAA,KAAK,EAAE,QADgB;AAEvBT,MAAAA,WAAW,EACT,0HAHqB;AAIvBoB,MAAAA,GAAG,EAAE,CAJkB;AAKvBM,MAAAA,GAAG,EAAE,CALkB;AAMvBL,MAAAA,IAAI,EAAE,GANiB;AAOvBC,MAAAA,SAAS,EAAE,CAPY;AAQvBC,MAAAA,KAAK,EAAE3B,MAAM,CAAC4B;AARS,KAAD;AAvDnB;AAXgB,CAAlB","sourcesContent":["import {\n COMPONENT_TYPES,\n createStaticBoolProp,\n createSourceProp,\n createResizeModeProp,\n createNumberProp,\n GROUPS,\n} from \"@draftbit/types\";\n\nexport const SEED_DATA = {\n name: \"Video\",\n tag: \"Video\",\n description: \"Given a URL, display a video\",\n doc_link: \"https://docs.expo.io/versions/latest/sdk/video/\",\n code_link:\n \"https://github.com/expo/expo/blob/master/packages/expo-av/src/Video.tsx\",\n category: COMPONENT_TYPES.media,\n layout: {\n height: 215,\n },\n props: {\n source: createSourceProp({\n label: \"Source\",\n description: \"The source of the video data to display.\",\n defaultValue: \"http://static.draftbit.com/videos/intro-to-draftbit.mp4\",\n }),\n usePoster: createStaticBoolProp({\n label: \"Use Thumbnail\",\n description: \"Show a thumbnail before the video starts.\",\n defaultValue: false,\n }),\n posterSource: createSourceProp({\n label: \"Thumbnail Source\",\n description:\n \"The optional image to display over the video while it is loading.\",\n defaultValue: null,\n required: false,\n }),\n resizeMode: createResizeModeProp(),\n isMuted: createStaticBoolProp({\n label: \"Mute Audio\",\n description: \"Mute the audio of the video.\",\n }),\n useNativeControls: createStaticBoolProp({\n label: \"Use Native Controls\",\n description:\n \"Display the playback controls, allowing users to play or pause the video.\",\n defaultValue: true,\n }),\n shouldPlay: createStaticBoolProp({\n label: \"Play Automatically\",\n description: \"Start playing the video after loading is finished.\",\n }),\n isLooping: createStaticBoolProp({\n label: \"Loop Video\",\n description: \"Automatically replay the video.\",\n }),\n positionMillis: createNumberProp({\n label: \"Starting Point\",\n description: \"Set a certian starting point of the video\",\n min: 0,\n step: 0.01,\n precision: 2,\n group: GROUPS.basic,\n }),\n rate: createNumberProp({\n label: \"Playback Rate\",\n description:\n \"The playback rate of the media. This value must be between 0.0 and 32.0 (Default: 1)\",\n min: 0,\n max: 32,\n step: 0.25,\n precision: 2,\n group: GROUPS.basic,\n }),\n volume: createNumberProp({\n label: \"Volume\",\n description:\n \"The volume of the audio for this media. This value must be between 0.0 (silence) and 1.0 (maximum volume). (Default: .5)\",\n min: 0,\n max: 1,\n step: 0.1,\n precision: 1,\n group: GROUPS.basic,\n }),\n },\n};\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@draftbit/core",
|
|
3
|
-
"version": "43.6.
|
|
3
|
+
"version": "43.6.2-62239f.0+62239f49",
|
|
4
4
|
"description": "Core (non-native) Components",
|
|
5
5
|
"main": "lib/commonjs/index.js",
|
|
6
6
|
"module": "lib/module/index.js",
|
|
@@ -80,5 +80,5 @@
|
|
|
80
80
|
]
|
|
81
81
|
]
|
|
82
82
|
},
|
|
83
|
-
"gitHead": "
|
|
83
|
+
"gitHead": "62239f4978ee31aa79fe799918ad7c82d5af5445"
|
|
84
84
|
}
|
package/src/mappings/Video.js
CHANGED
|
@@ -16,15 +16,15 @@ export const SEED_DATA = {
|
|
|
16
16
|
defaultValue: "http://static.draftbit.com/videos/intro-to-draftbit.mp4",
|
|
17
17
|
}),
|
|
18
18
|
usePoster: createStaticBoolProp({
|
|
19
|
-
label: "Thumbnail",
|
|
19
|
+
label: "Use Thumbnail",
|
|
20
20
|
description: "Show a thumbnail before the video starts.",
|
|
21
21
|
defaultValue: false,
|
|
22
22
|
}),
|
|
23
23
|
posterSource: createSourceProp({
|
|
24
24
|
label: "Thumbnail Source",
|
|
25
25
|
description: "The optional image to display over the video while it is loading.",
|
|
26
|
-
defaultValue:
|
|
27
|
-
|
|
26
|
+
defaultValue: null,
|
|
27
|
+
required: false,
|
|
28
28
|
}),
|
|
29
29
|
resizeMode: createResizeModeProp(),
|
|
30
30
|
isMuted: createStaticBoolProp({
|
package/src/mappings/Video.ts
CHANGED
|
@@ -25,7 +25,7 @@ export const SEED_DATA = {
|
|
|
25
25
|
defaultValue: "http://static.draftbit.com/videos/intro-to-draftbit.mp4",
|
|
26
26
|
}),
|
|
27
27
|
usePoster: createStaticBoolProp({
|
|
28
|
-
label: "Thumbnail",
|
|
28
|
+
label: "Use Thumbnail",
|
|
29
29
|
description: "Show a thumbnail before the video starts.",
|
|
30
30
|
defaultValue: false,
|
|
31
31
|
}),
|
|
@@ -33,8 +33,8 @@ export const SEED_DATA = {
|
|
|
33
33
|
label: "Thumbnail Source",
|
|
34
34
|
description:
|
|
35
35
|
"The optional image to display over the video while it is loading.",
|
|
36
|
-
defaultValue:
|
|
37
|
-
|
|
36
|
+
defaultValue: null,
|
|
37
|
+
required: false,
|
|
38
38
|
}),
|
|
39
39
|
resizeMode: createResizeModeProp(),
|
|
40
40
|
isMuted: createStaticBoolProp({
|