So I'm Using Materialize http://materializecss.com/grid.html
The problem is when my card can have different sizes and it seems that materialize grid doesn't support that. Here is the exact problem.
Is there any way I can make it more responsive and remove that extra space?
Any reference would do.
Fixed by using this repository http://masonry.desandro.com/
Related
I am looking for a way to make this card stacking effect in react-bootstrap.
I tried following the code in the link but it is quite different that I cannot implement it in react-bootstrap. I want it to be responsive because I use Container fluid with Row and Col.
It does not have to be pure CSS. Javascript usage or a combination of both is acceptable.
Our team already develop a web page using custom div, css and Split.js the to produce the following layout. There are 3 panels in the layout with each panel can be resize (notice the gutters).
Problem is, when using mobile the layout is not responsive - and we still do a lot of r and d for this.
I'm looking for alternative, which is Bootstrap framework. But so far, still don't figure out how to do this. Is there something I miss, or bootstrap is not the right choice?
I know this JQuery Resizable Plugin works for this purpose on mobile:
https://github.com/RickStrahl/jquery-resizable
I built a component for this purpose a while ago. The concept is to split any view (html element) into two, one has a fixed width/height and the other consumes the rest of the parent. If you put an optional divider in between the two views, you are able to drag and drop it to resize.
https://www.npmjs.com/package/split-view
Let me know if it works for your case.
I've wrestled with this for a long time, and ended up resorting to jQuery hacks. I'd really like to know if there is a way to implement this with CSS or LESS (using javascript mixins).
It's essentially a page with assorted fixed and fluid elements.
http://cl.ly/IagL
Any ideas on best practice?
Yes, I see a problem if you want the height of left and right column to be equal with the height of the middle column. If you make the height as a fix height than you can do it, otherwise you need to use jquery.
But if you want to achieve the fluid width, I suggest you to use twitter bootstrap. Their framework support the use of LESS as well http://twitter.github.com/bootstrap/
The middle height is technically impossible with CSS and is a known issue. http://www.dtelepathy.com/blog/telepathy/sometimes-css-cant-do-it-all
I guess I will have to resort to jQuery
I am developing an application where users will be able to open tabs. For your note, I am using the Bootstrap CSS framework, and it has a tab plugin as well. (In case I need a more flexible approach I can use a different library for this job.)
http://twitter.github.com/bootstrap/javascript.html#tabs
What I need is to have a flexible width for tabs. It should work like Chrome/Firefox's tabs. If the collective width of the tabs is less than the width of the bar, it should work as it is is. However if it is longer than the width of the bar, then the size of each tab width should reduce equally. (If you open 10-20 tabs using chrome/firefox, you'll understand what I mean)
Is there any easy way to do this, without using javascript? The only solution that comes up to my mind is to get the inner width of the bar using javascript and get the width of the other tabs and sum them up. If the sum is higher, then I can resize each tab.
I can implement this solution but I fear it will be hard to ensure cross browser compatibility. Is there any easier way to achieve this?
Thanks in advance,
You don't need JavaScript as long as you can rely on a CSS algorithm that adapt width to its content: the table layout algorithm :)
See http://jsfiddle.net/r9yrM/1/ from my previous answer for examples.
Don't forget to have a minimum padding on each "cell", text stuck to a border isn't very readable (and ugly).
With JS, you could decide of a maximum number of tabs (or a minimum "reasonable" width) and above (below) that number, add a class on the parent that will trigger each tab to render as float: left and block and not table-cell anymore. Then it'll occupy 2 or more lines (like the extension Tab Mix Plus on Firefox)
You could adjust the width of nav nav-tabs li elements after they are rendered.
Calculate how many tabs fit in the parent element at their normal size and reduce each tab by a percentage of a single tab width for each tab that exceeds the max number.
I've tried to solve the same problem today... maybe my solution helps you a little more: http://www.da3x.de/blog/flexible-tab-panel-with-overlapping-elements/
It uses HTML + CSS only... no JS so far. But I think I'd need some JS to react on the actual width of the browser window.
Im using jqgrid in my rails project.Using jqgrid in different pages for different recorsd.In one page I need different font size and in another page I need different font size.So here I can not change the css of jqgrid.I need to change the fond size dynamically in my view code.I need to change the header,record and footer fonts.Can any one suggest me the way to do it.
It's not easy. The current code of jqGrid don't use px instead of em. There are options like scrollOffset or cellLayout to be able to fix problems with wrong calculation of column width. So to solve the problem with dynamically font size one have to adjust the width or height of grid and not only to change jqGrid.css. If you don't do this the grid can have unneeded scroll bars.
Shortly I don't recommend you to try to implement dynamic font size in jqGrid because of complexity of the problem. If you do did this it would be good if you share the solution.