V
V
Vladimir2015-03-02 16:41:04
Drupal
Vladimir, 2015-03-02 16:41:04

What is "Zen Grids" and how to use it?

I'm coding Zen based themes and recently came across the Zen Grids website and I'd like to know how to use it. It’s not particularly clear on the site what’s what, or I’m stupid, as I understand it, grids are needed for an even arrangement of blocks, but how to use all this? I understand that you need to do something through the compass?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexey, 2015-03-03
@seoyuzer

Zen Grid uses Sass and Compass
Grids are needed not only for even block layout, but also for creating responsive designs.
How to use it? Write classes for blocks and style them with Zen Grid methods. For example like this:

@import "zen"; // Импортируем 
$zen-column-count: 7; // Указываем количество колонок
$zen-gutter-width: 10px; // Указываем ширину отступов между колонками.

.content {
 @include zen-grid-item(4, 3); // Для региона с классом контент указываем что он должен занимать 4 колонки и распологаться начиная с третьей.
}

In the future, we get an adaptive layout without much effort. The width of the region will automatically change depending on the width of the browser window. The location of the regions is the same. Well, in general, go ahead and google what is adaptive layout.
If I'm wrong about something, I think they will correct me in the comments.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question