Problem
To match CSS, thegap property should not really have Auto or Undefined variants.
See: bevyengine/bevy#6743 (comment)
Proposed solution
A new LengthPercentage enum which does not include the Undefined or Auto variants
enum LengthPercentage {
/// Abstract absolute units
Points(f32),
/// The dimension is stored in percentage relative to the parent item.
Percent(f32),
}
Not 100% sure on the name, but LengthPercentage is what the CSS specification uses and is pretty descriptive.
Notes
This isn't really a problem in practice. We currently just treat Auto and Undefined as 0.0. But it is potentially confusing to users of taffy.
Problem
To match CSS, the
gapproperty should not really haveAutoorUndefinedvariants.See: bevyengine/bevy#6743 (comment)
Proposed solution
A new
LengthPercentageenum which does not include theUndefinedorAutovariantsNot 100% sure on the name, but
LengthPercentageis what the CSS specification uses and is pretty descriptive.Notes
This isn't really a problem in practice. We currently just treat
AutoandUndefinedas0.0. But it is potentially confusing to users of taffy.