Guide for adding new configuration settings to Wave Terminal. Use when adding a new setting to the configuration system, implementing a new config key, or adding user-customizable settings.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
Guide for creating and displaying context menus in Wave Terminal. Use when implementing right-click menus, adding context menu items, creating submenus, or handling menu interactions with checkboxes and separators.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
설치 방법 보기설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.
This guide provides a quick overview of how to create and display a context menu using our system.
Define each menu item using the ContextMenuItem type:
type ContextMenuItem = {
label?: string;
type?: "separator" | "normal" | "submenu" | "checkbox" | "radio";
role?: string; // Electron role (optional)
click?: () => void; // Callback for item selection (not needed if role is set)
submenu?: ContextMenuItem[]; // For nested menus
checked?: boolean; // For checkbox or radio items
visible?: boolean;
enabled?: boolean;
sublabel?: string;
};
Import the context menu module:
import { ContextMenuModel } from "@/app/store/contextmenu";
To display the context menu, call:
ContextMenuModel.getInstance().showContextMenu(menu, event);
ContextMenuItem.A simple context menu with a separator:
const menu: ContextMenuItem[] = [
{
label: "New File",
click: () => {
/* create a new file */
},
},
{
label: "New Folder",
click: () => {
/* create a new folder */
},
},
{ type: "separator" },
{
label: "Rename",
click: () => {
/* rename item */
},
},
];
ContextMenuModel.getInstance().showContextMenu(menu, e);
Toggle settings using a submenu with checkbox items:
const isClearOnStart = true; // Example setting
const menu: ContextMenuItem[] = [
{
label: "Clear Output On Restart",
submenu: [
{
label: "On",
type: "checkbox",
checked: isClearOnStart,
click: () => {
// Set the config to enable clear on restart
},
},
{
label: "Off",
type: "checkbox",
checked: !isClearOnStart,
click: () => {
// Set the config to disable clear on restart
},
},
],
},
];
ContextMenuModel.getInstance().showContextMenu(menu, e);
Open a configuration file (e.g., widgets.json) in preview mode:
{
label: "Edit widgets.json",
click: () => {
fireAndForget(async () => {
const path = `${getApi().getConfigDir()}/widgets.json`;
const blockDef: BlockDef = {
meta: { view: "preview", file: path },
};
await createBlock(blockDef, false, true);
});
},
}
ContextMenuItem type.click for actions; use submenu for nested options.type: "separator" to group items.type: "checkbox" or "radio" with the checked property.ContextMenuModel.getInstance().showContextMenu(menu, event) to render the menu.Context menus are commonly used for file operations like creating, renaming, and deleting files or folders.
Use checkbox menu items to toggle settings on and off, with the checked property reflecting the current state.
Use submenu to organize related options hierarchically, keeping the top-level menu clean and organized.
Use the visible and enabled properties to dynamically show or disable menu items based on the current state.
아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.
로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.
아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.
Guide for adding new configuration settings to Wave Terminal. Use when adding a new setting to the configuration system, implementing a new config key, or adding user-customizable settings.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
Guide for adding new RPC calls to Wave Terminal. Use when implementing new RPC commands, adding server-client communication methods, or extending the RPC interface with new functionality.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
Guide for adding new wsh commands to Wave Terminal. Use when implementing new CLI commands, adding command-line functionality, or extending the wsh command interface.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
Guide for implementing a new view type in Wave Terminal. Use when creating a new view component, implementing the ViewModel interface, registering a new view type in BlockRegistry, or adding a new content type to display within blocks.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
Guide for adding new Electron APIs to Wave Terminal. Use when implementing new frontend-to-electron communications via preload/IPC.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
Search and order products online. Compares prices across Polish marketplaces (Allegro, Ceneo, Google Shopping), presents options in a comparison table, and assists with checkout. Handles the full flow: priority selection, research, comparison, cart, and checkout handoff. Triggers on: "order", "buy", "find product", "compare prices", "cheapest", "zamow", "kup", "znajdz produkt", "porownaj ceny", "najtaniej".
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.