koin.js 1.2.2 → 1.2.4
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 +16 -7
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +16 -7
- package/dist/index.mjs.map +1 -1
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -2682,14 +2682,14 @@ function useTouchHandlers({
|
|
|
2682
2682
|
const touch = e.touches[0];
|
|
2683
2683
|
e.preventDefault();
|
|
2684
2684
|
e.stopPropagation();
|
|
2685
|
-
if (hapticsEnabled && navigator.vibrate) {
|
|
2686
|
-
navigator.vibrate(8);
|
|
2687
|
-
}
|
|
2688
2685
|
if (isSystemButton) {
|
|
2689
2686
|
onPress(buttonType);
|
|
2690
2687
|
} else if (onPressDown) {
|
|
2691
2688
|
onPressDown(buttonType);
|
|
2692
2689
|
}
|
|
2690
|
+
if (hapticsEnabled && navigator.vibrate) {
|
|
2691
|
+
queueMicrotask(() => navigator.vibrate(8));
|
|
2692
|
+
}
|
|
2693
2693
|
if (onPositionChange) {
|
|
2694
2694
|
const target = e.currentTarget;
|
|
2695
2695
|
if (!target) return;
|
|
@@ -2697,7 +2697,7 @@ function useTouchHandlers({
|
|
|
2697
2697
|
drag.checkDragStart(touch.clientX, touch.clientY, rect);
|
|
2698
2698
|
}
|
|
2699
2699
|
},
|
|
2700
|
-
[isSystemButton, buttonType, onPress, onPressDown, onPositionChange, drag]
|
|
2700
|
+
[isSystemButton, buttonType, onPress, onPressDown, onPositionChange, drag, hapticsEnabled]
|
|
2701
2701
|
);
|
|
2702
2702
|
const handleTouchMove = React2.useCallback(
|
|
2703
2703
|
(e) => {
|
|
@@ -7444,8 +7444,10 @@ function useEmulatorCore({
|
|
|
7444
7444
|
// Offload to prevent UI blocking
|
|
7445
7445
|
audio_latency: 96,
|
|
7446
7446
|
// Larger buffer prevents audio crackle
|
|
7447
|
-
rewind_enable: false
|
|
7447
|
+
rewind_enable: false,
|
|
7448
7448
|
// Save RAM - savestate buffer is expensive
|
|
7449
|
+
video_max_swapchain_images: 3
|
|
7450
|
+
// Smoother frame delivery on mobile
|
|
7449
7451
|
};
|
|
7450
7452
|
} else {
|
|
7451
7453
|
console.warn("[Nostalgist] SharedArrayBuffer not available. Falling back to main-thread rendering for heavy system.");
|
|
@@ -7455,7 +7457,9 @@ function useEmulatorCore({
|
|
|
7455
7457
|
// Fallback: Main thread (might stutter)
|
|
7456
7458
|
audio_latency: 128,
|
|
7457
7459
|
// Increase latency further to handle main thread blocking
|
|
7458
|
-
rewind_enable: false
|
|
7460
|
+
rewind_enable: false,
|
|
7461
|
+
video_max_swapchain_images: 3
|
|
7462
|
+
// Smoother frame delivery on mobile
|
|
7459
7463
|
};
|
|
7460
7464
|
}
|
|
7461
7465
|
}
|
|
@@ -7548,7 +7552,12 @@ function useEmulatorCore({
|
|
|
7548
7552
|
cheevos_hardcore_mode_enable: retroAchievements.hardcore ?? false,
|
|
7549
7553
|
cheevos_verbose_enable: true
|
|
7550
7554
|
} : {}
|
|
7551
|
-
}
|
|
7555
|
+
},
|
|
7556
|
+
// Core-specific options (e.g., FBNeo CPU clock)
|
|
7557
|
+
retroarchCoreConfig: system.toUpperCase() === "ARCADE" ? {
|
|
7558
|
+
"fbneo_cpu_speed_adjust": "150"
|
|
7559
|
+
// 150% CPU clock reduces slowdowns on mobile
|
|
7560
|
+
} : {}
|
|
7552
7561
|
};
|
|
7553
7562
|
if (biosUrl) {
|
|
7554
7563
|
prepareOptions.bios = biosUrl;
|