diff --git a/crates/gpui/src/taffy.rs b/crates/gpui/src/taffy.rs index c3113ad2cb91ad8c9e29360812716114a7427052..11cb0872861321c3c06c3f8a5bf79fdd30eb2275 100644 --- a/crates/gpui/src/taffy.rs +++ b/crates/gpui/src/taffy.rs @@ -8,7 +8,6 @@ use std::{fmt::Debug, ops::Range}; use taffy::{ TaffyTree, TraversePartialTree as _, geometry::{Point as TaffyPoint, Rect as TaffyRect, Size as TaffySize}, - prelude::min_content, style::AvailableSpace as TaffyAvailableSpace, tree::NodeId, }; @@ -296,7 +295,7 @@ trait ToTaffy { impl ToTaffy for Style { fn to_taffy(&self, rem_size: Pixels, scale_factor: f32) -> taffy::style::Style { - use taffy::style_helpers::{length, minmax, repeat}; + use taffy::style_helpers::{fr, length, minmax, repeat}; fn to_grid_line( placement: &Range, @@ -310,8 +309,8 @@ impl ToTaffy for Style { fn to_grid_repeat( unit: &Option, ) -> Vec> { - // grid-template-columns: repeat(, minmax(0, min-content)); - unit.map(|count| vec![repeat(count, vec![minmax(length(0.0), min_content())])]) + // grid-template-columns: repeat(, minmax(0, 1fr)); + unit.map(|count| vec![repeat(count, vec![minmax(length(0.0), fr(1.0))])]) .unwrap_or_default() }