@@ -364,9 +398,15 @@ function PlaceholderType(props) {
type="text"
ref={inputRef}
placeholder={"company"}
- value={props.pos.widgetValue && props.pos.widgetValue}
+ style={{ fontSize: calculateFontSize() }}
+ value={
+ textValue
+ ? textValue
+ : props.pos.widgetValue && props.pos.widgetValue
+ }
onBlur={handleInputBlur}
- onChange={(e) =>
+ onChange={(e) => {
+ handleTextValid(e, /[^a-zA-Z\s]/g);
onChangeInput(
e.target.value,
props.pos.key,
@@ -375,14 +415,14 @@ function PlaceholderType(props) {
props.setXyPostion,
props.data && props.data?.Id,
false
- )
- }
+ );
+ }}
/>
) : (
{props.pos.type}
@@ -397,9 +437,15 @@ function PlaceholderType(props) {
type="text"
ref={inputRef}
placeholder={"job title"}
- value={props.pos.widgetValue && props.pos.widgetValue}
+ style={{ fontSize: calculateFontSize() }}
+ value={
+ textValue
+ ? textValue
+ : props.pos.widgetValue && props.pos.widgetValue
+ }
onBlur={handleInputBlur}
- onChange={(e) =>
+ onChange={(e) => {
+ handleTextValid(e, /[^a-zA-Z\s]/g);
onChangeInput(
e.target.value,
props.pos.key,
@@ -408,14 +454,14 @@ function PlaceholderType(props) {
props.setXyPostion,
props.data && props.data?.Id,
false
- )
- }
+ );
+ }}
/>
) : (
{props.pos.type}
@@ -452,7 +498,6 @@ function PlaceholderType(props) {
: "dd MMMM, YYYY"
}
/>
- {/*
{props.selectDate}
*/}
);
@@ -489,9 +534,15 @@ function PlaceholderType(props) {
type="text"
ref={inputRef}
placeholder={"email"}
- value={props.pos.widgetValue && props.pos.widgetValue}
+ style={{ fontSize: calculateFontSize() }}
+ value={
+ textValue
+ ? textValue
+ : props.pos.widgetValue && props.pos.widgetValue
+ }
onBlur={handleInputBlur}
- onChange={(e) =>
+ onChange={(e) => {
+ handleTextValid(e, /^[a-zA-Z0-9._-]+@[a-zA-Z0-9.-]+.[a-zA-Z]{2,}$/);
onChangeInput(
e.target.value,
props.pos.key,
@@ -500,14 +551,14 @@ function PlaceholderType(props) {
props.setXyPostion,
props.data && props.data?.Id,
false
- )
- }
+ );
+ }}
/>
) : (
{props.pos.type}
diff --git a/microfrontends/SignDocuments/src/Component/component/PlaceholderCopy.js b/microfrontends/SignDocuments/src/Component/component/PlaceholderCopy.js
index 3a9049ade..d952ea0a6 100644
--- a/microfrontends/SignDocuments/src/Component/component/PlaceholderCopy.js
+++ b/microfrontends/SignDocuments/src/Component/component/PlaceholderCopy.js
@@ -66,6 +66,7 @@ function PlaceholderCopy(props) {
let newPageNumber = 1;
const signerPosition = props.xyPostion;
const signerId = props.signerObjId ? props.signerObjId : props.Id;
+
//handle placeholder array and copy for multiple signers placeholder at requested location
if (signerId) {
//get current signers data
diff --git a/microfrontends/SignDocuments/src/Component/component/fieldsComponent.js b/microfrontends/SignDocuments/src/Component/component/fieldsComponent.js
index e8fc48f03..da91713b2 100644
--- a/microfrontends/SignDocuments/src/Component/component/fieldsComponent.js
+++ b/microfrontends/SignDocuments/src/Component/component/fieldsComponent.js
@@ -21,7 +21,6 @@ function FieldsComponent({
setContractName,
isSigners,
dataTut,
- dataTut2,
isMailSend,
handleAddSigner,
setUniqueId,
@@ -31,7 +30,8 @@ function FieldsComponent({
handleRoleChange,
handleOnBlur,
title,
- isdraggingEnable
+ isdraggingEnable,
+ isTemplateFlow
}) {
const [isSignersModal, setIsSignersModal] = useState(false);
@@ -230,7 +230,12 @@ function FieldsComponent({
(data) =>
data.type !== "dropdown" && data.type !== "radio" && data.type !== "label"
);
- const updateWidgets = isSignYourself ? filterWidgets : widget;
+ const labelWidget = widget.filter((data) => data.type !== "label");
+ const updateWidgets = isSignYourself
+ ? filterWidgets
+ : isTemplateFlow
+ ? labelWidget
+ : widget;
return (
<>
diff --git a/microfrontends/SignDocuments/src/Component/placeHolderSign.js b/microfrontends/SignDocuments/src/Component/placeHolderSign.js
index 284902836..b7c83aa10 100644
--- a/microfrontends/SignDocuments/src/Component/placeHolderSign.js
+++ b/microfrontends/SignDocuments/src/Component/placeHolderSign.js
@@ -36,6 +36,7 @@ import Title from "./component/Title";
import TourContentWithBtn from "../premitives/TourContentWithBtn";
import ModalUi from "../premitives/ModalUi";
import DropdownWidgetOption from "../Component/WidgetComponent/dropdownWidgetOption";
+import InputValidation from "./WidgetComponent/inputValidation";
function PlaceHolderSign() {
const navigate = useNavigate();
@@ -1176,6 +1177,7 @@ function PlaceHolderSign() {
//function for base on condition to add checkbox widget status and input text validation in signerPos array
const handleApplyWidgetsStatus = (textValidate) => {
let regularExpression = textValidate;
+
const filterSignerPos = signerPos.filter((data) => data.Id === uniqueId);
if (filterSignerPos.length > 0) {
const getPlaceHolder = filterSignerPos[0].placeHolder;
@@ -1228,25 +1230,14 @@ function PlaceHolderSign() {
setSignerPos(newUpdateSigner);
setIsCheckboxRequired(false);
-
+ setTextValidate("");
setSelectRequiredType("Optional");
}
}
};
const handleValidateInput = (e) => {
- if (
- textValidate === "email" ||
- textValidate === "number" ||
- textValidate === "text"
- ) {
- handleApplyWidgetsStatus(textValidate);
- setIsValidate(false);
- } else {
- setValidateError("please enter accurate validation.");
- setTimeout(() => {
- setValidateError("");
- }, 1500);
- }
+ handleApplyWidgetsStatus(textValidate);
+ setIsValidate(false);
};
return (
@@ -1523,63 +1514,13 @@ function PlaceHolderSign() {
-
{
- setIsValidate(false);
- }}
- title={"Validation"}
- >
-
-
-
-
-
setTextValidate(e.target.value)}
- />
- {validateError && (
-
- {validateError}
-
- )}
-
-
-
-
-
-
-
+
{
return obj;
case "date":
obj = {
- width: 120,
+ width: 100,
height: 20
};
return obj;
@@ -939,6 +939,7 @@ export const multiSignEmbed = async (
imgData.type === "initials" ||
imgData.type === "image"
) {
+ console.log(images[id]);
if (
(imgData.ImageType && imgData.ImageType === "image/png") ||
imgData.ImageType === "image/jpeg"