diff options
author | Kitson Kelly <me@kitsonkelly.com> | 2021-11-23 11:08:56 +1100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-11-23 11:08:56 +1100 |
commit | bf5657cd590a0624d614a09ff6fc3538f94643da (patch) | |
tree | 26420625430f9b043d8406ed21039fb962b7a502 /cli/lsp/capabilities.rs | |
parent | 3abe31252e02c3488727c7aa15a4d3a301d96531 (diff) |
feat(lsp): add workspace symbol provider (#12787)
Diffstat (limited to 'cli/lsp/capabilities.rs')
-rw-r--r-- | cli/lsp/capabilities.rs | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/cli/lsp/capabilities.rs b/cli/lsp/capabilities.rs index a664c296d..e05cc27b8 100644 --- a/cli/lsp/capabilities.rs +++ b/cli/lsp/capabilities.rs @@ -12,6 +12,7 @@ use lspower::lsp::CodeActionOptions; use lspower::lsp::CodeActionProviderCapability; use lspower::lsp::CodeLensOptions; use lspower::lsp::CompletionOptions; +use lspower::lsp::DocumentSymbolOptions; use lspower::lsp::FoldingRangeProviderCapability; use lspower::lsp::HoverProviderCapability; use lspower::lsp::ImplementationProviderCapability; @@ -114,9 +115,13 @@ pub fn server_capabilities( )), references_provider: Some(OneOf::Left(true)), document_highlight_provider: Some(OneOf::Left(true)), - // TODO: Provide a label once https://github.com/gluon-lang/lsp-types/pull/207 is merged - document_symbol_provider: Some(OneOf::Left(true)), - workspace_symbol_provider: None, + document_symbol_provider: Some(OneOf::Right(DocumentSymbolOptions { + label: Some("Deno".to_string()), + work_done_progress_options: WorkDoneProgressOptions { + work_done_progress: None, + }, + })), + workspace_symbol_provider: Some(OneOf::Left(true)), code_action_provider: Some(code_action_provider), code_lens_provider: Some(CodeLensOptions { resolve_provider: Some(true), |