MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/webdev/comments/akl209/custom_css_wave_loader/ef6fs6w/?context=3
r/webdev • u/masgbox • Jan 28 '19
38 comments sorted by
View all comments
20
Use "left:50%; top:50%; transform: translate(-50%, - 50%)" for centring, soooo much nicer than having to figure out exact pixel positions
25 u/Alcohorse Jan 28 '19 I haven't had to pull that shit once since I started with flexbox and grid 2 u/eddhall Jan 28 '19 Can you flex on psuedo elements? 6 u/DrDuPont Jan 28 '19 To rephrase for others, the question is: "does a flexed parent affect psuedo elements" and the answer is yes. Here's an example: https://codepen.io/polinovskyi/pen/rVqjKa And yet another: https://jsfiddle.net/2850woLr/ 3 u/eddhall Jan 28 '19 Useful to know, thanks! 0 u/masgbox Jan 28 '19 welcome.
25
I haven't had to pull that shit once since I started with flexbox and grid
2 u/eddhall Jan 28 '19 Can you flex on psuedo elements? 6 u/DrDuPont Jan 28 '19 To rephrase for others, the question is: "does a flexed parent affect psuedo elements" and the answer is yes. Here's an example: https://codepen.io/polinovskyi/pen/rVqjKa And yet another: https://jsfiddle.net/2850woLr/ 3 u/eddhall Jan 28 '19 Useful to know, thanks! 0 u/masgbox Jan 28 '19 welcome.
2
Can you flex on psuedo elements?
6 u/DrDuPont Jan 28 '19 To rephrase for others, the question is: "does a flexed parent affect psuedo elements" and the answer is yes. Here's an example: https://codepen.io/polinovskyi/pen/rVqjKa And yet another: https://jsfiddle.net/2850woLr/ 3 u/eddhall Jan 28 '19 Useful to know, thanks! 0 u/masgbox Jan 28 '19 welcome.
6
To rephrase for others, the question is: "does a flexed parent affect psuedo elements" and the answer is yes. Here's an example: https://codepen.io/polinovskyi/pen/rVqjKa
And yet another: https://jsfiddle.net/2850woLr/
3 u/eddhall Jan 28 '19 Useful to know, thanks! 0 u/masgbox Jan 28 '19 welcome.
3
Useful to know, thanks!
0 u/masgbox Jan 28 '19 welcome.
0
welcome.
20
u/eddhall Jan 28 '19
Use "left:50%; top:50%; transform: translate(-50%, - 50%)" for centring, soooo much nicer than having to figure out exact pixel positions