New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Custom Download Grid Size not setting? #1778
Comments
Same here, I have tried to set it to 16 but still 12 columns. |
Yup, having this problem too (altough I'm using .less), guess I'll set columnwidths manually until this is resolved. |
Me too! Please solve this...Bootstrap is awesome but it´s kind of dissappointing that something so basic doesn´t work. |
In my experience, the values of .spanN, .offsetN etc. get updated when you set custom values. However, if you set the number of columns to, say, 16, classes for .span13 to .span16 do not get created and must be defined manually. |
Was planning on testing Bootstrap too but if this is not fixed fast I'll have to go for another solution :'( |
I've seen the code here https://github.com/twitter/bootstrap/blob/master/less/mixins.less and it seems that the grid generation is hardcoded. That's ok because less doesn't support loops. But changing from a default of 16 grids to 12 and not allowing to change it back is not cool :( |
Ok so I have this working now. Kind of hackish but I think it's simple enough. After checking out https://github.com/twitter/bootstrap/blob/master/less/mixins.less and https://github.com/twitter/bootstrap/blob/master/less/tables.less I have added (and somehow overrided) the functions that add the grids. This is how I have it working in my project where I'm using My
And it's working for me ;) |
Since LESS doesn't support loops, I wonder if it's possible for the customized download feature to run the stylesheet through a templating system (say, ERB) to generate the appropriate number of columns. Something like this: <% column_count.times do |column| %>
.span<%= column %> { #gridSystem > .columns(@gridGutterWidth, @gridColumnWidth, @gridRowWidth, <%= column %>); }
<% end %> If that's not possible, I think it would be reasonable to include 24 hard-coded column classes by default. I doubt most people will be using over 24 columns anyways. |
I think an issue I am seeing with color properties could be related to this. Issue #1914 |
also, isse #1791 |
experiencing the same problem here. a possible workaround to avoid using loops in any way could be it could be achieved in this way: in
if I use a 24 columns layout this is right. if I specify eg. 16 columns layout in
the classes span17-span24 and offset17-offset24 and generated but not used (not bad), and .container is always right |
Might do the latter, but I'll talk to Jacob to see if we can cook something up for more than 12 columns. |
I tried this and seems working, do you want me to do a PR to evaluate this better? |
@inmarelibero Yeah, let's do that for now. Can you submit a pull request against 2.0.2-wip adding the 13-24 columns for all our grid system mixins (there are three)? I'll close this out when that comes through. It behooves me to say that we don't actually need the last |
cool, I'll do it as soon as possible |
please please do this as soon as possible customizing up to 24 columns was one of the biggest reasons why I loved 1.4 |
@markdotto @srhise you find PR at #2143 |
Closing to punt to the pull request. #2143. |
maybe i'm missing some... but... that worked for me.... |
@brutuscat or anybody, how do you calculate 4.25531915 for 16collumns and 6.382978723% for 12? thank you all. |
When I change the @gridColumns value to 10 here: http://twitter.github.com/bootstrap/download.html and download, it seems to keep the 12 column setting?
Thanks!
The text was updated successfully, but these errors were encountered: