mirror of
https://github.com/Termix-SSH/Mobile.git
synced 2026-07-28 05:51:43 +02:00
2fef85c35c
* fix: ipad keyboard issue + paste key not wokring and disabled auto correct * fix: ipad keyboard issues * fix: ipad styling issues, emoji/voice dictation support, android keyboard issues * fix: ipad styling issues * feat: add debuging to fix ipad keyboard margins * fix: handle physical keyboard special keys in terminal (#6) * feat: add iPadOS build workflow without EAS dependency (#4) * fix: handle physical keyboard special keys in terminal Tab, Escape, and arrow keys from physical keyboards were filtered out by the key.length === 1 check. Add explicit handling like Enter/Backspace. * feat: add iOS native Shift+Tab support via UIKeyCommand Add Expo native module that uses UIKeyCommand + method swizzling to intercept Shift+Tab on iOS hardware keyboards and forward the backtab escape sequence (\x1b[Z]) to the active terminal. --------- Co-authored-by: swing <bestswngs@gmail.com> Co-authored-by: Luke Gustafson <88517757+LukeGus@users.noreply.github.com> * feat: improve ipad ui logic and improve external keyboard handling * feat: fix arrow keys and modifier keys on hardware keybords * fix: fix arrow keys and modifier keys on hardware keybords * feat: add voice over support and improved terminal background conneciton * feat: add missing files * feat: add host key verification support * fix: dictation issues + android IME multi character input issues on android * fix: none auth hosts * chore: clean * chore: update readme --------- Co-authored-by: ZacharyZcR <zacharyzcr1984@gmail.com> Co-authored-by: swing <bestswngs@gmail.com>
27 lines
702 B
TypeScript
27 lines
702 B
TypeScript
import { requireOptionalNativeModule } from "expo-modules-core";
|
|
import type { EventSubscription } from "expo-modules-core";
|
|
|
|
interface KeyCommandEvent {
|
|
input: string;
|
|
shift: boolean;
|
|
ctrl: boolean;
|
|
alt: boolean;
|
|
}
|
|
|
|
interface HardwareKeyboardModule {
|
|
addListener(
|
|
eventName: "onKeyCommand",
|
|
listener: (event: KeyCommandEvent) => void,
|
|
): EventSubscription;
|
|
}
|
|
|
|
const HardwareKeyboard =
|
|
requireOptionalNativeModule<HardwareKeyboardModule>("HardwareKeyboard");
|
|
|
|
export function addKeyCommandListener(
|
|
listener: (event: KeyCommandEvent) => void,
|
|
): EventSubscription | null {
|
|
if (!HardwareKeyboard) return null;
|
|
return HardwareKeyboard.addListener("onKeyCommand", listener);
|
|
}
|