koin.js 1.0.15 → 1.0.16
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.
- package/dist/index.js +21 -5
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +21 -5
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -821,7 +821,7 @@ var SaveLoadControls = memo(function SaveLoadControls2({
|
|
|
821
821
|
{
|
|
822
822
|
progress: autoSaveProgress,
|
|
823
823
|
state: autoSavePaused ? "idle" : autoSaveState,
|
|
824
|
-
intervalSeconds:
|
|
824
|
+
intervalSeconds: 60,
|
|
825
825
|
isPaused: autoSavePaused,
|
|
826
826
|
onClick: onAutoSaveToggle
|
|
827
827
|
}
|
|
@@ -3701,14 +3701,22 @@ var Dpad = React2.memo(function Dpad2({
|
|
|
3701
3701
|
if (!touch) return;
|
|
3702
3702
|
if (drag.isDragging) {
|
|
3703
3703
|
drag.handleDragMove(touch.clientX, touch.clientY);
|
|
3704
|
+
} else if (onPositionChange) {
|
|
3705
|
+
const startedDrag = drag.checkMoveThreshold(touch.clientX, touch.clientY);
|
|
3706
|
+
if (!startedDrag) {
|
|
3707
|
+
drag.clearDragTimer();
|
|
3708
|
+
const rect = dpadRef.current?.getBoundingClientRect();
|
|
3709
|
+
if (rect) {
|
|
3710
|
+
updateDirections(getDirectionsFromTouch(touch.clientX, touch.clientY, rect));
|
|
3711
|
+
}
|
|
3712
|
+
}
|
|
3704
3713
|
} else {
|
|
3705
3714
|
const rect = dpadRef.current?.getBoundingClientRect();
|
|
3706
3715
|
if (rect) {
|
|
3707
|
-
drag.clearDragTimer();
|
|
3708
3716
|
updateDirections(getDirectionsFromTouch(touch.clientX, touch.clientY, rect));
|
|
3709
3717
|
}
|
|
3710
3718
|
}
|
|
3711
|
-
}, [drag, getDirectionsFromTouch, updateDirections]);
|
|
3719
|
+
}, [drag, getDirectionsFromTouch, updateDirections, onPositionChange]);
|
|
3712
3720
|
const handleTouchEnd = useCallback((e) => {
|
|
3713
3721
|
e.preventDefault();
|
|
3714
3722
|
drag.clearDragTimer();
|
|
@@ -3909,8 +3917,16 @@ function ControlsHint({ isVisible }) {
|
|
|
3909
3917
|
children: [
|
|
3910
3918
|
/* @__PURE__ */ jsx("div", { className: "flex justify-center mb-4", children: /* @__PURE__ */ jsx("div", { className: "w-16 h-16 rounded-full bg-green-500/20 border-2 border-green-400 flex items-center justify-center", children: /* @__PURE__ */ jsx(Move, { size: 32, className: "text-green-400" }) }) }),
|
|
3911
3919
|
/* @__PURE__ */ jsx("h3", { className: "text-white text-lg font-bold mb-2", children: "Customize Your Controls" }),
|
|
3912
|
-
/* @__PURE__ */ jsxs("p", { className: "text-white/70 text-sm mb-
|
|
3913
|
-
|
|
3920
|
+
/* @__PURE__ */ jsxs("p", { className: "text-white/70 text-sm mb-3", children: [
|
|
3921
|
+
"Use the ",
|
|
3922
|
+
/* @__PURE__ */ jsx(Lock, { size: 12, className: "inline mx-1 text-white" }),
|
|
3923
|
+
" ",
|
|
3924
|
+
/* @__PURE__ */ jsx("strong", { className: "text-white", children: "lock icon" }),
|
|
3925
|
+
" at the top to unlock controls for repositioning."
|
|
3926
|
+
] }),
|
|
3927
|
+
/* @__PURE__ */ jsxs("p", { className: "text-white/70 text-sm mb-3", children: [
|
|
3928
|
+
"When unlocked, ",
|
|
3929
|
+
/* @__PURE__ */ jsx("strong", { className: "text-white", children: "long-press" }),
|
|
3914
3930
|
" any button or the ",
|
|
3915
3931
|
/* @__PURE__ */ jsx("strong", { className: "text-white", children: "D-pad center" }),
|
|
3916
3932
|
" to drag and reposition it."
|