Skip to content

Conversation

alishaevn
Copy link
Member

@alishaevn alishaevn commented Feb 14, 2023

ref: scientist-hq/webstore#176

expected behavior

  • return the bottom margin to the TextBox component
  • set up several more components to accept color setting variables
  • expand the color palette to include 4 darker and 4 lighter shades of the primary, secondary, light and dark brand colors

{paragraphs.map((par, index) => (
<div className={`text-box--${alignment} ${addClass || ''}`} key={index}>
<p
className={`text-box text-box--${size} mb-0`}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

when we have multiple paragraphs, we want space between them. I initially had a conditional to remove the spacing from the last paragraph only, but felt that was too specific to our current use case. (part of the "about us" section).

in the future, this component could be used anywhere, and having the bottom margin is a good thing.

<>
<Title title='My Requests' size='medium' />
<div className='rounded overflow-hidden'>
<div className='rounded overflow-hidden mb-4'>
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

adds some spacing between the last item in the list, and the footer.

</div>
)
})}
const StatusBar = ({ backgroundColor, statusArray, apiRequestStatus, addClass }) => {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added backgroundColor

import './status-bar.scss'

const StatusBar = ({ statusArray, apiRequestStatus, addClass }) => (
<div className={`container ${addClass}`}>
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the majority of this code is the same. I needed to create a new variable and function though, so the return body is no longer immediately being returned. a lot of this change is adding indention for that reason.

return (
<div
className={`status-bar-column col-3 py-2 gap-2 d-flex justify-content-center align-items-center
${border} ${labelBgColor(index)}`}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

deriving both of these classes from the new code above.

@alishaevn alishaevn marked this pull request as ready for review February 17, 2023 20:40
@alishaevn alishaevn merged commit baaeb34 into main Feb 17, 2023
@alishaevn alishaevn deleted the 176-demo-account branch February 26, 2024 22:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants