New course! Every coder should learn Generative AI!
Try a free lesson0
what i am doing wrong?
``` question SPAN elements within the data-cart-info DIV should be displayed as inline block elements, and vertical-align set to middle. The .material-icons SPAN should have a 150 pixels size of font. html code <body> <div data-cart-info> <heading class ="mdc-typography--headline4"> <span class="material-icons"> shopping_cart </span> <span data-bill> </span> </heading> </div> css code style> body { margin: 0; padding: 1em; background-color: white; } span[data-cart-info]{ vertical-align: middle; }, [data-credit-card] { transform: scale(0.78); margin-left: -3.4em; } .material-icons span { font-size: 150px; } ```
8 Answers
+ 3
?? It doesn't worked ??
+ 2
The problem is : . material-icons span. It should be span. material-icons or only . material-icons. Another one: you've used span[data-cart-info], which is actually div[data-cart-info]
+ 2
It did not. please any pointers as it not helping me move forward in a challenge I am solving
+ 1
``` this is how i edited the code
<style>
body {
margin: 0;
padding: 1em;
background-color: white;
}
.material-icon {
font-size: 150px;
}
div [data-cart-info] {
vertical-align: middle;
},
```
+ 1
The below snippet should be helpful
[data-cart-info] span {
display: inline-block;
vertical-align: middle;
}
0
Thanks . It has not changed still giving errors
0
Hi sherrif salam, please have you found the answer to the span elements css display stuff? I need help with the same issue. -->> The SPAN elements within the "data-cart-info" DIV do not have the required CSS style
0
Try writing <h4 class ="mdc-typography--headline4"> <span class="material-icons"> shopping_cart </span> <span data-bill> </span> </h4>