-
Notifications
You must be signed in to change notification settings - Fork 14
modal - should be no title OR description on top margin #374
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One question that might be worth double checking 😄
marginTop: | ||
size === "large" ? 24 : size === "medium" ? 16 : 12, | ||
}, | ||
(title || description) && { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Im not quite sure about having description here? Does the description render in the top section? I would assume this would just be title &&
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the logic is right but the title is possibly confused?
this makes sense (title || description) ? defaultMargin : noMargin
which is what the code has
(gosh this component is getting tangly though, really want to chop it up)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah, the description does render in the top section - very tangly component FOR SURE
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚢
🚀 PR was released in |
I made a mistake in #373, instead of not having a top margin between the content if there's no title and no description, it should be no title OR no description. The mistake's effect can see in this chromatic https://www.chromatic.com/test?appId=5a77a6d38a9e3c002045d20d&id=61255022235bb7003aae37f0
before

after
