mirror of
https://github.com/OpenSignLabs/OpenSign.git
synced 2026-08-20 06:35:54 +02:00
fix: date is not changable in signyourself flow of mobile
This commit is contained in:
@@ -144,6 +144,21 @@ function Placeholder(props) {
|
||||
|
||||
return () => clearTimeout(timer);
|
||||
}, [props.pos]);
|
||||
|
||||
useEffect(() => {
|
||||
const closeMenuOnOutsideClick = (e) => {
|
||||
if (!isDraggingEnabled && !e.target.closest("#changeIsDragging")) {
|
||||
setDraggingEnabled(true);
|
||||
}
|
||||
};
|
||||
|
||||
document.addEventListener("click", closeMenuOnOutsideClick);
|
||||
|
||||
return () => {
|
||||
// Cleanup the event listener when the component unmounts
|
||||
document.removeEventListener("click", closeMenuOnOutsideClick);
|
||||
};
|
||||
}, [isDraggingEnabled]);
|
||||
//function change format array list with selected date and format
|
||||
const changeDateFormat = () => {
|
||||
const updateDate = [];
|
||||
|
||||
@@ -2,6 +2,7 @@ import React from "react";
|
||||
import { themeColor } from "../../constant/const";
|
||||
import {
|
||||
defaultWidthHeight,
|
||||
isMobile,
|
||||
radioButtonWidget,
|
||||
resizeBorderExtraWidth
|
||||
} from "../../constant/Utils";
|
||||
@@ -30,7 +31,7 @@ function PlaceholderBorder(props) {
|
||||
};
|
||||
return (
|
||||
<div
|
||||
onMouseEnter={props?.setDraggingEnabled(true)}
|
||||
onMouseEnter={!isMobile && props?.setDraggingEnabled(true)}
|
||||
className="borderResize"
|
||||
style={{
|
||||
borderColor: themeColor,
|
||||
|
||||
Reference in New Issue
Block a user