дзеркало
https://github.com/l0ng-ai/openidea.git
синхронізовано 2026-11-09 11:15:40 +02:00
feat(plugins): let plugin views open a project file at a line (#1362)
Plugin tool windows that list code locations (routes, failed tests, queries) had no way to take the user to file:line. A host import `views.open-location(path, line, column)` opens a file inside the project in an editor of the window the call came from, caret at the given line and column (0-based, UTF-16). It needs `project.read` and refuses paths outside the project; the event goes only to the calling window, as `open-terminal` does. The Rust SDK exposes it as `host::open_location` (with the mock), the API table lists it, and the shipped components are rebuilt for the new WIT. Closes #1334 Co-authored-by: yzPeedro <[email protected]>
Цей коміт міститься в:
1 джерело
7ffaa0b5da
коміт
8d784ac164
42 files changed
+114
-16
No files matched your search
@@ -313,6 +313,7 @@ then run `openidea-plugin check`.
|
||||
| `host::refresh_view(view)` | `views.refresh` | The view (or custom editors) render again; call it when the content changed. |
|
||||
| `host::post_view_message(view, text)` | `views.post-message` | To the script of the view's `html` body. |
|
||||
| `host::open_terminal(title, program, args)` | `views.open-terminal` | A terminal tab in the invoking window running the approved `process:<program>` in the project root: output that keeps coming, interactive sessions. |
|
||||
| `host::open_location(path, line, column)` | `views.open-location` | Opens a file inside the project in an editor of the invoking window, the caret at `line`/`column` (0-based, UTF-16): a view's links to code. Needs `project.read`. |
|
||||
| `host::setting(key)`, `setting_bool`, `setting_string`, `setting_number` | `settings.get` | The user's value (project over global) or the schema's default. |
|
||||
|
||||
`run-command` receives an optional string argument: `executeAction("plugin.<plugin id>.<command id>", "arg")`
|
||||
|
||||
Бінарний файл не відображається.
@@ -1 +1 @@
|
||||
28e4bf10a41bdda011111b0e150ebe96205c57f410bad98c19eea3f1286349d6
|
||||
9ad412cb7b853d40467c67305a1126bb87910d179ecfa1c88e13d4a900367c50
|
||||
Бінарний файл не відображається.
@@ -1 +1 @@
|
||||
7e015486cc916f5edbac542863373fd7204f5bcd534f6c408d5f9d2b72913862
|
||||
49a3c6bf2511ba137457397203244bdfca3d6e10f62dbc7fde9473dab07f6457
|
||||
Бінарний файл не відображається.
@@ -1 +1 @@
|
||||
a6cf59e74595e13908e2cbf1752c58665c6963de258413c9d7332d2a7dd9cbd0
|
||||
c199dc52e00d3943882d532e7e6095f7b2f8d7d6026cf1ccaa685dd6300f2319
|
||||
Бінарний файл не відображається.
@@ -1 +1 @@
|
||||
b8dde206a74b222b93e61056d4cbe403617ae240d142e01e91420a2aacdb2da4
|
||||
6047be5eeaa1330d7aa1f182e88ae2f352f244829ad9a01fdc3a2a081bdca95d
|
||||
Бінарний файл не відображається.
@@ -1 +1 @@
|
||||
a681c2abd4a65d6aeb62efd514e9b170f4fca52b0c14d2d380a3b04be0a3fbc6
|
||||
7a3ee410d228d1e39155aa042237d222d23d7f5a45e261086cffc45c6ee1ad32
|
||||
Бінарний файл не відображається.
@@ -1 +1 @@
|
||||
3c83bc9559df54457e19e650cdd21bab9d609e22daaa1fc4f596910b70834a34
|
||||
7658a95eb9fc27468cae4b1d20e3b5ab299fde478e07f69ab0fdb4cc10caf11d
|
||||
Бінарний файл не відображається.
@@ -1 +1 @@
|
||||
63f1bbdf6eca5a4642cd3453ae384ff3f876de0373c12008b757a63852164b71
|
||||
227a30ef0028f167a20825bdd775b15392161e641f6c68030e01d0c79e263bb5
|
||||
Бінарний файл не відображається.
@@ -1 +1 @@
|
||||
0db5cb24c358651d0e728ab3efb52286290c1a38ec379435225c935d4165ad6a
|
||||
046f769822102de0d4ecec99ad41027cb792941065226716f38a6e64c50ff364
|
||||
Бінарний файл не відображається.
@@ -1 +1 @@
|
||||
257478b050ea360c55e904f2a89c6069293139ff0d97ba860de3f29dac927787
|
||||
0b9c3572390a3caab7d47f9b975439f8dde3feff6b9044579d99b8334ac2a692
|
||||
Бінарний файл не відображається.
@@ -1 +1 @@
|
||||
21e7510d6a3712bf0f21d53a5c8d652e3c2787d89a1fc25998cde96efe124207
|
||||
0af62bcd4583d126a616cafbf2ddc80f039a3ead2b5dcb7144222b0ebc673432
|
||||
Бінарний файл не відображається.
@@ -1 +1 @@
|
||||
04844bfbfbcb1770f4f4742658944c592922b037b2387e9340de58ef0d9baacc
|
||||
24ef150beefb05622212228e1c44cb487fffe6526776762d713f3ebdf4c02ac0
|
||||
Reference in new issue
Заблокувати користувача