@draftbit/core 43.4.2-80bace.1 → 43.4.3-6076c5.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.
Files changed (30) hide show
  1. package/lib/commonjs/components/FieldSearchBarFull.js.map +1 -1
  2. package/lib/commonjs/index.js +0 -8
  3. package/lib/commonjs/index.js.map +1 -1
  4. package/lib/commonjs/mappings/LinearGradient.js +63 -11
  5. package/lib/commonjs/mappings/LinearGradient.js.map +1 -1
  6. package/lib/commonjs/mappings/RowHeadlineImageCaption.js.map +1 -1
  7. package/lib/commonjs/mappings/RowHeadlineImageIcon.js.map +1 -1
  8. package/lib/module/components/FieldSearchBarFull.js.map +1 -1
  9. package/lib/module/components/RowBodyIcon.js.map +1 -1
  10. package/lib/module/index.js +0 -1
  11. package/lib/module/index.js.map +1 -1
  12. package/lib/module/mappings/BlurView.js.map +1 -1
  13. package/lib/module/mappings/FieldSearchBarFull.js +1 -1
  14. package/lib/module/mappings/FieldSearchBarFull.js.map +1 -1
  15. package/lib/module/mappings/LinearGradient.js +64 -12
  16. package/lib/module/mappings/LinearGradient.js.map +1 -1
  17. package/lib/typescript/src/index.d.ts +0 -1
  18. package/lib/typescript/src/mappings/LinearGradient.d.ts +79 -6
  19. package/package.json +2 -2
  20. package/src/index.js +0 -1
  21. package/src/index.tsx +0 -1
  22. package/src/mappings/LinearGradient.js +64 -12
  23. package/src/mappings/LinearGradient.ts +69 -13
  24. package/lib/commonjs/components/LinearGradient.js +0 -127
  25. package/lib/commonjs/components/LinearGradient.js.map +0 -1
  26. package/lib/module/components/LinearGradient.js +0 -111
  27. package/lib/module/components/LinearGradient.js.map +0 -1
  28. package/lib/typescript/src/components/LinearGradient.d.ts +0 -108
  29. package/src/components/LinearGradient.js +0 -84
  30. package/src/components/LinearGradient.tsx +0 -119
@@ -1,108 +0,0 @@
1
- import * as React from "react";
2
- import { StyleProp, ViewStyle } from "react-native";
3
- declare type LinearGradientComponentProps = {
4
- color1: string;
5
- color2: string;
6
- color3?: string;
7
- startX: number;
8
- startY: number;
9
- endX: number;
10
- endY: number;
11
- children?: React.ReactNode;
12
- style?: StyleProp<ViewStyle>;
13
- };
14
- declare const LinearGradientComponent: ({ children, color1, color2, color3, startX, startY, endX, endY, style, }: LinearGradientComponentProps) => JSX.Element;
15
- export default LinearGradientComponent;
16
- export declare const SEED_DATA: {
17
- name: string;
18
- tag: string;
19
- description: string;
20
- props: {
21
- color1: {
22
- group: string;
23
- label: string;
24
- description: string;
25
- editable: boolean;
26
- required: boolean;
27
- defaultValue: null;
28
- formType: string;
29
- propType: string;
30
- };
31
- color2: {
32
- group: string;
33
- label: string;
34
- description: string;
35
- editable: boolean;
36
- required: boolean;
37
- defaultValue: null;
38
- formType: string;
39
- propType: string;
40
- };
41
- color3: {
42
- group: string;
43
- label: string;
44
- description: string;
45
- editable: boolean;
46
- required: boolean;
47
- defaultValue: null;
48
- formType: string;
49
- propType: string;
50
- };
51
- startX: {
52
- group: string;
53
- label: string;
54
- description: string;
55
- editable: boolean;
56
- required: boolean;
57
- defaultValue: number;
58
- min: number;
59
- max: number;
60
- step: number;
61
- precision: number;
62
- formType: string;
63
- propType: string;
64
- };
65
- startY: {
66
- group: string;
67
- label: string;
68
- description: string;
69
- editable: boolean;
70
- required: boolean;
71
- defaultValue: number;
72
- min: number;
73
- max: number;
74
- step: number;
75
- precision: number;
76
- formType: string;
77
- propType: string;
78
- };
79
- endX: {
80
- group: string;
81
- label: string;
82
- description: string;
83
- editable: boolean;
84
- required: boolean;
85
- defaultValue: number;
86
- min: number;
87
- max: number;
88
- step: number;
89
- precision: number;
90
- formType: string;
91
- propType: string;
92
- };
93
- endY: {
94
- group: string;
95
- label: string;
96
- description: string;
97
- editable: boolean;
98
- required: boolean;
99
- defaultValue: number;
100
- min: number;
101
- max: number;
102
- step: number;
103
- precision: number;
104
- formType: string;
105
- propType: string;
106
- };
107
- };
108
- };
@@ -1,84 +0,0 @@
1
- import * as React from "react";
2
- import { LinearGradient } from "expo-linear-gradient";
3
- import { extractStyles } from "../utilities";
4
- import { createColorProp, FORM_TYPES, GROUPS, PROP_TYPES, } from "@draftbit/types";
5
- const LinearGradientComponent = ({ children, color1, color2, color3 = undefined, startX = 0, startY = 0, endX = 100, endY = 0, style, }) => {
6
- const { viewStyles } = extractStyles(style);
7
- const colors = [color1, color2, color3].filter((color) => color);
8
- const start = { x: startX / 100, y: startY / 100 };
9
- const end = { x: endX / 100, y: endY / 100 };
10
- return (React.createElement(LinearGradient, { colors: colors, start: start, end: end, style: viewStyles }, children));
11
- };
12
- export default LinearGradientComponent;
13
- export const SEED_DATA = {
14
- name: "LinearGradient",
15
- tag: "LinearGradient",
16
- description: "Linear Gradient Component",
17
- props: {
18
- color1: createColorProp({
19
- label: "Color 1",
20
- }),
21
- color2: createColorProp({
22
- label: "Color 2",
23
- }),
24
- color3: createColorProp({
25
- label: "Color 3",
26
- }),
27
- startX: {
28
- group: GROUPS.basic,
29
- label: "Start X",
30
- description: "Start position from Left",
31
- editable: true,
32
- required: false,
33
- defaultValue: 0,
34
- min: 0,
35
- max: 100,
36
- step: 1,
37
- precision: 0,
38
- formType: FORM_TYPES.number,
39
- propType: PROP_TYPES.NUMBER,
40
- },
41
- startY: {
42
- group: GROUPS.basic,
43
- label: "Start Y",
44
- description: "Start position from Top",
45
- editable: true,
46
- required: false,
47
- defaultValue: 0,
48
- min: 0,
49
- max: 100,
50
- step: 1,
51
- precision: 0,
52
- formType: FORM_TYPES.number,
53
- propType: PROP_TYPES.NUMBER,
54
- },
55
- endX: {
56
- group: GROUPS.basic,
57
- label: "End Y",
58
- description: "End position from Right",
59
- editable: true,
60
- required: false,
61
- defaultValue: 100,
62
- min: 0,
63
- max: 100,
64
- step: 1,
65
- precision: 0,
66
- formType: FORM_TYPES.number,
67
- propType: PROP_TYPES.NUMBER,
68
- },
69
- endY: {
70
- group: GROUPS.basic,
71
- label: "End Y",
72
- description: "End position from Bottom",
73
- editable: true,
74
- required: false,
75
- defaultValue: 100,
76
- min: 0,
77
- max: 100,
78
- step: 1,
79
- precision: 0,
80
- formType: FORM_TYPES.number,
81
- propType: PROP_TYPES.NUMBER,
82
- },
83
- },
84
- };
@@ -1,119 +0,0 @@
1
- import * as React from "react";
2
- import { StyleProp, ViewStyle } from "react-native";
3
- import { LinearGradient } from "expo-linear-gradient";
4
- import { extractStyles } from "../utilities";
5
- import {
6
- createColorProp,
7
- FORM_TYPES,
8
- GROUPS,
9
- PROP_TYPES,
10
- } from "@draftbit/types";
11
-
12
- type LinearGradientComponentProps = {
13
- color1: string;
14
- color2: string;
15
- color3?: string;
16
- startX: number;
17
- startY: number;
18
- endX: number;
19
- endY: number;
20
- children?: React.ReactNode;
21
- style?: StyleProp<ViewStyle>;
22
- };
23
-
24
- const LinearGradientComponent = ({
25
- children,
26
- color1,
27
- color2,
28
- color3 = undefined,
29
- startX = 0,
30
- startY = 0,
31
- endX = 100,
32
- endY = 0,
33
- style,
34
- }: LinearGradientComponentProps) => {
35
- const { viewStyles } = extractStyles(style);
36
- const colors = [color1, color2, color3].filter((color) => color) as string[];
37
- const start = { x: startX / 100, y: startY / 100 };
38
- const end = { x: endX / 100, y: endY / 100 };
39
- return (
40
- <LinearGradient colors={colors} start={start} end={end} style={viewStyles}>
41
- {children}
42
- </LinearGradient>
43
- );
44
- };
45
-
46
- export default LinearGradientComponent;
47
-
48
- export const SEED_DATA = {
49
- name: "LinearGradient",
50
- tag: "LinearGradient",
51
- description: "Linear Gradient Component",
52
- props: {
53
- color1: createColorProp({
54
- label: "Color 1",
55
- }),
56
- color2: createColorProp({
57
- label: "Color 2",
58
- }),
59
- color3: createColorProp({
60
- label: "Color 3",
61
- }),
62
- startX: {
63
- group: GROUPS.basic,
64
- label: "Start X",
65
- description: "Start position from Left",
66
- editable: true,
67
- required: false,
68
- defaultValue: 0,
69
- min: 0,
70
- max: 100,
71
- step: 1,
72
- precision: 0,
73
- formType: FORM_TYPES.number,
74
- propType: PROP_TYPES.NUMBER,
75
- },
76
- startY: {
77
- group: GROUPS.basic,
78
- label: "Start Y",
79
- description: "Start position from Top",
80
- editable: true,
81
- required: false,
82
- defaultValue: 0,
83
- min: 0,
84
- max: 100,
85
- step: 1,
86
- precision: 0,
87
- formType: FORM_TYPES.number,
88
- propType: PROP_TYPES.NUMBER,
89
- },
90
- endX: {
91
- group: GROUPS.basic,
92
- label: "End Y",
93
- description: "End position from Right",
94
- editable: true,
95
- required: false,
96
- defaultValue: 100,
97
- min: 0,
98
- max: 100,
99
- step: 1,
100
- precision: 0,
101
- formType: FORM_TYPES.number,
102
- propType: PROP_TYPES.NUMBER,
103
- },
104
- endY: {
105
- group: GROUPS.basic,
106
- label: "End Y",
107
- description: "End position from Bottom",
108
- editable: true,
109
- required: false,
110
- defaultValue: 100,
111
- min: 0,
112
- max: 100,
113
- step: 1,
114
- precision: 0,
115
- formType: FORM_TYPES.number,
116
- propType: PROP_TYPES.NUMBER,
117
- },
118
- },
119
- };