style-guide
style-guide copied to clipboard
Flexible width option for text container
Flex and Text components has no flexibility options for complying of it's parent element's width.
Issue
Expected
Can style-guide have more flexible containers that inherit of its parents width? Something like in this example https://codepen.io/seahindeniz/pen/jOPjBJv
<Flex direction="column" className="sg-flex--fit-content">
<Flex marginBottom="m">
<Text>This box generates the width</Text>
</Flex>
<Flex>
<Flex className="sg-flex--grow sg-flex--min-content">
<Text>
This box should not generate width for its content size and needs to
comply the width of its parents or previous elements width. Lorem ipsum
dolor sit amet, consectetur adipiscing elit. Fusce quis elit dui. Donec
tincidunt velit at justo congue suscipit.
</Text>
</Flex>
</Flex>
</Flex>
Hi @seahindeniz . Thanks for suggesting this.
@coderitual This might be nice addition to Flex component. We have a similar example in Input with an error message so we could use this to remove additional classes there. What's your opinion?