itsucks-compass-960-plugin 0.9.11

Sign up to get free protection for your applications and to get access to all the features.
data/Manifest ADDED
@@ -0,0 +1,15 @@
1
+ Manifest
2
+ README.mkdn
3
+ Rakefile
4
+ VERSION
5
+ lib/ninesixty.rb
6
+ lib/ninesixty/compass_plugin.rb
7
+ sass/960/_debug.sass
8
+ sass/960/_grid.sass
9
+ sass/960/_text.sass
10
+ templates/project/12_col.gif
11
+ templates/project/16_col.gif
12
+ templates/project/debug.sass
13
+ templates/project/grid.sass
14
+ templates/project/manifest.rb
15
+ templates/project/text.sass
data/README.mkdn ADDED
@@ -0,0 +1,61 @@
1
+ 960 Grid System - Compass Plugin
2
+ ================================
3
+
4
+ * Port of Version 1.0
5
+ * 2008-03-24
6
+
7
+ Created by Nathan Smith. See the official site for more info: <http://960.gs/>
8
+
9
+ ---------
10
+
11
+ This plugin adds the 960 Grid System framework to [Compass](http://compass-style.org/).
12
+
13
+ Install
14
+ =======
15
+
16
+ sudo gem install itsucks-compass-960-plugin
17
+
18
+ Create a 960-based Compass Project
19
+ ==================================
20
+
21
+ compass -r ninesixty -f 960 <project name>
22
+
23
+ Then edit your `grid.sass`, `text.sass` adn `debug.sass` files accordingly. A reset is added into grid.sass automatically.
24
+
25
+ Customizing your Grid System
26
+ ============================
27
+
28
+ To create a grid system with other number of columns use the `+grid-system` mixin to generate
29
+ the corresponding classes.
30
+
31
+ Example:
32
+
33
+ #wrap
34
+ +grid-system(24)
35
+
36
+ Making Semantic Grids
37
+ =====================
38
+
39
+ * Use the `+grid-container` mixin to declare your container element.
40
+ * Use the `+grid` mixin to declare a grid element.
41
+ * Use the `+alpha` and `+omega` mixins to declare the first and last grid elements for a row.
42
+ * Use the `+grid-prefix` and `+grid-suffix` mixins to add grid columns before or after a grid element.
43
+
44
+
45
+ Example:
46
+
47
+ #wrap
48
+ +grid-container
49
+ #left-nav
50
+ +alpha
51
+ +grid(5,16)
52
+ #main-content
53
+ +grid-prefix(1,16)
54
+ +grid(10, 16)
55
+ +omega
56
+
57
+ Debug Grids
58
+ ===========
59
+
60
+ +showgrid_12(!selector = ".wrap_12")
61
+ +showgrid_16(!selector = ".wrap_16")
data/Rakefile ADDED
@@ -0,0 +1,21 @@
1
+ require 'fileutils'
2
+ require 'sass'
3
+
4
+ begin
5
+ require 'echoe'
6
+
7
+ Echoe.new('itsucks-compass-960-plugin', open('VERSION').read) do |p|
8
+ # p.rubyforge_name = '960'
9
+ p.summary = "Compass compatible Sass port of 960.gs."
10
+ p.description = "The 960 Grid System is an effort to streamline web development workflow by providing commonly used dimensions, based on a width of 960 pixels. http://960.gs/"
11
+ p.url = "http://github.com/chriseppstein/compass-960-plugin"
12
+ p.author = ['Percy Lau']
13
+ p.email = "percy.lau@gmail.com"
14
+ p.dependencies = ["chriseppstein-compass"]
15
+ p.has_rdoc = false
16
+ end
17
+
18
+ rescue LoadError => boom
19
+ puts "You are missing a dependency required for meta-operations on this gem."
20
+ puts "#{boom.to_s.capitalize}."
21
+ end
data/VERSION ADDED
@@ -0,0 +1 @@
1
+ 0.9.11
@@ -0,0 +1,33 @@
1
+ # -*- encoding: utf-8 -*-
2
+
3
+ Gem::Specification.new do |s|
4
+ s.name = %q{itsucks-compass-960-plugin}
5
+ s.version = "0.9.11"
6
+
7
+ s.required_rubygems_version = Gem::Requirement.new(">= 1.2") if s.respond_to? :required_rubygems_version=
8
+ s.authors = ["Percy Lau"]
9
+ s.date = %q{2010-03-21}
10
+ s.description = %q{The 960 Grid System is an effort to streamline web development workflow by providing commonly used dimensions, based on a width of 960 pixels. http://960.gs/}
11
+ s.email = %q{percy.lau@gmail.com}
12
+ s.extra_rdoc_files = ["README.mkdn", "lib/ninesixty.rb", "lib/ninesixty/compass_plugin.rb"]
13
+ s.files = ["Manifest", "README.mkdn", "Rakefile", "VERSION", "lib/ninesixty.rb", "lib/ninesixty/compass_plugin.rb", "sass/960/_debug.sass", "sass/960/_grid.sass", "sass/960/_text.sass", "templates/project/12_col.gif", "templates/project/16_col.gif", "templates/project/debug.sass", "templates/project/grid.sass", "templates/project/manifest.rb", "templates/project/text.sass", "itsucks-compass-960-plugin.gemspec"]
14
+ s.homepage = %q{http://github.com/chriseppstein/compass-960-plugin}
15
+ s.rdoc_options = ["--line-numbers", "--inline-source", "--title", "Itsucks-compass-960-plugin", "--main", "README.mkdn"]
16
+ s.require_paths = ["lib"]
17
+ s.rubyforge_project = %q{itsucks-compass-960-plugin}
18
+ s.rubygems_version = %q{1.3.6}
19
+ s.summary = %q{Compass compatible Sass port of 960.gs.}
20
+
21
+ if s.respond_to? :specification_version then
22
+ current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
23
+ s.specification_version = 3
24
+
25
+ if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
26
+ s.add_runtime_dependency(%q<chriseppstein-compass>, [">= 0"])
27
+ else
28
+ s.add_dependency(%q<chriseppstein-compass>, [">= 0"])
29
+ end
30
+ else
31
+ s.add_dependency(%q<chriseppstein-compass>, [">= 0"])
32
+ end
33
+ end
data/lib/ninesixty.rb ADDED
@@ -0,0 +1 @@
1
+ require File.join(File.dirname(__FILE__), 'ninesixty', 'compass_plugin')
@@ -0,0 +1,5 @@
1
+ options = Hash.new
2
+ options[:stylesheets_directory] = File.expand_path(File.join(File.dirname(__FILE__), '..', '..', 'sass'))
3
+ options[:templates_directory] = File.expand_path(File.join(File.dirname(__FILE__), '..', '..', 'templates'))
4
+
5
+ Compass::Frameworks.register('960', options)
@@ -0,0 +1,14 @@
1
+ !col_12 ||= "12_col.gif"
2
+ !col_16 ||= "16_col.gif"
3
+
4
+ =showgrid_12(!selector, !grid_pic = !col_12)
5
+ #{!selector}
6
+ :background
7
+ :image= image_url(!grid_pic)
8
+ :repeat repeat-y
9
+
10
+ =showgrid_16(!selector, !grid_pic = !col_16)
11
+ #{!selector}
12
+ :background
13
+ :image= image_url(!grid_pic)
14
+ :repeat repeat-y
@@ -0,0 +1,80 @@
1
+ !ninesixty_gutter_width ||= 20px
2
+ !ninesixty_grid_width ||= 960px
3
+ !ninesixty_columns ||= 12
4
+
5
+ =grid-container
6
+ :margin-left auto
7
+ :margin-right auto
8
+ :width= !ninesixty_grid_width
9
+
10
+ =grid-width(!n, !cols = !ninesixty_columns, !gutter_width = !ninesixty_gutter_width)
11
+ :width= (!ninesixty_grid_width / !cols) * !n - !gutter_width
12
+
13
+ =grid-unit-base(!gutter_width = !ninesixty_gutter_width)
14
+ :display inline
15
+ :float left
16
+ :margin
17
+ :left= !gutter_width / 2
18
+ :right= !gutter_width / 2
19
+
20
+ =grid(!n, !cols = !ninesixty_columns, !gutter_width = !ninesixty_gutter_width)
21
+ +grid-unit-base(!gutter_width)
22
+ +grid-width(!n, !cols, !gutter_width)
23
+
24
+ =alpha
25
+ :margin-left 0
26
+
27
+ =omega
28
+ :margin-right 0
29
+
30
+ =grids(!cols = !ninesixty_columns, !gutter_width = !ninesixty_gutter_width)
31
+ #{enumerate(".grid",1,!cols,"_")}
32
+ +grid-unit-base
33
+ @for !n from 1 through !cols
34
+ .grid_#{!n}
35
+ +grid-width(!n, !cols, !gutter_width)
36
+
37
+ =grid-prefix(!n, !cols = !ninesixty_columns)
38
+ :padding-left= (!ninesixty_grid_width / !cols) * !n
39
+
40
+ =grid-prefixes(!cols = !ninesixty_columns)
41
+ @for !n from 1 through !cols - 1
42
+ .prefix_#{!n}
43
+ +grid-prefix(!n, !cols)
44
+
45
+ =grid-suffix(!n, !cols = !ninesixty_columns)
46
+ :padding-right= (!ninesixty_grid_width / !cols) * !n
47
+
48
+ =grid-suffixes(!cols = !ninesixty_columns)
49
+ @for !n from 1 through !cols - 1
50
+ .suffix_#{!n}
51
+ +grid-suffix(!n, !cols)
52
+
53
+ =grid-push(!n, !cols = !ninesixty_columns)
54
+ :left= (!ninesixty_grid_width / !cols) * !n
55
+
56
+ =grid-pushs(!cols = !ninesixty_columns)
57
+ @for !n from 1 through !cols - 1
58
+ .push_#{!n}
59
+ +grid-push(!n, !cols)
60
+
61
+ =grid-pull(!n, !cols = !ninesixty_columns)
62
+ :left= -(!ninesixty_grid_width / !cols) * !n
63
+
64
+ =grid-pulls(!cols = !ninesixty_columns)
65
+ @for !n from 1 through !cols - 1
66
+ .pull_#{!n}
67
+ +grid-pull(!n, !cols)
68
+
69
+ =grid-children
70
+ .alpha
71
+ +alpha
72
+ .omega
73
+ +omega
74
+
75
+ =grid-system(!cols = !ninesixty_columns)
76
+ +grid-container
77
+ +grids(!cols)
78
+ +grid-prefixes(!cols)
79
+ +grid-suffixes(!cols)
80
+ +grid-children
@@ -0,0 +1,59 @@
1
+ !ninesixty_font_family ||= "Helvetica, Arial, 'Liberation Sans', FreeSans, sans-serif"
2
+
3
+ =text(!font_family = !ninesixty_font_family)
4
+ body
5
+ :font= "13px/1.5" !font_family
6
+
7
+ a:focus
8
+ :outline 1px dotted invert
9
+
10
+ hr
11
+ :border-color #ccc
12
+ :border-style solid
13
+ :border-width 1px 0 0
14
+ :clear both
15
+ :height 0
16
+
17
+ h1
18
+ :font-size 25px
19
+
20
+ h2
21
+ :font-size 23px
22
+
23
+ h3
24
+ :font-size 21px
25
+
26
+ h4
27
+ :font-size 19px
28
+
29
+ h5
30
+ :font-size 17px
31
+
32
+ h6
33
+ :font-size 15px
34
+
35
+ ol
36
+ :list-style decimal
37
+
38
+ ul
39
+ :list-style square
40
+
41
+ li
42
+ :margin-left 30px
43
+
44
+ p,
45
+ dl,
46
+ hr,
47
+ h1,
48
+ h2,
49
+ h3,
50
+ h4,
51
+ h5,
52
+ h6,
53
+ ol,
54
+ ul,
55
+ pre,
56
+ table,
57
+ address,
58
+ fieldset
59
+ :margin-bottom 20px
Binary file
Binary file
@@ -0,0 +1,13 @@
1
+ /*
2
+ 960 Grid System ~ Debug CSS.
3
+ Learn more ~ http://960.gs/
4
+
5
+ Licensed under GPL and MIT.
6
+
7
+ @import 960/debug.sass
8
+
9
+ /*
10
+ +showgrid_12(!selector = ".wrap_12")
11
+
12
+ /*
13
+ +showgrid_16(!selector = ".wrap_16")
@@ -0,0 +1,34 @@
1
+ /*
2
+ 960 Grid System ~ Core CSS.
3
+ Learn more ~ http://960.gs/
4
+
5
+ Licensed under GPL and MIT.
6
+
7
+ @import compass/utilities/general/reset.sass
8
+ @import 960/grid.sass
9
+
10
+ +global-reset
11
+
12
+ // The following generates the default grids provided by the css version of 960.gs
13
+ .container_12
14
+ +grid-system(12)
15
+
16
+ .container_16
17
+ +grid-system(16)
18
+
19
+ // But most compass users prefer to construct semantic layouts like so (two column layout with header and footer):
20
+
21
+ !ninesixty_columns = 24
22
+ .two-column
23
+ +grid-container
24
+ #header,
25
+ #footer,
26
+ #sidebar,
27
+ #main-content
28
+ +grid-unit-base
29
+ #header, #footer
30
+ +grid-width(24)
31
+ #sidebar
32
+ +grid-width(8)
33
+ #main-content
34
+ +grid-width(16)
@@ -0,0 +1,5 @@
1
+ stylesheet 'grid.sass', :media => "screen, projection"
2
+ stylesheet 'text.sass', :media => "screen, projection"
3
+ stylesheet 'debug.sass', :media => "screen, projection"
4
+ image '12_col.gif'
5
+ image '16_col.gif'
@@ -0,0 +1,10 @@
1
+ /*
2
+ 960 Grid System ~ Text CSS.
3
+ Learn more ~ http://960.gs/
4
+
5
+ Licensed under GPL and MIT.
6
+
7
+
8
+ @import 960/text.sass
9
+
10
+ +text
metadata ADDED
@@ -0,0 +1,96 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: itsucks-compass-960-plugin
3
+ version: !ruby/object:Gem::Version
4
+ prerelease: false
5
+ segments:
6
+ - 0
7
+ - 9
8
+ - 11
9
+ version: 0.9.11
10
+ platform: ruby
11
+ authors:
12
+ - Percy Lau
13
+ autorequire:
14
+ bindir: bin
15
+ cert_chain: []
16
+
17
+ date: 2010-03-21 00:00:00 +08:00
18
+ default_executable:
19
+ dependencies:
20
+ - !ruby/object:Gem::Dependency
21
+ name: chriseppstein-compass
22
+ prerelease: false
23
+ requirement: &id001 !ruby/object:Gem::Requirement
24
+ requirements:
25
+ - - ">="
26
+ - !ruby/object:Gem::Version
27
+ segments:
28
+ - 0
29
+ version: "0"
30
+ type: :runtime
31
+ version_requirements: *id001
32
+ description: The 960 Grid System is an effort to streamline web development workflow by providing commonly used dimensions, based on a width of 960 pixels. http://960.gs/
33
+ email: percy.lau@gmail.com
34
+ executables: []
35
+
36
+ extensions: []
37
+
38
+ extra_rdoc_files:
39
+ - README.mkdn
40
+ - lib/ninesixty.rb
41
+ - lib/ninesixty/compass_plugin.rb
42
+ files:
43
+ - Manifest
44
+ - README.mkdn
45
+ - Rakefile
46
+ - VERSION
47
+ - lib/ninesixty.rb
48
+ - lib/ninesixty/compass_plugin.rb
49
+ - sass/960/_debug.sass
50
+ - sass/960/_grid.sass
51
+ - sass/960/_text.sass
52
+ - templates/project/12_col.gif
53
+ - templates/project/16_col.gif
54
+ - templates/project/debug.sass
55
+ - templates/project/grid.sass
56
+ - templates/project/manifest.rb
57
+ - templates/project/text.sass
58
+ - itsucks-compass-960-plugin.gemspec
59
+ has_rdoc: true
60
+ homepage: http://github.com/chriseppstein/compass-960-plugin
61
+ licenses: []
62
+
63
+ post_install_message:
64
+ rdoc_options:
65
+ - --line-numbers
66
+ - --inline-source
67
+ - --title
68
+ - Itsucks-compass-960-plugin
69
+ - --main
70
+ - README.mkdn
71
+ require_paths:
72
+ - lib
73
+ required_ruby_version: !ruby/object:Gem::Requirement
74
+ requirements:
75
+ - - ">="
76
+ - !ruby/object:Gem::Version
77
+ segments:
78
+ - 0
79
+ version: "0"
80
+ required_rubygems_version: !ruby/object:Gem::Requirement
81
+ requirements:
82
+ - - ">="
83
+ - !ruby/object:Gem::Version
84
+ segments:
85
+ - 1
86
+ - 2
87
+ version: "1.2"
88
+ requirements: []
89
+
90
+ rubyforge_project: itsucks-compass-960-plugin
91
+ rubygems_version: 1.3.6
92
+ signing_key:
93
+ specification_version: 3
94
+ summary: Compass compatible Sass port of 960.gs.
95
+ test_files: []
96
+