Search
 
SCRIPT & CODE EXAMPLE
 

CSS

scss media query

/* Using SCSS variables to store breakpoints */
$breakpoint-tablet: 768px;
@media (min-width: $breakpoint-tablet) {
  
}
Comment

media query in scss

$size__site_content_width: 1024px;

/* Media Queries */ Not necessarily correct, edit these at will 
$media_queries : (
    'mobile'    : "only screen and (max-width: 667px)",
    'tablet'    : "only screen and (min-width: 668px) and (max-width: $size__site_content_width)",
    'desktop'   : "only screen and (min-width: ($size__site_content_width + 1))",
    'retina2'   : "only screen and (-webkit-min-device-pixel-ratio: 2) and (min-resolution: 192dpi)",
    'retina3'   : "only screen and (-webkit-min-device-pixel-ratio: 3) and (min-resolution: 288dpi)",
    'landscape' : "screen and (orientation:landscape) ",    
    'portrait'  : "screen and (orientation:portrait) "
);

@mixin for_breakpoint($breakpoints) {
    $conditions : ();
    @each $breakpoint in $breakpoints {
        // If the key exists in the map
        $conditions: append(
            $conditions,
            #{inspect(map-get($media_queries, $breakpoint))},
            comma
        );
    }

    @media #{$conditions} {
        @content;
    }

}
Comment

PREVIOUS NEXT
Code Example
Css :: select2 make previously selected options non deletable 
Css :: skeumorphism box shadow 
Css :: centrar imagen flexbox 
Css :: css font size 
Css :: web3 button style 
Css :: boostarp grid npm css react 
Css :: How to replace broken image CSS? 
Css :: how to display a header in the center of the column in css 
Css :: radio check mark color 
Css :: add image icon to button css 
Css :: css class for table 
Css :: scss include 
Css :: highchart font family 
Css :: media query change button text 
Css :: fade div 
Css :: page rotate css 
Css :: laravel 7 css not working 
Css :: flex box in css 
Css :: height current -3px css 
Css :: css nested scrollbars 
Css :: interfaces in golang 
Css :: css colors 
Css :: css make a cell twice as big flexbox 
Css :: css after before 
Css :: circle progress bar css 
Css :: flex item: 1; 
Css :: auto enable background graphics print settings 
Css :: making a div vertically scrollable using css 
Css :: Creating Nike logo with CSS 
Css :: Understanding ' sign in css selector 
ADD CONTENT
Topic
Content
Source link
Name
7+2 =