Vibration & haptics
vibrate(options), cancel()。
- Methods: vibrate(options), cancel()
TSXVibration
1import { Vibration } from "@quan-erp/shared-frontend-core";
2
3export function HapticConfirm() {
4 const haptics = Vibration.instance;
5
6 return (
7 <>
8 <button type="button" onClick={() => void haptics.vibrate({})}>
9 Pulse
10 </button>
11 <button type="button" onClick={() => haptics.cancel()}>
12 Cancel
13 </button>
14 </>
15 );
16}