Created
July 20, 2014 03:13
-
-
Save hoodwink73/d5c81506cacc799a82f8 to your computer and use it in GitHub Desktop.
Mixins for creating Ink modules
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mixin container() | |
table.container(class!=attributes.class) | |
tr | |
td | |
if block | |
block | |
mixin row() | |
table.row(class!=attributes.class) | |
tr | |
if block | |
block | |
//- the columns mixin takes in the | |
//- the number of columns and | |
//- the name of the classes(space sepertaed) | |
//- to be applied on the `wrapper` of the column | |
mixin columns(number, wrapperClasses) | |
- var wrapperClasses = wrapperClasses ? wrapperClasses : '' | |
- var columnClass = number + (attributes.visibility ? ' ' + attributes.visibility: '') | |
td.wrapper(class=wrapperClasses) | |
- if (attributes.visibility === "show-for-small") | |
// [if !mso]><!-- | |
table.columns(class!= columnClass) | |
tr | |
if block | |
block | |
td.expander | |
- if (attributes.visibility === "show-for-small") | |
// <![endif] | |
mixin fullWidthRow() | |
+row() | |
td.center(align="center") | |
center | |
+container | |
+columns('tweleve', 'last') | |
if block | |
block | |
td.expander | |
mixin blockGrid(number) | |
- var grid = "block-grid " + number + '-up' | |
table(class=grid) | |
tr | |
if block | |
block | |
mixin button(label) | |
table.button(class!=(attributes.style ? attributes.style : '')) | |
tr | |
td | |
a= label |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment