Closed huyenltnguyen closed 2 months ago
Excuse me, I have a silly question. How do I test my solution?
You can run pnpm storybook
, access the Storybook page at localhost:6006
, find the Dropdown component and check if it has the expected styles.
I don't seem to have everything I need installed to run Storybook though. Where can I get it?
That's strange.
I'm sorry if this is too obvious, but did you run pnpm i
after cloning the repo / before running pnpm storybook
?
Yes. And I am also using pnpm version 9.1.2 if that helps.
And node v20.13.1
I didn't see those addons listed in package.json directly either, but it's fairly probably that it must have been bundled with something else.
Description
The
Button
component has a top margin of 0.5px whileDropdown
doesn't. When Button and Dropdown are used together:Page tested: https://www.freecodecamp.org/learn/javascript-algorithms-and-data-structures/basic-javascript/comment-your-javascript-code
Changes needed
To address the issue, I think
Dropdown
should have a 0.5px top margin.Though we might want to revisit this in the future,
Button
orDropdown
probably shouldn't have any margin, and their parent should be responsible for the layout (ref #13).