Breakpoints are where media queries separate. Declared values or maximums
xs
- framework var:
$br-xs-max - Larger Mobile Devices (767px by default)
sm
- framework var:
$br-sm-max - Tablet (1199px by default)
md
- framework var:
$br-md-max - Laptop (1599px by default)
lg
- framework var:
$br-lg-max - Laptop (1799px by default)
- For large laptop/desktop elements. Since it's the largest breakpoint, it does not have a max value, instead it's minimum is based on md breakpoints value
xxs
- framework var:
$br-xxs-max - True Mobile (0px - 400px by default)
- UI Design may have elements designed too large for many mobile devices. use this to fix or tweak them. This breakpoint is for adding custom css for the framework and is not natively by the core framework's styles although used at some places by js bois.
xl
- framework var:
$br-xxs-max - HD (1800px+ based on
$br-lg-maxset value by default) - very very very large viewports. AAAAAAAAAAAAAAAAA
$mobile-br-max
- Defaults to
sm - declares which breakpoint tag the mobile and nonmobile devices split. The set tag will be the maximum width for framework mobile styles.
$mobile-br-max-polaris calculated based on this value
defaults to nonmobile. valid value is either nonmobile or mobile. generates media queries for styles
NOTE:Since the shithole library is built mobile first, Declared framework sass variable values are set as the maximum value of these breakpoints, but using their tags with shithole functionalities will be interpretted as the corresponding min value of the breakpoint.
create media queries based on mobile split
- @param $mobile-tag: 'nonmobile' !default | string | device to use. only takes
mobileornonmobile
@include on-breakpoint(mobile) {
//styles for mobile devices
}If you use shithole mixins or functions and want to use these max values append -max to the tags
@include breakpoint(sm-max) {
//styles for tablet and below heeere
}create media queries
- @param $br: () !default | (list / string) | breakpoint duh. accepts string of condition or breakpoint tag
- @param $media: '' !default | (list / string) | the mediatype
- @param $use-only: false !default | (boolean) | add
onlyto the query - @param $operator: and !default | (string) | operator to use between list $br
- @content: styles for the breakpoint
- @return: declared @content wrapped in breakpoint
Examples:
@include breakpoint(lg) {
//styles for desktop and above
}@include breakpoint(md, md-max) {
//styles for desktop and above
}shorter way of including breakpoint()
Advanced cousin of breakpoint. Accepts other values aside from the breakpoints but also translates instances of breakpoint tags with it
Example:
@include media('md and md-max, max-width: 420px') {
//styles for whatever breakpoint that is
}