@bigbinary/neeto-molecules 1.1.14 → 1.1.15

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.
@@ -9,7 +9,8 @@ import EmailBody from "./EmailBodyEditor";
9
9
  import FormikDatePicker from "./FormikDatePicker";
10
10
  import { isPastDate } from "./utils";
11
11
  var Form = function Form(_ref) {
12
- var disableReplyTo = _ref.disableReplyTo,
12
+ var isSendFromDisabled = _ref.isSendFromDisabled,
13
+ disableReplyTo = _ref.disableReplyTo,
13
14
  showVideoEmbedInEditor = _ref.showVideoEmbedInEditor,
14
15
  children = _ref.children;
15
16
  var _useFormikContext = useFormikContext(),
@@ -73,6 +74,8 @@ var Form = function Form(_ref) {
73
74
  }, /*#__PURE__*/React.createElement(Input, {
74
75
  required: true,
75
76
  className: "col-auto",
77
+ "data-testid": "neeto-molecules-share-via-email-send-from",
78
+ disabled: isSendFromDisabled,
76
79
  label: t("neetoMolecules.shareViaEmail.sendFrom"),
77
80
  name: "sendFromEmail"
78
81
  }), !disableReplyTo && /*#__PURE__*/React.createElement(Input, {
@@ -7,7 +7,9 @@ import EmailPreview from "../EmailPreview";
7
7
  import EmailForm from "./Form";
8
8
  import { emailFormValidationSchema, generateInitialValues } from "./utils";
9
9
  var ShareViaEmail = function ShareViaEmail(_ref) {
10
- var backToUrl = _ref.backToUrl,
10
+ var _ref$isSendFromDisabl = _ref.isSendFromDisabled,
11
+ isSendFromDisabled = _ref$isSendFromDisabl === void 0 ? true : _ref$isSendFromDisabl,
12
+ backToUrl = _ref.backToUrl,
11
13
  handleSubmit = _ref.handleSubmit,
12
14
  children = _ref.children,
13
15
  description = _ref.description,
@@ -71,6 +73,7 @@ var ShareViaEmail = function ShareViaEmail(_ref) {
71
73
  style: "body2"
72
74
  }, description)), /*#__PURE__*/React.createElement(EmailForm, {
73
75
  disableReplyTo: disableReplyTo,
76
+ isSendFromDisabled: isSendFromDisabled,
74
77
  showVideoEmbedInEditor: showVideoEmbedInEditor
75
78
  }, children)), /*#__PURE__*/React.createElement("div", {
76
79
  className: "col-span-7"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bigbinary/neeto-molecules",
3
- "version": "1.1.14",
3
+ "version": "1.1.15",
4
4
  "description": "A package of reusable molecular components for neeto products.",
5
5
  "repository": "git@github.com:bigbinary/neeto-molecules.git",
6
6
  "author": "Amaljith K <amaljith.k@bigbinary.com>",
@@ -70,6 +70,7 @@ const ShareViaEmail: React.FC<{
70
70
  children?: React.ReactNode;
71
71
  description?: string;
72
72
  disableReplyTo?: boolean;
73
+ isSendFromDisabled?: boolean;
73
74
  productName?: string;
74
75
  defaultValues?: {
75
76
  sendFromEmail?: string;