Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save directionforward/86096f1e22cb0dd40f8db4b2e4e6a498 to your computer and use it in GitHub Desktop.
Save directionforward/86096f1e22cb0dd40f8db4b2e4e6a498 to your computer and use it in GitHub Desktop.
Squarespace Breakpoints.
/**
Squarespace essentially doesn't really document their breakpoints.
This can be quite annoying to not have when doing custom CSS.
Most themes use essentially one breakpoint. Mobile and not mobile; anything 750 and below is considered mobile.
You can use these to write your own CSS and simply use the "Style Editor" to inject your compiled CSS in the event
you are not using "Developer Mode" in your site.
Enjoy!
*/
@mobile: ~"only screen and (max-width: 750px)";
@tablet: ~"only screen and (min-width: 751px)";
@tablet-strict: ~"only screen and (min-width: 751px) and (max-width: 949px)";
@tablet-desktop: ~"only screen and (min-width: 751px)";
@desktop: ~"only screen and (min-width: 950px)";
@desktop-strict: ~"only screen and (min-width: 950px) and (max-width: 1199px)";
@desktop-xl: ~"only screen and (min-width: 1200px)";
// Usage
@media @mobile {
// Code here
}
@media @tablet-strict {
// Code here
}
@media @desktop {
// Code here
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment