diff options
| author | Aram Drevekenin <aram@poor.dev> | 2026-03-05 21:13:02 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-03-05 21:13:02 +0100 |
| commit | 903cdf5d32476a8d6cc208d2c418a1f2c67e5a53 (patch) | |
| tree | 9a4647d9dc3efcdea8149fd78fdfa956b3c8d8cb /zellij-utils/src/plugin_api/plugin_command.proto | |
| parent | build: make test mirror build command for plugins (#4801) (diff) | |
| download | sl0ppij-903cdf5d32476a8d6cc208d2c418a1f2c67e5a53.tar.gz sl0ppij-903cdf5d32476a8d6cc208d2c418a1f2c67e5a53.tar.xz sl0ppij-903cdf5d32476a8d6cc208d2c418a1f2c67e5a53.zip | |
Click file paths to open in editor, allow plugins to change styles and hover of viewport (#4802)
* initial implementation
* implement hover
* add styles and foreground/background emphases, fix upsert hover collisions
* initial implementation of link plugin
* suppress highlighting + clicks on unfocused and mouse mode panes
* also make italic
* fix env var and ~ expansions
* fix regex issues and add defensive validations
* fix tests and add plugin assets
* add tests
* refactor all the things
* add pr
Diffstat (limited to 'zellij-utils/src/plugin_api/plugin_command.proto')
| -rw-r--r-- | zellij-utils/src/plugin_api/plugin_command.proto | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/zellij-utils/src/plugin_api/plugin_command.proto b/zellij-utils/src/plugin_api/plugin_command.proto index 53e9d729..c4fa949f 100644 --- a/zellij-utils/src/plugin_api/plugin_command.proto +++ b/zellij-utils/src/plugin_api/plugin_command.proto @@ -199,6 +199,8 @@ enum CommandName { HideFloatingPanes = 204; ShowFloatingPanes = 205; SetPaneColor = 206; + SetPaneRegexHighlights = 207; + ClearPaneHighlights = 208; } message PluginCommand { @@ -347,6 +349,8 @@ message PluginCommand { HideFloatingPanesPayload hide_floating_panes_payload = 155; ShowFloatingPanesPayload show_floating_panes_payload = 156; SetPaneColorPayload set_pane_color_payload = 157; + SetPaneRegexHighlightsPayload set_pane_regex_highlights_payload = 158; + ClearPaneHighlightsPayload clear_pane_highlights_payload = 159; } } @@ -1220,3 +1224,52 @@ message SetPaneColorPayload { optional string fg = 2; optional string bg = 3; } + +message HighlightStyle { + oneof style { + bool emphasis_0 = 1; + bool emphasis_1 = 2; + bool emphasis_2 = 3; + bool emphasis_3 = 4; + CustomRgbHighlight custom_rgb = 5; + CustomIndexHighlight custom_index = 6; + bool background_emphasis_0 = 7; + bool background_emphasis_1 = 8; + bool background_emphasis_2 = 9; + bool background_emphasis_3 = 10; + bool none = 11; + } +} + +message CustomRgbHighlight { + optional uint32 fg_r = 1; + optional uint32 fg_g = 2; + optional uint32 fg_b = 3; + optional uint32 bg_r = 4; + optional uint32 bg_g = 5; + optional uint32 bg_b = 6; +} + +message CustomIndexHighlight { + optional uint32 fg = 1; + optional uint32 bg = 2; +} + +message RegexHighlight { + string pattern = 1; + HighlightStyle style = 2; + repeated ContextItem context = 3; + bool on_hover = 4; + bool bold = 5; + bool italic = 6; + bool underline = 7; +} + +message SetPaneRegexHighlightsPayload { + PaneId pane_id = 1; + repeated RegexHighlight highlights = 2; +} + +message ClearPaneHighlightsPayload { + PaneId pane_id = 1; +} |
