mirror of
https://github.com/OpenSignLabs/OpenSign.git
synced 2026-08-24 08:32:34 +02:00
fix: input text width
This commit is contained in:
@@ -135,7 +135,7 @@ function PlaceholderType(props) {
|
||||
}
|
||||
}
|
||||
// eslint-disable-next-line react-hooks/exhaustive-deps
|
||||
}, [props.pos]);
|
||||
}, [props.pos?.options?.defaultValue]);
|
||||
|
||||
const ExampleCustomInput = forwardRef(({ value, onClick }, ref) => (
|
||||
<div
|
||||
@@ -403,33 +403,6 @@ function PlaceholderType(props) {
|
||||
case textInputWidget:
|
||||
return props.isSignYourself ||
|
||||
(props.isNeedSign && props.data?.signerObjId === props.signerObjId) ? (
|
||||
// <input
|
||||
// className="inputPlaceholder"
|
||||
// ref={inputRef}
|
||||
// placeholder={validatePlaceholder}
|
||||
// style={{ fontSize: calculateFontSize() }}
|
||||
// value={textValue}
|
||||
// type="text"
|
||||
// tabIndex="0"
|
||||
// disabled={
|
||||
// props.isNeedSign && props.data?.signerObjId !== props.signerObjId
|
||||
// ? true
|
||||
// : props.isPlaceholder
|
||||
// }
|
||||
// onBlur={handleInputBlur}
|
||||
// onChange={(e) => {
|
||||
// setTextValue(e.target.value);
|
||||
// onChangeInput(
|
||||
// e.target.value,
|
||||
// props.pos.key,
|
||||
// props.xyPostion,
|
||||
// props.index,
|
||||
// props.setXyPostion,
|
||||
// props.data && props.data?.Id,
|
||||
// false
|
||||
// );
|
||||
// }}
|
||||
// />
|
||||
<textarea
|
||||
ref={inputRef}
|
||||
placeholder={validatePlaceholder}
|
||||
@@ -533,29 +506,6 @@ function PlaceholderType(props) {
|
||||
case "name":
|
||||
return props.isSignYourself ||
|
||||
(props.isNeedSign && props.data?.signerObjId === props.signerObjId) ? (
|
||||
// <input
|
||||
// tabIndex="0"
|
||||
// ref={inputRef}
|
||||
// placeholder={"name"}
|
||||
// style={{ fontSize: calculateFontSize() }}
|
||||
// className="inputPlaceholder"
|
||||
// type="text"
|
||||
// value={textValue}
|
||||
// onBlur={handleInputBlur}
|
||||
// onChange={(e) => {
|
||||
// const isDefault = false;
|
||||
// handleTextValid(e);
|
||||
// onChangeInput(
|
||||
// e.target.value,
|
||||
// props.pos.key,
|
||||
// props.xyPostion,
|
||||
// props.index,
|
||||
// props.setXyPostion,
|
||||
// props.data && props.data?.Id,
|
||||
// isDefault
|
||||
// );
|
||||
// }}
|
||||
// />
|
||||
<textarea
|
||||
ref={inputRef}
|
||||
placeholder={"name"}
|
||||
@@ -597,27 +547,6 @@ function PlaceholderType(props) {
|
||||
case "company":
|
||||
return props.isSignYourself ||
|
||||
(props.isNeedSign && props.data?.signerObjId === props.signerObjId) ? (
|
||||
// <input
|
||||
// className="inputPlaceholder"
|
||||
// type="text"
|
||||
// ref={inputRef}
|
||||
// placeholder={"company"}
|
||||
// style={{ fontSize: calculateFontSize() }}
|
||||
// value={textValue}
|
||||
// onBlur={handleInputBlur}
|
||||
// onChange={(e) => {
|
||||
// handleTextValid(e);
|
||||
// onChangeInput(
|
||||
// e.target.value,
|
||||
// props.pos.key,
|
||||
// props.xyPostion,
|
||||
// props.index,
|
||||
// props.setXyPostion,
|
||||
// props.data && props.data?.Id,
|
||||
// false
|
||||
// );
|
||||
// }}
|
||||
// />
|
||||
<textarea
|
||||
ref={inputRef}
|
||||
placeholder="Enter label"
|
||||
@@ -658,27 +587,6 @@ function PlaceholderType(props) {
|
||||
case "job title":
|
||||
return props.isSignYourself ||
|
||||
(props.isNeedSign && props.data?.signerObjId === props.signerObjId) ? (
|
||||
// <input
|
||||
// className="inputPlaceholder"
|
||||
// type="text"
|
||||
// ref={inputRef}
|
||||
// placeholder={"job title"}
|
||||
// style={{ fontSize: calculateFontSize() }}
|
||||
// value={textValue}
|
||||
// onBlur={handleInputBlur}
|
||||
// onChange={(e) => {
|
||||
// handleTextValid(e);
|
||||
// onChangeInput(
|
||||
// e.target.value,
|
||||
// props.pos.key,
|
||||
// props.xyPostion,
|
||||
// props.index,
|
||||
// props.setXyPostion,
|
||||
// props.data && props.data?.Id,
|
||||
// false
|
||||
// );
|
||||
// }}
|
||||
// />
|
||||
<textarea
|
||||
ref={inputRef}
|
||||
placeholder={"job title"}
|
||||
@@ -801,27 +709,6 @@ function PlaceholderType(props) {
|
||||
case "email":
|
||||
return props.isSignYourself ||
|
||||
(props.isNeedSign && props.data?.signerObjId === props.signerObjId) ? (
|
||||
// <input
|
||||
// className="inputPlaceholder"
|
||||
// type="text"
|
||||
// ref={inputRef}
|
||||
// placeholder={"email"}
|
||||
// style={{ fontSize: calculateFontSize() }}
|
||||
// value={textValue}
|
||||
// onBlur={handleInputBlur}
|
||||
// onChange={(e) => {
|
||||
// handleTextValid(e);
|
||||
// onChangeInput(
|
||||
// e.target.value,
|
||||
// props.pos.key,
|
||||
// props.xyPostion,
|
||||
// props.index,
|
||||
// props.setXyPostion,
|
||||
// props.data && props.data?.Id,
|
||||
// false
|
||||
// );
|
||||
// }}
|
||||
// />
|
||||
<textarea
|
||||
ref={inputRef}
|
||||
placeholder={"email"}
|
||||
|
||||
@@ -1383,25 +1383,7 @@ export const multiSignEmbed = async (
|
||||
});
|
||||
y -= 18; // Adjust the line height as needed
|
||||
}
|
||||
}
|
||||
// else if (widgetTypeExist) {
|
||||
// const font = await pdfDoc.embedFont("Helvetica");
|
||||
// const fontSize = 12;
|
||||
// let textContent;
|
||||
// if (position?.options?.response) {
|
||||
// textContent = position.options?.response;
|
||||
// } else if (position?.options?.defaultValue) {
|
||||
// textContent = position?.options?.defaultValue;
|
||||
// }
|
||||
// page.drawText(textContent, {
|
||||
// x: xPos(position),
|
||||
// y: yPos(position) + 10,
|
||||
// size: fontSize,
|
||||
// font,
|
||||
// color: rgb(0, 0, 0)
|
||||
// });
|
||||
// }
|
||||
else if (position.type === "dropdown") {
|
||||
} else if (position.type === "dropdown") {
|
||||
const dropdownRandomId = "dropdown" + randomId();
|
||||
const dropdown = form.createDropdown(dropdownRandomId);
|
||||
dropdown.addOptions(position?.options?.values);
|
||||
|
||||
@@ -496,11 +496,15 @@
|
||||
overflow: hidden !important;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.disabled {
|
||||
opacity: 0.5; /* Example: reduce opacity to visually indicate disabled state */
|
||||
pointer-events: none; /* Prevents mouse clicks and other events */
|
||||
opacity: 0.5;
|
||||
/* Example: reduce opacity to visually indicate disabled state */
|
||||
pointer-events: none;
|
||||
/* Prevents mouse clicks and other events */
|
||||
/* background-color: #888; */
|
||||
}
|
||||
|
||||
.useEmail {
|
||||
font-size: 10px;
|
||||
color: #424242;
|
||||
@@ -851,6 +855,7 @@ option {
|
||||
z-index: 999;
|
||||
border-radius: 2px;
|
||||
resize: none;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.labelTextArea:focus {
|
||||
|
||||
Reference in New Issue
Block a user