chriseppstein-compass 0.1.1 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/Manifest +6 -3
- data/VERSION +1 -1
- data/compass.gemspec +3 -3
- data/examples/blueprint_default/stylesheets/ie.sass +1 -2
- data/examples/blueprint_default/stylesheets/print.sass +1 -2
- data/examples/blueprint_default/stylesheets/screen.sass +4 -5
- data/examples/blueprint_plugins/stylesheets/ie.sass +1 -2
- data/examples/blueprint_plugins/stylesheets/print.sass +1 -2
- data/examples/blueprint_plugins/stylesheets/screen.sass +6 -6
- data/examples/blueprint_scoped/stylesheets/ie.sass +1 -2
- data/examples/blueprint_scoped/stylesheets/print.sass +1 -2
- data/examples/blueprint_scoped/stylesheets/screen.sass +1 -2
- data/examples/blueprint_scoped_form/stylesheets/ie.sass +1 -2
- data/examples/blueprint_scoped_form/stylesheets/print.sass +1 -2
- data/examples/blueprint_scoped_form/stylesheets/screen.sass +7 -6
- data/examples/blueprint_semantic/stylesheets/ie.sass +1 -2
- data/examples/blueprint_semantic/stylesheets/liquid.sass +3 -3
- data/examples/blueprint_semantic/stylesheets/print.sass +1 -2
- data/examples/blueprint_semantic/stylesheets/screen.sass +5 -5
- data/frameworks/blueprint/stylesheets/blueprint/_ie.sass +36 -6
- data/frameworks/blueprint/stylesheets/blueprint/_print.sass +44 -31
- data/frameworks/blueprint/stylesheets/blueprint/_screen.sass +2 -2
- data/frameworks/blueprint/stylesheets/blueprint/modules/_colors.sass +25 -20
- data/frameworks/blueprint/stylesheets/blueprint/modules/_debug.sass +3 -3
- data/frameworks/blueprint/stylesheets/blueprint/modules/_fancy_type.sass +20 -24
- data/frameworks/blueprint/stylesheets/blueprint/modules/_grid.sass +52 -51
- data/frameworks/blueprint/stylesheets/blueprint/modules/_interaction.sass +37 -34
- data/frameworks/blueprint/stylesheets/blueprint/modules/_liquid.sass +46 -49
- data/frameworks/blueprint/stylesheets/blueprint/modules/_scaffolding.sass +36 -19
- data/frameworks/blueprint/stylesheets/blueprint/modules/_typography.sass +24 -2
- data/frameworks/blueprint/stylesheets/blueprint/modules/_utilities.sass +0 -2
- data/frameworks/blueprint/templates/project/ie.sass +1 -2
- data/frameworks/blueprint/templates/project/print.sass +1 -2
- data/frameworks/blueprint/templates/project/screen.sass +4 -5
- data/frameworks/compass/stylesheets/compass/utilities/_print.sass +24 -0
- data/test/compass_test.rb +7 -6
- data/test/fixtures/stylesheets/blueprint/css/typography.css +158 -0
- data/test/fixtures/stylesheets/{default → blueprint}/sass/ie.sass +1 -2
- data/test/fixtures/stylesheets/{default → blueprint}/sass/print.sass +1 -2
- data/test/fixtures/stylesheets/blueprint/sass/screen.sass +17 -0
- data/test/fixtures/stylesheets/blueprint/sass/typography.sass +3 -0
- metadata +8 -5
- data/test/fixtures/stylesheets/default/sass/screen.sass +0 -18
@@ -2,10 +2,19 @@
|
|
2
2
|
To install the fancy type plugin:
|
3
3
|
1. import the fancy_type module:
|
4
4
|
@import blueprint/modules/fancy_type
|
5
|
-
2. mixin +fancy-type to your project's body:
|
5
|
+
2. mixin +fancy-type to your project's body or at the top level of your stylesheet:
|
6
6
|
body
|
7
7
|
+fancy-type
|
8
8
|
|
9
|
+
=fancy-type
|
10
|
+
+fancy-paragraphs
|
11
|
+
.caps
|
12
|
+
+caps
|
13
|
+
.dquo
|
14
|
+
+dquo
|
15
|
+
.alt
|
16
|
+
+alt
|
17
|
+
|
9
18
|
/* Indentation instead of line shifts for sibling paragraphs. Mixin to a style like p + p
|
10
19
|
=sibling-indentation
|
11
20
|
:text-indent 2em
|
@@ -30,8 +39,8 @@
|
|
30
39
|
<span class="dquo">“</span>asdf”
|
31
40
|
(That is, when the title starts with a quote mark).
|
32
41
|
(You may have to change this value depending on your font size).
|
33
|
-
=dquo
|
34
|
-
:margin-left
|
42
|
+
=dquo(!offset = 0.5em)
|
43
|
+
:margin-left -!offset
|
35
44
|
|
36
45
|
/*
|
37
46
|
Reduced size type with incremental leading
|
@@ -40,20 +49,16 @@
|
|
40
49
|
This could be used for side notes. For smaller type, you don't necessarily want to
|
41
50
|
follow the 1.5x vertical rhythm -- the line-height is too much.
|
42
51
|
|
43
|
-
Using this
|
52
|
+
Using this mixin, reduces your font size and line-height so that for
|
44
53
|
every four lines of normal sized type, there is five lines of the sidenote. eg:
|
45
54
|
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
14.4px / 10px = 1.44 (new line height in em's)
|
54
|
-
=incr
|
55
|
-
:font-size 10px
|
56
|
-
:line-height 1.44em
|
55
|
+
Arguments:
|
56
|
+
font_size - The desired font size in pixels. This will be converted to ems for you. Defaults to 10px.
|
57
|
+
base_font_size - The base font size in pixels. Defaults to 12px
|
58
|
+
old_line_height - The old line height. Defaults to 1.5 times the base_font_size
|
59
|
+
=incr(!font_size = 10px, !base_font_size = 12px, !old_line_height = !base_font_size * 1.5)
|
60
|
+
:font-size= 1em * !font_size / !base_font_size
|
61
|
+
:line-height= 1em * !old_line_height / !font_size * 4 / 5
|
57
62
|
:margin-bottom 1.5em
|
58
63
|
|
59
64
|
/*
|
@@ -74,12 +79,3 @@
|
|
74
79
|
p.incr,
|
75
80
|
.incr p
|
76
81
|
+incr
|
77
|
-
|
78
|
-
=fancy-type
|
79
|
-
+fancy-paragraphs
|
80
|
-
.caps
|
81
|
-
+caps
|
82
|
-
.dquo
|
83
|
-
+dquo
|
84
|
-
.alt
|
85
|
-
+alt
|
@@ -17,20 +17,52 @@
|
|
17
17
|
|
18
18
|
@import compass/utilities/general/clearfix.sass
|
19
19
|
|
20
|
-
// Main layout grid,
|
21
|
-
!
|
22
|
-
!
|
23
|
-
!
|
20
|
+
// Main layout grid, override these constants to build your grid and container sizes.
|
21
|
+
!blueprint_grid_columns ||= 24
|
22
|
+
!blueprint_grid_width ||= 30px
|
23
|
+
!blueprint_grid_margin ||= 10px
|
24
|
+
|
25
|
+
!blueprint_grid_outer_width = !blueprint_grid_width + !blueprint_grid_margin
|
26
|
+
!blueprint_container_size = !blueprint_grid_outer_width * !blueprint_grid_columns - !blueprint_grid_margin
|
27
|
+
|
28
|
+
|
29
|
+
=blueprint-grid
|
30
|
+
// A container should group all your columns
|
31
|
+
.container
|
32
|
+
+container
|
33
|
+
// Use these classes (or mixins) to set the width of a column.
|
34
|
+
@for !n from 1 to !blueprint_grid_columns + 1
|
35
|
+
.span-#{!n}
|
36
|
+
+span(!n)
|
37
|
+
div
|
38
|
+
&.span-#{!n}
|
39
|
+
+column(!n, !n == !blueprint_grid_columns)
|
40
|
+
// The last column in a row needs this class (or mixin) or it will end up on the next row.
|
41
|
+
div.last
|
42
|
+
+last
|
43
|
+
// Add these to a column to append empty cols.
|
44
|
+
@for !n from 1 to !blueprint_grid_columns
|
45
|
+
.append-#{!n}
|
46
|
+
+append(!n)
|
47
|
+
// Add these to a column to prepend empty cols.
|
48
|
+
@for !n from 1 to !blueprint_grid_columns
|
49
|
+
.prepend-#{!n}
|
50
|
+
+prepend(!n)
|
51
|
+
// Use these classes on an element to push it into the
|
52
|
+
// next column, or to pull it into the previous column.
|
53
|
+
@for !n from 1 to !blueprint_grid_columns + 1
|
54
|
+
.pull-#{!n}
|
55
|
+
+pull(!n)
|
56
|
+
@for !n from 1 to !blueprint_grid_columns + 1
|
57
|
+
.push-#{!n}
|
58
|
+
+push(!n)
|
24
59
|
|
25
|
-
// Do not edit below this line unless you really know what you're doing.
|
26
|
-
!layout_grid_outer_width = !layout_grid_width + !layout_grid_margin
|
27
|
-
!layout_grid_size = !layout_grid_width * !layout_grid_columns + (!layout_grid_margin * (!layout_grid_columns - 1))
|
28
60
|
|
29
61
|
// Columns
|
30
62
|
// Note: If you use this mixin without the class and want to support ie6
|
31
63
|
// you must set text-align left on your container element in an IE stylesheet.
|
32
64
|
=container
|
33
|
-
:width = !
|
65
|
+
:width = !blueprint_container_size
|
34
66
|
:margin 0 auto
|
35
67
|
+clearfix
|
36
68
|
|
@@ -41,7 +73,7 @@
|
|
41
73
|
:right 0
|
42
74
|
|
43
75
|
=span(!n)
|
44
|
-
:width = !
|
76
|
+
:width = !blueprint_grid_width * !n + (!blueprint_grid_margin * (!n - 1))
|
45
77
|
|
46
78
|
// Use this mixins to set the width of n columns.
|
47
79
|
=column(!n, !last = false)
|
@@ -50,24 +82,24 @@
|
|
50
82
|
@if !last
|
51
83
|
+last
|
52
84
|
@else
|
53
|
-
:margin-right = !
|
85
|
+
:margin-right = !blueprint_grid_margin
|
54
86
|
|
55
87
|
// Mixin to a column to append n empty cols.
|
56
88
|
=append(!n)
|
57
|
-
:padding-right = (!
|
89
|
+
:padding-right = (!blueprint_grid_outer_width) * !n
|
58
90
|
|
59
91
|
// Mixin to a column to prepend n empty cols.
|
60
92
|
=prepend(!n)
|
61
|
-
:padding-left = (!
|
93
|
+
:padding-left = (!blueprint_grid_outer_width) * !n
|
62
94
|
|
63
95
|
// mixin to a column to move it n columns to the left
|
64
96
|
=pull(!n, !last = false)
|
65
97
|
:float left
|
66
98
|
:position relative
|
67
99
|
@if !last
|
68
|
-
:margin-left = (-!
|
100
|
+
:margin-left = (-!blueprint_grid_outer_width * !n) + !blueprint_grid_margin
|
69
101
|
@else
|
70
|
-
:margin-left = -!
|
102
|
+
:margin-left = -!blueprint_grid_outer_width * !n
|
71
103
|
|
72
104
|
// mixin to a column to push it n columns to the right
|
73
105
|
=push(!n)
|
@@ -75,20 +107,20 @@
|
|
75
107
|
:position relative
|
76
108
|
:margin
|
77
109
|
:top 0
|
78
|
-
:right = -!
|
110
|
+
:right = -!blueprint_grid_outer_width * !n
|
79
111
|
:bottom 1.5em
|
80
|
-
:left = !
|
112
|
+
:left = !blueprint_grid_outer_width * !n
|
81
113
|
|
82
114
|
// Border on right hand side of a column.
|
83
115
|
=border
|
84
|
-
:padding-right = !
|
85
|
-
:margin-right = !
|
116
|
+
:padding-right = !blueprint_grid_margin / 2 - 1
|
117
|
+
:margin-right = !blueprint_grid_margin / 2
|
86
118
|
:border-right 1px solid #eee
|
87
119
|
|
88
120
|
// Border with more whitespace, spans one column.
|
89
121
|
=colborder
|
90
|
-
:padding-right= !
|
91
|
-
:margin-right= !
|
122
|
+
:padding-right= !blueprint_grid_width - 0.5 * !blueprint_grid_margin - 1
|
123
|
+
:margin-right= !blueprint_grid_width - 0.5 * !blueprint_grid_margin
|
92
124
|
:border-right 1px solid #eee
|
93
125
|
|
94
126
|
// Mixin this to an hr to make a horizontal ruler across a column.
|
@@ -107,34 +139,3 @@
|
|
107
139
|
+colruler
|
108
140
|
:background #fff
|
109
141
|
:color #fff
|
110
|
-
|
111
|
-
=blueprint-grid
|
112
|
-
// A container should group all your columns
|
113
|
-
.container
|
114
|
-
+container
|
115
|
-
// Use these classes (or mixins) to set the width of a column.
|
116
|
-
@for !n from 1 to !layout_grid_columns + 1
|
117
|
-
.span-#{!n}
|
118
|
-
+span(!n)
|
119
|
-
div
|
120
|
-
&.span-#{!n}
|
121
|
-
+column(!n, !n == !layout_grid_columns)
|
122
|
-
// The last column in a row needs this class (or mixin) or it will end up on the next row.
|
123
|
-
div.last
|
124
|
-
+last
|
125
|
-
// Add these to a column to append empty cols.
|
126
|
-
@for !n from 1 to !layout_grid_columns
|
127
|
-
.append-#{!n}
|
128
|
-
+append(!n)
|
129
|
-
// Add these to a column to prepend empty cols.
|
130
|
-
@for !n from 1 to !layout_grid_columns
|
131
|
-
.prepend-#{!n}
|
132
|
-
+prepend(!n)
|
133
|
-
// Use these classes on an element to push it into the
|
134
|
-
// next column, or to pull it into the previous column.
|
135
|
-
@for !n from 1 to !layout_grid_columns + 1
|
136
|
-
.pull-#{!n}
|
137
|
-
+pull(!n)
|
138
|
-
@for !n from 1 to !layout_grid_columns + 1
|
139
|
-
.push-#{!n}
|
140
|
-
+push(!n)
|
@@ -1,55 +1,58 @@
|
|
1
|
+
@import colors.sass
|
2
|
+
|
3
|
+
|
4
|
+
=blueprint-interaction
|
5
|
+
.error
|
6
|
+
+error
|
7
|
+
.notice
|
8
|
+
+notice
|
9
|
+
.success
|
10
|
+
+success
|
11
|
+
.hide
|
12
|
+
:display none
|
13
|
+
.highlight
|
14
|
+
+highlight
|
15
|
+
.added
|
16
|
+
+added
|
17
|
+
.removed
|
18
|
+
+removed
|
19
|
+
|
1
20
|
=feedback-base
|
2
21
|
:padding .8em
|
3
22
|
:margin-bottom 1em
|
4
|
-
:border 2px solid
|
23
|
+
:border= 2px solid !feedback_border_color
|
5
24
|
|
6
25
|
=error
|
7
26
|
+feedback-base
|
8
|
-
:background= !error_bg_color
|
9
|
-
:color= !error_color
|
10
|
-
:border-color= !error_border_color
|
27
|
+
:background = !error_bg_color
|
28
|
+
:color = !error_color
|
29
|
+
:border-color = !error_border_color
|
11
30
|
a
|
12
|
-
:color= !error_color
|
31
|
+
:color = !error_color
|
13
32
|
|
14
33
|
=notice
|
15
34
|
+feedback-base
|
16
|
-
:background= !notice_bg_color
|
17
|
-
:color= !notice_color
|
18
|
-
:border-color= !notice_border_color
|
35
|
+
:background = !notice_bg_color
|
36
|
+
:color = !notice_color
|
37
|
+
:border-color = !notice_border_color
|
19
38
|
a
|
20
|
-
:color= !notice_color
|
39
|
+
:color = !notice_color
|
21
40
|
|
22
41
|
=success
|
23
42
|
+feedback-base
|
24
|
-
:background= !success_bg_color
|
25
|
-
:color= !success_color
|
26
|
-
:border-color= !success_border_color
|
43
|
+
:background = !success_bg_color
|
44
|
+
:color = !success_color
|
45
|
+
:border-color = !success_border_color
|
27
46
|
a
|
28
|
-
:color= !success_color
|
47
|
+
:color = !success_color
|
29
48
|
|
30
49
|
=highlight
|
31
|
-
:background
|
50
|
+
:background = !highlight_color
|
32
51
|
|
33
52
|
=added
|
34
|
-
:background
|
35
|
-
:color
|
53
|
+
:background = !added_bg_color
|
54
|
+
:color = !added_color
|
36
55
|
|
37
56
|
=removed
|
38
|
-
:background
|
39
|
-
:color
|
40
|
-
|
41
|
-
=blueprint-interaction
|
42
|
-
.error
|
43
|
-
+error
|
44
|
-
.notice
|
45
|
-
+notice
|
46
|
-
.success
|
47
|
-
+success
|
48
|
-
.hide
|
49
|
-
:display none
|
50
|
-
.highlight
|
51
|
-
+highlight
|
52
|
-
.added
|
53
|
-
+added
|
54
|
-
.removed
|
55
|
-
+removed
|
57
|
+
:background = !removed_bg_color
|
58
|
+
:color = !removed_color
|
@@ -33,28 +33,56 @@
|
|
33
33
|
|
34
34
|
@import compass/utilities/general/clearfix.sass
|
35
35
|
|
36
|
-
// Main layout grid,
|
36
|
+
// Main layout grid, override these constants to build your grid and container sizes.
|
37
37
|
// The width shown gives the right floored percentage values.
|
38
|
-
!
|
39
|
-
!
|
40
|
-
!
|
38
|
+
!blueprint_liquid_grid_columns ||= 24
|
39
|
+
!blueprint_liquid_grid_width ||= 4.173%
|
40
|
+
!blueprint_liquid_grid_margin ||= 0.833em
|
41
41
|
|
42
42
|
// Do not edit below this line unless you really know what you're doing.
|
43
|
-
!
|
44
|
-
!
|
45
|
-
!
|
43
|
+
!blueprint_liquid_container_width = 80%
|
44
|
+
!blueprint_liquid_container_min_width = 950px
|
45
|
+
!blueprint_liquid_grid_push_pull = -(!blueprint_liquid_grid_margin * 4)
|
46
46
|
|
47
|
-
=
|
48
|
-
|
47
|
+
=blueprint-liquid-grid
|
48
|
+
// A container should group all your columns
|
49
|
+
.container
|
50
|
+
+container
|
51
|
+
// Use these classes (or mixins) to set the width of a column.
|
52
|
+
@for !n from 1 to !blueprint_liquid_grid_columns + 1
|
53
|
+
.span-#{!n}
|
54
|
+
+span(!n)
|
55
|
+
div
|
56
|
+
&.span-#{!n}
|
57
|
+
+column(!n, !n == !blueprint_liquid_grid_columns)
|
58
|
+
// The last column in a row needs this class (or mixin) or it will end up on the next row.
|
59
|
+
div.last
|
60
|
+
+last
|
61
|
+
// Add these to a column to append empty cols.
|
62
|
+
@for !n from 1 to !blueprint_liquid_grid_columns
|
63
|
+
.append-#{!n}
|
64
|
+
+append(!n)
|
65
|
+
// Add these to a column to prepend empty cols.
|
66
|
+
@for !n from 1 to !blueprint_liquid_grid_columns
|
67
|
+
.prepend-#{!n}
|
68
|
+
+prepend(!n)
|
69
|
+
// Use these classes on an element to push it into the
|
70
|
+
// next column, or to pull it into the previous column.
|
71
|
+
@for !n from 1 to !blueprint_liquid_grid_columns + 1
|
72
|
+
.pull-#{!n}
|
73
|
+
+pull(!n)
|
74
|
+
@for !n from 1 to !blueprint_liquid_grid_columns + 1
|
75
|
+
.push-#{!n}
|
76
|
+
+push(!n)
|
49
77
|
|
50
78
|
=container
|
51
|
-
:min-width= !
|
52
|
-
:width = !
|
79
|
+
:min-width= !blueprint_liquid_container_min_width
|
80
|
+
:width = !blueprint_liquid_container_width
|
53
81
|
:margin 0 auto
|
54
|
-
+
|
82
|
+
+clearfix
|
55
83
|
|
56
84
|
=span(!n)
|
57
|
-
:width= (!
|
85
|
+
:width= (!blueprint_liquid_grid_width * !n) - ((!blueprint_liquid_grid_width * !n) % 1)
|
58
86
|
|
59
87
|
=last
|
60
88
|
:margin-right 0
|
@@ -66,23 +94,23 @@
|
|
66
94
|
@if !last
|
67
95
|
+last
|
68
96
|
@else
|
69
|
-
:margin-right = !
|
97
|
+
:margin-right = !blueprint_liquid_grid_margin
|
70
98
|
|
71
99
|
=append(!n)
|
72
|
-
:padding-right= (!
|
100
|
+
:padding-right= (!blueprint_liquid_grid_width * !n) - ((!blueprint_liquid_grid_width * !n) % 1)
|
73
101
|
|
74
102
|
=prepend(!n)
|
75
|
-
:padding-left= (!
|
103
|
+
:padding-left= (!blueprint_liquid_grid_width * !n) - ((!blueprint_liquid_grid_width * !n) % 1)
|
76
104
|
|
77
105
|
=pull(!n, !last = false)
|
78
|
-
:margin-left= (!
|
106
|
+
:margin-left= (!blueprint_liquid_grid_push_pull * !n)
|
79
107
|
|
80
108
|
=push(!n)
|
81
109
|
:float right
|
82
110
|
:margin
|
83
111
|
:top 0
|
84
112
|
:left 1.5em
|
85
|
-
:right= (!
|
113
|
+
:right= (!blueprint_liquid_grid_push_pull * !n)
|
86
114
|
:bottom 0
|
87
115
|
|
88
116
|
=border
|
@@ -107,34 +135,3 @@
|
|
107
135
|
:background #fff
|
108
136
|
:color #fff
|
109
137
|
|
110
|
-
|
111
|
-
=blueprint-liquid
|
112
|
-
// A container should group all your columns
|
113
|
-
.container
|
114
|
-
+container
|
115
|
-
// Use these classes (or mixins) to set the width of a column.
|
116
|
-
@for !n from 1 to !layout_liquid_columns + 1
|
117
|
-
.span-#{!n}
|
118
|
-
+span(!n)
|
119
|
-
div
|
120
|
-
&.span-#{!n}
|
121
|
-
+column(!n, !n == !layout_liquid_columns)
|
122
|
-
// The last column in a row needs this class (or mixin) or it will end up on the next row.
|
123
|
-
div.last
|
124
|
-
+last
|
125
|
-
// Add these to a column to append empty cols.
|
126
|
-
@for !n from 1 to !layout_liquid_columns
|
127
|
-
.append-#{!n}
|
128
|
-
+append(!n)
|
129
|
-
// Add these to a column to prepend empty cols.
|
130
|
-
@for !n from 1 to !layout_liquid_columns
|
131
|
-
.prepend-#{!n}
|
132
|
-
+prepend(!n)
|
133
|
-
// Use these classes on an element to push it into the
|
134
|
-
// next column, or to pull it into the previous column.
|
135
|
-
@for !n from 1 to !layout_liquid_columns + 1
|
136
|
-
.pull-#{!n}
|
137
|
-
+pull(!n)
|
138
|
-
@for !n from 1 to !layout_liquid_columns + 1
|
139
|
-
.push-#{!n}
|
140
|
-
+push(!n)
|