I am having trouble on step 74 of building a cafe menu. The problem is as follows along with my answer.
Problem:
Focusing on the menu items and prices, there is a fairly large gap between each line.
Target all the p elements nested in elements with the class named item and set their top and bottom margin to be 5px.
Answer:
.item p {
margin-top: 5px;
margin-bottom: 5px;
}
I’ve edited your post for readability. When you enter a code block into a forum post, please precede it with a separate line of three backticks and follow it with a separate line of three backticks to make it easier to read.
You can also use the “preformatted text” tool in the editor (</>) to add backticks around text.
See this post to find the backtick on your keyboard.
Note: Backticks (`) are not single quotes (’).
bro u need to learn this; example
- margin: 1px 2px 3px 4px; means values of( top,right,bottom,left)
- margin: 2px 0; means top and bottom have value of 2px and right and left have value of 0
Thank you for sharing this with me!