css media queries
CSS
CSS @media Rule
Example
Change the background color of the <body> element to "lightblue" when the browser window is 600px wide or less:
Syntax
@media only screen and (max-width: 600px) {
body {
background-color: lightblue;
}
}
/*
Extra small devices (phones, 600px and down) */
@media only screen and (max-width: 600px)
{...}
/* Small devices (portrait tablets and large phones, 600px and up)
*/
@media only screen and (min-width: 600px) {...}
/* Medium devices (landscape tablets, 768px and up) */
@media only screen and (min-width: 768px) {...}
/* Large devices (laptops/desktops, 992px and up)
*/
@media only screen and (min-width: 992px) {...}
/* Extra large devices (large
laptops and desktops,
1200px and up) */
@media only screen and (min-width: 1200px) {...} /* Sur les écrans, quand la largeur de la fenêtre fait au maximum 1280px */
@media screen and (max-width: 1280px)
/* Sur tous types d'écran, quand la largeur de la fenêtre est comprise entre 1024px et 1280px */
@media all and (min-width: 1024px) and (max-width: 1280px)
/* Sur les téléviseurs */
@media tv
/* Sur tous types d'écrans orientés verticalement */
@media all and (orientation: portrait)
@media only screen and (max-width: 600px) {
body {
background-color: lightblue;
}
}@media only screen and (max-width: 600px) {
body {
background-color: lightblue;
}@media only screen and (max-width: 1200px){
/*Tablets [601px -> 1200px]*/
}
@media only screen and (max-width: 600px){
/*Big smartphones [426px -> 600px]*/
}
@media only screen and (max-width: 425px){
/*Small smartphones [325px -> 425px]*/
}
Also in CSS:
- Title
- css backdrop filter grayscale
- Category
- CSS
- Title
- background gradient vertical css
- Category
- CSS
- Title
- corona.html:61 Uncaught ReferenceError: $ is not defined
- Category
- CSS
- Title
- js add css to document
- Category
- CSS
- Title
- CKEDITOR PUSH TEXT IN FRONT OF CURSOR
- Category
- CSS
- Title
- text animation css
- Category
- CSS
- Title
- css paragraph ellipsis
- Category
- CSS
- Title
- css light grey
- Category
- CSS
- Title
- not last child css
- Category
- CSS
- Title
- background image with color overlay gradient css
- Category
- CSS
- Title
- how to use visited hover active and visited in css
- Category
- CSS
- Title
- html font white text with black border
- Category
- CSS
- Title
- javascript modify css
- Category
- CSS
- Title
- use PurifyCSS with hugo
- Category
- CSS
- Title
- how to center with position fixed
- Category
- CSS
- Title
- css first of type
- Category
- CSS
- Title
- css select all elements except last css
- Category
- CSS
- Title
- pure css heart
- Category
- CSS
- Title
- affect top div opacity without affecting childrne
- Category
- CSS
- Title
- css scale
- Category
- CSS
- Title
- nth of type for every 4th after the 1st
- Category
- CSS
- Title
- css limit text length
- Category
- CSS
- Title
- for loops in cpp
- Category
- CSS
- Title
- how do i update my gatsby version?
- Category
- CSS
- Title
- style file input button css
- Category
- CSS
- Title
- css gradient text
- Category
- CSS
- Title
- link css file in html
- Category
- CSS
- Title
- bootsrap buttons
- Category
- CSS
- Title
- tab link class in html
- Category
- CSS
- Title
- css :focus
- Category
- CSS
- Title
- flip image css
- Category
- CSS
- Title
- css div vertical center
- Category
- CSS
- Title
- html font size
- Category
- CSS
- Title
- touch scroll css gallery
- Category
- CSS
- Title
- stop the client from scrolling
- Category
- CSS
- Title
- vue import css
- Category
- CSS
- Title
- mettre une image au milieu css
- Category
- CSS
- Title
- Also define the standard property 'transition'
- Category
- CSS
- Title
- css quitar el icono de lista
- Category
- CSS
- Title
- DISABLE the Horizontal Scroll
- Category
- CSS
- Title
- show central part of rectangle image css
- Category
- CSS
- Title
- css label in border
- Category
- CSS
- Title
- css nth child skip first
- Category
- CSS
- Title
- CSS make image fill whole background
- Category
- CSS
- Title
- transparent background css
- Category
- CSS
- Title
- matrix multiplication markdown
- Category
- CSS
- Title
- css grid media queries
- Category
- CSS
- Title
- css navigation bar
- Category
- CSS
- Title
- custom checkbox with image css
- Category
- CSS
- Title
- bootstrap
- Category
- CSS
- Title
- how to get random images
- Category
- CSS
- Title
- overlay in css
- Category
- CSS
- Title
- css first h element
- Category
- CSS
- Title
- css set property with data attribute
- Category
- CSS
- Title
- css circle border
- Category
- CSS
- Title
- access css and js files inside resources folder in laravel
- Category
- CSS
- Title
- how to change button gradient
- Category
- CSS
- Title
- showing danger message in red in terminal bash
- Category
- CSS
- Title
- css transition delay
- Category
- CSS
- Title
- como fazer listrada css
- Category
- CSS
- Title
- css grid gap
- Category
- CSS
- Title
- how can I see my gatsby version
- Category
- CSS
- Title
- media queries les plus utilisees
- Category
- CSS
- Title
- css background attachment
- Category
- CSS
- Title
- textarea scale to content
- Category
- CSS
- Title
- chat bot with a floating button html and css
- Category
- CSS
- Title
- css sticky header with nav bar
- Category
- CSS
- Title
- jest test try catch
- Category
- CSS
- Title
- css in js
- Category
- CSS
- Title
- css grid tutorial
- Category
- CSS
- Title
- select odd child css
- Category
- CSS
- Title
- add css file to html
- Category
- CSS
- Title
- how to margin placeholdr text
- Category
- CSS
- Title
- span size css
- Category
- CSS
- Title
- remove blue border on a input
- Category
- CSS
- Title
- css animation
- Category
- CSS
- Title
- react native tutorial
- Category
- CSS
- Title
- how to center a div in css
- Category
- CSS
- Title
- css center vertically
- Category
- CSS
- Title
- How to prevent anchor links from scrolling behind a sticky header with one line of CSS
- Category
- CSS
- Title
- como botar um separador display flex quebra de linha
- Category
- CSS
- Title
- row class in bootstrap
- Category
- CSS
- Title
- dotted line css
- Category
- CSS
- Title
- how to apply bg image in inline css
- Category
- CSS
- Title
- git clone command in terminal
- Category
- CSS
- Title
- how to apply a transition to a child element when hovering over parent element
- Category
- CSS
- Title
- css rgb color
- Category
- CSS
- Title
- sass to scss
- Category
- CSS
- Title
- add background image css
- Category
- CSS
- Title
- how to create two vertical div in html
- Category
- CSS
- Title
- adding css to html body
- Category
- CSS
- Title
- link css with path
- Category
- CSS
- Title
- how to change hyperlink color in css
- Category
- CSS
- Title
- fade in css
- Category
- CSS
- Title
- ancho maximo css
- Category
- CSS
- Title
- select box arrow hide css in ie
- Category
- CSS
- Title
- xcrun: error: SDK "iphoneos" cannot be located
- Category
- CSS
- Title
- how to add toggle class in javascript using css modules
- Category
- CSS
- Title
- css button no style
- Category
- CSS
- Title
- dont break word css
- Category
- CSS