You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Flex component has worked well to demonstrate the possibilities of building a layout, but it is time for it to evolve.
simplify layout props
add href / link ability
rename component to something more appropriate
add testing
move component into ResultLayout for internal use only?
Currently the component is highly coupled to CSS flex box properties to function. I think a more intuitive easier to use set of props would be beneficial to make using the quirky bits of flexbox simpler.
We have needed ways to create anchor tags (links) within layouts, and we have considered a Link component or similar... however, it makes more sense to just extend the capabilities of this component to function as a link if a specific prop is provided (href perhaps). In this way we can leverage the fact that other components are already being wrapped and prevent having another wrapper.
After the changes above the component will no longer be 'flex' only, and so a rename is likely in order. It is a Layout building block, so maybe LayoutContainer or simply Container would be a more appropriate name.
Lastly it is unlikely that this component would be used outside of the ResultLayout, so we should probably move it as a helper component for ResultLayout and not create a story for it, nor export it from the component library.
The text was updated successfully, but these errors were encountered:
The Flex component has worked well to demonstrate the possibilities of building a layout, but it is time for it to evolve.
Currently the component is highly coupled to CSS flex box properties to function. I think a more intuitive easier to use set of props would be beneficial to make using the quirky bits of flexbox simpler.
We have needed ways to create anchor tags (links) within layouts, and we have considered a Link component or similar... however, it makes more sense to just extend the capabilities of this component to function as a link if a specific prop is provided (
href
perhaps). In this way we can leverage the fact that other components are already being wrapped and prevent having another wrapper.After the changes above the component will no longer be 'flex' only, and so a rename is likely in order. It is a Layout building block, so maybe LayoutContainer or simply Container would be a more appropriate name.
Lastly it is unlikely that this component would be used outside of the ResultLayout, so we should probably move it as a helper component for ResultLayout and not create a story for it, nor export it from the component library.
The text was updated successfully, but these errors were encountered: