// Copyright 2024, Command Line Inc.
// SPDX-License-Identifier: Apache-2.0
import { MagnifyIcon } from "@/app/element/magnify";
import { PLATFORM } from "@/app/store/global";
import "./quicktips.scss";
const KeyBinding = ({ keyDecl }: { keyDecl: string }) => {
const parts = keyDecl.split(":");
const elems: React.ReactNode[] = [];
for (let part of parts) {
if (part === "Cmd") {
if (PLATFORM === "darwin") {
elems.push(
⌘ Cmd
);
} else {
elems.push(
Alt
);
}
continue;
}
if (part == "Ctrl") {
elems.push(
^ Ctrl
);
continue;
}
if (part == "Shift") {
elems.push(
⇧ Shift
);
continue;
}
if (part == "Arrows") {
elems.push(
←
);
elems.push(
→
);
elems.push(
↑
);
elems.push(
↓
);
continue;
}
if (part == "Digit") {
elems.push(
Number (1-9)
);
continue;
}
elems.push(
{part.toUpperCase()}
);
}
return {elems}
;
};
const QuickTips = () => {
return (
Header Icons
Connect to a remote server
Important Keybindings
New Tab
New Terminal Block
Navigate Between Blocks
Focus Nth Block
Switch To Nth Tab
wsh commands
wsh view [filename|url]
Run this command in the terminal to preview a file, directory, or web URL.
More Tips
Right click the tabs to change backgrounds or rename.
Click the gear in the web view to set your homepage
Click the gear in the terminal to set your terminal theme and font size
Need More Help?
);
};
export { KeyBinding, QuickTips };