singularitygs 0.0.7 → 0.0.8

Sign up to get free protection for your applications and to get access to all the features.
data/lib/singularitygs.rb CHANGED
@@ -1,10 +1,12 @@
1
1
  require 'compass'
2
2
  require 'modular-scale'
3
+ require 'sassy-math'
4
+
3
5
  Compass::Frameworks.register("singularitygs", :path => "#{File.dirname(__FILE__)}/..")
4
6
 
5
7
  module CompassExtension
6
8
 
7
- VERSION = "0.0.7"
8
- DATE = "2012-06-23"
9
+ VERSION = "0.0.8"
10
+ DATE = "2012-07-26"
9
11
 
10
12
  end
@@ -1,4 +1,5 @@
1
1
  /*! SINGULARITY -- http://singularity.gs/ */
2
+ @import compass
2
3
  @import modular-scale
3
4
 
4
5
  // Can be a number or a list of non-uniform column widths
@@ -16,6 +17,9 @@ $padding: 0 !default
16
17
  // Compound grid calculation function
17
18
  @import singularitygs/compound
18
19
 
20
+ // Ratio grid calculation function
21
+ @import singularitygs/ratio
22
+
19
23
  // Column math is isolated
20
24
  @import singularitygs/column
21
25
 
@@ -25,3 +25,13 @@
25
25
  @for $i from 2 through $count
26
26
  $list: join($repeat, $list)
27
27
  @return $list
28
+
29
+ // Reverses direction of a list
30
+ @function reverse($list)
31
+ $length: length($list)
32
+ $return: ()
33
+
34
+ @for $i from 0 through $length - 1
35
+ $return: append($return, nth($list, $length - $i), comma)
36
+
37
+ @return $return
@@ -0,0 +1,20 @@
1
+ // Creates a list based on a ratio
2
+ // Valid options for $start: 'large' or 'small'
3
+ @function ratio($ratio, $steps, $start: 'small') {
4
+ $x: 1;
5
+ $return: ();
6
+
7
+ @for $i from 0 through $steps - 1 {
8
+ $xr: $x * pow($ratio, $i);
9
+ $return: append($return, $xr, comma);
10
+ }
11
+
12
+ @if $start == 'small' and $ratio < 1 {
13
+ $return: reverse($return);
14
+ }
15
+ @else if $start == 'large' and $ratio > 1 {
16
+ $return: reverse($return);
17
+ }
18
+
19
+ @return $return;
20
+ }
metadata CHANGED
@@ -1,71 +1,91 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: singularitygs
3
- version: !ruby/object:Gem::Version
4
- version: 0.0.7
5
- prerelease:
3
+ version: !ruby/object:Gem::Version
4
+ prerelease: false
5
+ segments:
6
+ - 0
7
+ - 0
8
+ - 8
9
+ version: 0.0.8
6
10
  platform: ruby
7
- authors:
11
+ authors:
8
12
  - Scott Kellum
13
+ - Sam Richard
9
14
  autorequire:
10
15
  bindir: bin
11
16
  cert_chain: []
12
- date: 2012-06-23 00:00:00.000000000 Z
13
- dependencies:
14
- - !ruby/object:Gem::Dependency
17
+
18
+ date: 2012-07-26 00:00:00 -04:00
19
+ default_executable:
20
+ dependencies:
21
+ - !ruby/object:Gem::Dependency
15
22
  name: sass
16
- requirement: !ruby/object:Gem::Requirement
17
- none: false
18
- requirements:
19
- - - ! '>='
20
- - !ruby/object:Gem::Version
21
- version: 3.2.0.alpha.269
22
- type: :runtime
23
23
  prerelease: false
24
- version_requirements: !ruby/object:Gem::Requirement
25
- none: false
26
- requirements:
27
- - - ! '>='
28
- - !ruby/object:Gem::Version
24
+ requirement: &id001 !ruby/object:Gem::Requirement
25
+ requirements:
26
+ - - ">="
27
+ - !ruby/object:Gem::Version
28
+ segments:
29
+ - 3
30
+ - 2
31
+ - 0
32
+ - alpha
33
+ - 269
29
34
  version: 3.2.0.alpha.269
30
- - !ruby/object:Gem::Dependency
31
- name: compass
32
- requirement: !ruby/object:Gem::Requirement
33
- none: false
34
- requirements:
35
- - - ! '>='
36
- - !ruby/object:Gem::Version
37
- version: 0.12.1
38
35
  type: :runtime
36
+ version_requirements: *id001
37
+ - !ruby/object:Gem::Dependency
38
+ name: compass
39
39
  prerelease: false
40
- version_requirements: !ruby/object:Gem::Requirement
41
- none: false
42
- requirements:
43
- - - ! '>='
44
- - !ruby/object:Gem::Version
40
+ requirement: &id002 !ruby/object:Gem::Requirement
41
+ requirements:
42
+ - - ">="
43
+ - !ruby/object:Gem::Version
44
+ segments:
45
+ - 0
46
+ - 12
47
+ - 1
45
48
  version: 0.12.1
46
- - !ruby/object:Gem::Dependency
49
+ type: :runtime
50
+ version_requirements: *id002
51
+ - !ruby/object:Gem::Dependency
47
52
  name: modular-scale
48
- requirement: !ruby/object:Gem::Requirement
49
- none: false
50
- requirements:
51
- - - ! '>='
52
- - !ruby/object:Gem::Version
53
+ prerelease: false
54
+ requirement: &id003 !ruby/object:Gem::Requirement
55
+ requirements:
56
+ - - ">="
57
+ - !ruby/object:Gem::Version
58
+ segments:
59
+ - 0
60
+ - 0
61
+ - 4
53
62
  version: 0.0.4
54
63
  type: :runtime
64
+ version_requirements: *id003
65
+ - !ruby/object:Gem::Dependency
66
+ name: sassy-math
55
67
  prerelease: false
56
- version_requirements: !ruby/object:Gem::Requirement
57
- none: false
58
- requirements:
59
- - - ! '>='
60
- - !ruby/object:Gem::Version
61
- version: 0.0.4
68
+ requirement: &id004 !ruby/object:Gem::Requirement
69
+ requirements:
70
+ - - ">="
71
+ - !ruby/object:Gem::Version
72
+ segments:
73
+ - 1
74
+ - 1
75
+ version: "1.1"
76
+ type: :runtime
77
+ version_requirements: *id004
62
78
  description: Advanced responsive grid system for Sass and Compass
63
- email:
79
+ email:
64
80
  - scott@scottkellum.com
81
+ - snugug@gmail.com
65
82
  executables: []
83
+
66
84
  extensions: []
85
+
67
86
  extra_rdoc_files: []
68
- files:
87
+
88
+ files:
69
89
  - lib/singularitygs.rb
70
90
  - stylesheets/singularitygs.sass
71
91
  - stylesheets/singularitygs/_background-grid.sass
@@ -76,30 +96,37 @@ files:
76
96
  - stylesheets/singularitygs/_gutter.sass
77
97
  - stylesheets/singularitygs/_helpers.sass
78
98
  - stylesheets/singularitygs/_mixins.sass
99
+ - stylesheets/singularitygs/_ratio.scss
100
+ has_rdoc: true
79
101
  homepage: http://singularity.gs
80
102
  licenses: []
103
+
81
104
  post_install_message:
82
105
  rdoc_options: []
83
- require_paths:
106
+
107
+ require_paths:
84
108
  - lib
85
- required_ruby_version: !ruby/object:Gem::Requirement
86
- none: false
87
- requirements:
88
- - - ! '>='
89
- - !ruby/object:Gem::Version
90
- version: '0'
91
- required_rubygems_version: !ruby/object:Gem::Requirement
92
- none: false
93
- requirements:
94
- - - ! '>='
95
- - !ruby/object:Gem::Version
96
- version: '1.2'
109
+ required_ruby_version: !ruby/object:Gem::Requirement
110
+ requirements:
111
+ - - ">="
112
+ - !ruby/object:Gem::Version
113
+ segments:
114
+ - 0
115
+ version: "0"
116
+ required_rubygems_version: !ruby/object:Gem::Requirement
117
+ requirements:
118
+ - - ">="
119
+ - !ruby/object:Gem::Version
120
+ segments:
121
+ - 1
122
+ - 2
123
+ version: "1.2"
97
124
  requirements: []
125
+
98
126
  rubyforge_project: singularitygs
99
- rubygems_version: 1.8.24
127
+ rubygems_version: 1.3.6
100
128
  signing_key:
101
129
  specification_version: 3
102
- summary: Singularity is a fluid grid system that can generate uniform columns as well
103
- as asymmetric and compound grids with tools to write grids as functions, mixins,
104
- or class based objects.
130
+ summary: Singularity is a fluid grid system that can generate uniform columns as well as asymmetric and compound grids with tools to write grids as functions, mixins, or class based objects.
105
131
  test_files: []
132
+