As a developer,
I want to be able to use the linear gradient component in more situations,
So that we don't duplicate our code unnecessarily
The linear gradient component currently only supports a horizontal format, but we can extend it to be usable in either a horizontal or in a vertical context
Acceptance Criteria:
[x] Update LinearGradient.js to accept a height prop as well as width, and use it to set a height css value just like we're doing with the width.
[x] Adjust the css so that the line component has a width property that can be fell back on if one isn't provided in the component props
[x] To test, use the LinearGradient component, and pass in height for props instead of width. You should see a vertical line now!
I tested the code, but it seems like the code overrides the width and height that I put into the component and takes in the width and height from the CSS file first.
User Story:
The linear gradient component currently only supports a horizontal format, but we can extend it to be usable in either a horizontal or in a vertical context
Acceptance Criteria:
LinearGradient.js
to accept aheight
prop as well aswidth
, and use it to set aheight
css value just like we're doing with the width.width
property that can be fell back on if one isn't provided in the component propsLinearGradient
component, and pass in height for props instead of width. You should see a vertical line now!