Another batch of lint fixes (#36521)

- **Enable a bunch of extra lints**
- **First batch of fixes**
- **More fixes**

Release Notes:

- N/A
This commit is contained in:
Piotr Osiewicz 2025-08-19 22:33:44 +02:00 committed by GitHub
parent 69b1c6d6f5
commit 6825715503
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
147 changed files with 788 additions and 1042 deletions

View file

@ -269,10 +269,9 @@ where
};
let picker_view = cx.new(|cx| {
let picker = Picker::uniform_list(delegate, window, cx)
Picker::uniform_list(delegate, window, cx)
.width(rems(30.))
.max_height(Some(rems(20.).into()));
picker
.max_height(Some(rems(20.).into()))
});
PopoverMenu::new("kernel-switcher")

View file

@ -91,7 +91,7 @@ fn convert_outputs(
cx: &mut App,
) -> Vec<Output> {
outputs
.into_iter()
.iter()
.map(|output| match output {
nbformat::v4::Output::Stream { text, .. } => Output::Stream {
content: cx.new(|cx| TerminalOutput::from(&text.0, window, cx)),

View file

@ -584,8 +584,8 @@ impl project::ProjectItem for NotebookItem {
Ok(nbformat::Notebook::Legacy(legacy_notebook)) => {
// TODO: Decide if we want to mutate the notebook by including Cell IDs
// and any other conversions
let notebook = nbformat::upgrade_legacy_notebook(legacy_notebook)?;
notebook
nbformat::upgrade_legacy_notebook(legacy_notebook)?
}
// Bad notebooks and notebooks v4.0 and below are not supported
Err(e) => {

View file

@ -68,7 +68,7 @@ pub fn text_style(window: &mut Window, cx: &mut App) -> TextStyle {
let theme = cx.theme();
let text_style = TextStyle {
TextStyle {
font_family,
font_features,
font_weight,
@ -81,9 +81,7 @@ pub fn text_style(window: &mut Window, cx: &mut App) -> TextStyle {
// These are going to be overridden per-cell
color: theme.colors().terminal_foreground,
..Default::default()
};
text_style
}
}
/// Returns the default terminal size for the terminal output.