Skip to content
Merged
8 changes: 4 additions & 4 deletions .kilocode/skills/context-menu/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ import { ContextMenuModel } from "@/app/store/contextmenu";
To display the context menu, call:

```ts
ContextMenuModel.showContextMenu(menu, event);
ContextMenuModel.getInstance().showContextMenu(menu, event);
```

- **menu**: An array of `ContextMenuItem`.
Expand Down Expand Up @@ -75,7 +75,7 @@ const menu: ContextMenuItem[] = [
},
];

ContextMenuModel.showContextMenu(menu, e);
ContextMenuModel.getInstance().showContextMenu(menu, e);
```

---
Expand Down Expand Up @@ -111,7 +111,7 @@ const menu: ContextMenuItem[] = [
},
];

ContextMenuModel.showContextMenu(menu, e);
ContextMenuModel.getInstance().showContextMenu(menu, e);
```

---
Expand Down Expand Up @@ -143,7 +143,7 @@ Open a configuration file (e.g., `widgets.json`) in preview mode:
- **Actions**: Use `click` for actions; use `submenu` for nested options.
- **Separators**: Use `type: "separator"` to group items.
- **Toggles**: Use `type: "checkbox"` or `"radio"` with the `checked` property.
- **Displaying**: Use `ContextMenuModel.showContextMenu(menu, event)` to render the menu.
- **Displaying**: Use `ContextMenuModel.getInstance().showContextMenu(menu, event)` to render the menu.

## Common Use Cases

Expand Down
1 change: 1 addition & 0 deletions .roo/rules/rules.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ The full API is defined in custom.d.ts as type ElectronApi.
- **CRITICAL** - useAtomValue and useAtom are React HOOKS. They cannot be used inline in JSX code, they must appear at the top of a component in the hooks area of the react code.
- for simple functions, we prefer `if (!cond) { return }; functionality;` pattern overn `if (cond) { functionality }` because it produces less indentation and is easier to follow.
- It is now 2026, so if you write new files, or update files use 2026 for the copyright year
- React.MutableRefObject is deprecated, just use React.RefObject now (current is now always mutable)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

"Deprecated" is imprecise — MutableRefObject was removed, not deprecated, in React 19.

In @types/react@^19, React.MutableRefObject was outright removed (not just deprecated). Saying "deprecated" implies it still exists but is discouraged; developers may go looking for it and be surprised when the type is simply absent.

✏️ Suggested wording
-  React.MutableRefObject is deprecated, just use React.RefObject now (current is now always mutable)
+  React.MutableRefObject has been removed in React 19. Use React.RefObject instead (current is now always mutable).
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
- React.MutableRefObject is deprecated, just use React.RefObject now (current is now always mutable)
- React.MutableRefObject has been removed in React 19. Use React.RefObject instead (current is now always mutable)
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.roo/rules/rules.md at line 96, Update the wording that currently says
"deprecated" for React.MutableRefObject to state it was "removed" in React 19
and `@types/react`@^19, and clarify that developers should use React.RefObject
(current refs are always mutable) — change the sentence referencing
React.MutableRefObject to mention removal in React 19/@types/react@^19 and
recommend React.RefObject as the replacement.


### Strict Comment Rules

Expand Down
Loading
Loading