@flozy/editor 3.3.6 → 3.3.7

Sign up to get free protection for your applications and to get access to all the features.
@@ -26,13 +26,13 @@ const Form = props => {
26
26
  readOnly,
27
27
  site_id,
28
28
  page_id,
29
- page_title,
30
29
  onFormSubmit
31
30
  } = customProps;
32
31
  const {
33
32
  buttonProps,
34
33
  textColor,
35
34
  formName,
35
+ uid,
36
36
  borderWidth,
37
37
  borderColor,
38
38
  borderStyle,
@@ -132,14 +132,14 @@ const Form = props => {
132
132
  response?.push({
133
133
  [pair[0]]: pair[1],
134
134
  placeholder: placeholder,
135
- from_name: formName,
136
- page_title: page_title
135
+ form_name: formName
137
136
  });
138
137
  }
139
138
  let params = {
140
139
  page_id: page_id,
141
140
  site_id: site_id,
142
141
  form_id: `${formName}`,
142
+ uid: `${page_id}_${uid ? uid : formName}`,
143
143
  response: response,
144
144
  form_data: {
145
145
  user_email: user_email,
@@ -115,7 +115,7 @@ const ELEMENTS_LIST = [{
115
115
  icon: /*#__PURE__*/_jsx(Icon, {
116
116
  icon: "embed"
117
117
  }),
118
- onInsert: editor => insertDefaultEmbed(editor, "video", "")
118
+ onInsert: editor => insertDefaultEmbed(editor, "embed", "")
119
119
  }, {
120
120
  name: "Calendly",
121
121
  desc: "",
@@ -9,7 +9,7 @@ export const formSubmit = async (formData, props) => {
9
9
  body: JSON.stringify(formData)
10
10
  });
11
11
  const result = await response.json();
12
- return result?.data?.data;
12
+ return result?.data;
13
13
  } catch (err) {
14
14
  console.log(err);
15
15
  return err;
@@ -390,6 +390,10 @@ export const getBlock = props => {
390
390
  return /*#__PURE__*/_jsx(Video, {
391
391
  ...props
392
392
  });
393
+ case "embed":
394
+ return /*#__PURE__*/_jsx(Video, {
395
+ ...props
396
+ });
393
397
  case "calendly":
394
398
  return /*#__PURE__*/_jsx(Video, {
395
399
  ...props
@@ -6,6 +6,7 @@ export const insertForm = (editor, item) => {
6
6
  type: "form",
7
7
  grid: "container",
8
8
  formName: `form_${new Date().getTime()}`,
9
+ uid: `form_${new Date().getTime()}`,
9
10
  props: {
10
11
  onSubmit: null
11
12
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@flozy/editor",
3
- "version": "3.3.6",
3
+ "version": "3.3.7",
4
4
  "description": "An Editor for flozy app brain",
5
5
  "files": [
6
6
  "dist"