0

Hi I want to use media query in css in div element to resize it's height according to device. Can anyone send me whole process?

6th Oct 2020, 5:18 PM
Ajay Rai
Ajay Rai - avatar
3 Respostas
+ 2
Ajay Rai try @media screen and (min-width:600px){ div{ height:30vh; } } Will change the div size if screen has a width of 600px and above
6th Oct 2020, 6:12 PM
Abhay
Abhay - avatar
+ 1
Where is your attempt?
6th Oct 2020, 5:21 PM
🇮🇳Vivek🇮🇳
🇮🇳Vivek🇮🇳 - avatar
0
@media on screen and (max-width:600px) { div{ height: 30vh; } } This is reducing my background color
6th Oct 2020, 5:25 PM
Ajay Rai
Ajay Rai - avatar