Allow to temporarily toggle diagnostics in the editor (#30316)
* Adds a `diagnostics_max_severity: null` editor settings that has previous hardcoded default, `warning` * Make inline diagnostics to inherit this setting by default (can be overridden with its own max_severity setting) * Allows to toggle diagnostics in the editor menu and via new action, `editor::ToggleDiagnostics` Closes https://github.com/zed-industries/zed/issues/4686 Release Notes: - N/A *or* Added/Fixed/Improved ...
This commit is contained in:
parent
9e5d115e72
commit
a8312d623d
12 changed files with 279 additions and 96 deletions
|
@ -18,7 +18,7 @@ use gpui::{
|
|||
};
|
||||
use multi_buffer::ToPoint;
|
||||
use pretty_assertions::assert_eq;
|
||||
use project::Project;
|
||||
use project::{Project, project_settings::DiagnosticSeverity};
|
||||
use ui::{App, BorrowAppContext, px};
|
||||
use util::test::{marked_text_offsets, marked_text_ranges};
|
||||
|
||||
|
@ -72,6 +72,7 @@ pub fn marked_display_snapshot(
|
|||
1,
|
||||
1,
|
||||
FoldPlaceholder::test(),
|
||||
DiagnosticSeverity::Warning,
|
||||
cx,
|
||||
)
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue