Jetpack Digital CSS grid.
Jetpack Digital specialises in the design and development of world-class eCommerce websites and service a wide range of clients in a variety of industries.
They had a number of team members creating HTML & CSS and the issue was that it was all different. This became a problem when anyone had to make updates to the existing codebase.
My role
- Scoping requirements
- Research & wireframe
- Website build (HTML & CSS)
Requirements.
- Standardise all naming conventions
- Minimal use of classes/IDs to enable a more efficient workflow
- Render on multiple devices and viewport widths
- Multiple columns layouts had to be supported
- Work all the way back to IE8 – everyone’s favourite browser
<div class="wrapper">
<div class="left">
<h2>Left Column</h2>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit.</p>
</div>
<div class="right">
<h2>Right Column</h2>
<p>In accumsan purus nunc, vitae posuere velit dapibus quis.</p>
</div>
<div class="clear"></div>
</div>
<div class="container2Columns">
<div class="col-1">
<h2>Left Column</h2>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit.</p>
</div>
<div class="col-2">
<h2>Right Column</h2>
<p>In accumsan purus nunc, vitae posuere velit dapibus quis.</p>
</div>
<div class="clear"></div>
</div>
<div class="colCount2">
<div class="colSpan1">
<h2>Left Column</h2>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit.</p>
</div>
<div class="colSpan1">
<h2>Right Column</h2>
<p>In accumsan purus nunc, vitae posuere velit dapibus quis.</p>
</div>
</div>
Solution.
The solution was to create a custom CSS grid which used minimal classes, helping the team quickly create standard webpage layouts.
It went from parent elements like wrapper and container2Columns with children like left, right, col-1 and col-2 to a more fixed solution the guys could implement with enough flexibility to be updated if the need arose.
The third code block is the chosen solution, it goes from 2 columns all the way to to 6 with the option to embed certain ones inside each other.
To keep the file size to a minimum it was decided that every permutation for each column was not required. When clients needed something a bit more custom, the team would implement this.