Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2013-06-21 21:17:07

Absolute
New Member
Registered: 2013-06-16
Posts: 6

Responsive frameworks and their different behaviours

Hello everyone,

This is a strange one that has been puzzling me for a while.
I use two CSS responsive frameworks. Skeleton and Bootstrap

I use Skeleton for smaller sites and wireframes, Bootstrap is my tool for larger projects.

Both of these frameworks present me with an editable CSS file which outlines the various media queries each supports. Here is that section of code on Skeleton:

@media only screen and (max-width: 959px) {}
@media only screen and (min-width: 768px) and (max-width: 959px) {}
@media only screen and (max-width: 767px) {}
@media only screen and (min-width: 480px) and (max-width: 767px) {}
@media only screen and (max-width: 479px) {}

and here it is for Bootstrap:

@media (min-width: 1200px) { ... }
@media (min-width: 768px) and (max-width: 979px) { ... }
@media (max-width: 767px) { ... }
@media (max-width: 480px) { ... }

Both are similar however there is a rather significant different when it comes to adding my styles. With Bootstrap, the styles I add in one media query are seemingly inherited by the media queries that follow it, for example any style change that occurs in the “max-width: 767px” breakpoint are also present in the “max-width: 480px” breakpoint.

The same is not true for Skeleton however. In Skeleton if I make a style change to a div in “max-width: 767px” breakpoint, the style is then reverted to the default when the browser size no longer matches that query. It is as if Skeleton doesnt cascade its CSS? Subsequently, for Skeleton I’m finding that I have to duplicate my code for each media query and I’m sure that’s not right.

If someone can shine any light on this subject that would be great.
Thanks!

Last edited by Absolute (2013-06-21 21:20:34)

Offline

#2 2013-06-22 00:15:04

maniqui
Member
From: Buenos Aires, Argentina
Registered: 2004-10-10
Posts: 3,070
Website

Re: Responsive frameworks and their different behaviours

Hi Absolute,

it seems Bootstrap uses overlapping media queries while Skeleton uses stacked media queries.
You may want to read about them here:
zomigi.com/blog/essential-considerations-for-crafting-quality-media-queries/#mq-overlap-stack


La música ideas portará y siempre continuará

TXP Builders – finely-crafted code, design and txp

Offline

#3 2013-06-22 07:28:44

Absolute
New Member
Registered: 2013-06-16
Posts: 6

Re: Responsive frameworks and their different behaviours

Fantastic! Thank you so much maniqui.

Offline

#4 2013-09-16 09:47:42

Phil_
Member
Registered: 2009-09-21
Posts: 37

Re: Responsive frameworks and their different behaviours

Hi Absolute,

I’m currently trying to make the decision on which of these two frameworks to learn/use.

I’ve seen comments by a few people that they use Skeleton for smaller projects and Bootstrap for larger ones. I was wondering what is the issue with Skeleton that makes you decide to switch to Bootstrap for larger projects. Or is it the fact that Bootstrap is more bloated than Skeleton and you’ll only switch over when the benefits provided by Bootstrap outweigh the disadvantages.

I’d value your insight.

Thanks

Phil

Offline

#5 2013-09-16 10:57:12

philwareham
Core designer
From: Haslemere, Surrey, UK
Registered: 2009-06-11
Posts: 3,564
Website GitHub Mastodon

Re: Responsive frameworks and their different behaviours

Hello Phil,

If talking about site builds for clients, the decision really depends on the cost of the site. If you have a limited budget sometimes it’s easier to use something like the stock Bootstrap to knock something up quickly, though of course the further you stray from Bootstrap’s design the more work is involved (and any customisations would be tricker to maintain if you wanted to stay up-to-date with Bootstrap releases).

Skeleton on the other hand provides only basic building blocks which you can then build upon. Personally I prefer that way of working but means more work in the short term, which maybe the site budgets won’t allow.

Or you can build your own framework over time, like I’ve done, in which you can lift the best bits of other frameworks and leave the bloat out. This is the best solution IMHO.

There are hundreds of frameworks already out there on GitHub, so try a few of them out.

Offline

#6 2013-09-16 22:09:12

tye
Member
From: Pottsville, NSW
Registered: 2005-07-06
Posts: 859
Website

Re: Responsive frameworks and their different behaviours

I’ve been looking at uikit which looks pretty good at first glance, but I haven’t used it in production yet.

It was this comparison table which made me look at it cos I agree with Phil…. there is a whole lot of bloat in some of these frameworks, although in some you don’t have to use it all

Offline

#7 2013-09-17 03:07:19

maniqui
Member
From: Buenos Aires, Argentina
Registered: 2004-10-10
Posts: 3,070
Website

Re: Responsive frameworks and their different behaviours

Nice one, Tye! Really liked it.


La música ideas portará y siempre continuará

TXP Builders – finely-crafted code, design and txp

Offline

#8 2013-09-17 17:16:46

mrdale
Member
From: Walla Walla
Registered: 2004-11-19
Posts: 2,215
Website

Re: Responsive frameworks and their different behaviours

mmm… uikit good. Just the right amount of built in functions without forcing a lot of junk on you.

Last edited by mrdale (2013-09-17 17:26:51)

Offline

#9 2013-09-17 20:38:03

bici
Member
From: vancouver
Registered: 2004-02-24
Posts: 2,075
Website Mastodon

Re: Responsive frameworks and their different behaviours

I have used Phil’s HIVE Framework on two sites now. love it.

But for the third I’ll have to learn to style it / theme it differently ;-)


…. texted postive

Offline

#10 2013-09-19 16:35:29

mrdale
Member
From: Walla Walla
Registered: 2004-11-19
Posts: 2,215
Website

Re: Responsive frameworks and their different behaviours

Yeah, I really like phil’s frameworks too. The trick for me has been to figure out what to use/not. So in order to learn, I’ve been loading the hive front side theme and adapting it.

The problem with learning all this responsive stuff is that I end up inadvertently destroying some intentionally good, mobile based stuff when I bend it visually.

One of these days it’ll click.

Offline

Board footer

Powered by FluxBB