modular-scale 2.1.0 → 2.1.1

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: bc09fa2379f131d6f1a73d0e549fe17d13603196
4
- data.tar.gz: e040091ffa1183f998473052a6084ffbe9b71ff5
3
+ metadata.gz: 046c2bbc74504a6714922aa2ec24b3bde0239a42
4
+ data.tar.gz: 8353d90b9502fdc663c404c925f71cca7e0c9596
5
5
  SHA512:
6
- metadata.gz: 761cfc5df949d1de71e3e54e38e450e213ebcb6789dc335047d6fb0a407886528ce5d338a1970130ed0a14a29b9e8b9a60fa2f1513a40eb07dbe5852d7ac8ffa
7
- data.tar.gz: a88ddbbb8ab25fac1ceb8af781d1f6d4eb360f9990cde18034b0b23cf597960083f89921a9336676fbbf9d72993b5e802a507aa08b63b776e6c2ad8858057451
6
+ metadata.gz: 29ce6e0c37e1f70edc359929094bc2b9bf863d01329d84d6b0bdb89feb08e917ad66dbe81ea8340fffcebe90855a4b2e6a07936822ba5906241fc858895f9b63
7
+ data.tar.gz: 4e7345d6f1c58b1d490e24d98fb5af614eb0a26e4ace57c179da4f91170a30d4259e9d9bc6a339fd13b758a15d141803f552957d48f5922938a38947e5f185b7
@@ -1,3 +1,7 @@
1
+ # Version 2.1.1
2
+
3
+ Bugfix an `@else if` statement.
4
+
1
5
  # Version 2.1.0
2
6
 
3
7
  Ground-up re-write of ms-respond based on http://madebymike.com.au/writing/precise-control-responsive-typography/
@@ -16,7 +16,7 @@ Compass::Frameworks.register('modular-scale', :path => extension_path)
16
16
  # a prerelease version
17
17
  # Date is in the form of YYYY-MM-DD
18
18
  module ModularScale
19
- VERSION = "2.1.0"
19
+ VERSION = "2.1.1"
20
20
  DATE = "2013-12-20"
21
21
  end
22
22
 
data/readme.md CHANGED
@@ -14,16 +14,16 @@ To get started, you need to select a ratio and a base value. The base value is u
14
14
  * Compass config: `require 'modular-scale'`
15
15
  * SCSS: `@import 'modular-scale';`
16
16
 
17
- ### Bower
18
-
19
- * Terminal: `bower install modular-scale --save-dev`
20
- * SCSS: `@import '../link_to_component_dir/modular-scale';`
21
-
22
17
  ### Eyeglass
23
18
 
24
19
  * Terminal: `npm install modularscale-sass --save-dev`
25
20
  * SCSS: `@import 'modular-scale'`
26
21
 
22
+ ### Bower
23
+
24
+ * Terminal: `bower install modular-scale --save-dev`
25
+ * SCSS: `@import '../link_to_component_dir/modular-scale';`
26
+
27
27
  ### Vanilla Sass
28
28
 
29
29
  * [Download the latest zip](https://github.com/Team-Sass/modular-scale/releases/latest)
@@ -170,7 +170,7 @@ foo {
170
170
 
171
171
  ## [Changelog](https://github.com/Team-Sass/modular-scale/releases)
172
172
 
173
- ### Licence
173
+ ### License
174
174
 
175
175
  The MIT License (MIT)
176
176
 
@@ -34,12 +34,14 @@
34
34
  // Initial value
35
35
  #{$property}: ms($value,$base,ms-range(1,1,$range));
36
36
 
37
- //
37
+ // Loop through breakpoints
38
38
  @for $i from 1 through (length($range) - 1) {
39
39
  @media (min-width: ms-range($i,2,$range)) and (max-width: ms-range($i+1,2,$range)) {
40
40
  #{$property}: ms-respond-calc($value, $i, $range, $base);
41
41
  }
42
42
  }
43
+
44
+ // Final breakpoint is just an override value
43
45
  @media (min-width: ms-range(length($range),2,$range)) {
44
46
  #{$property}: ms($value,$base,ms-range(length($range),1,$range));
45
47
  }
@@ -2,9 +2,9 @@
2
2
  // http://en.wikipedia.org/wiki/Merge_sort
3
3
 
4
4
  @function ms-merge($A, $B) {
5
-
5
+
6
6
  $Return: ();
7
-
7
+
8
8
  // Some empty lists get passed through
9
9
  // so just pass the other list throguh
10
10
  @if length($A) == 0 {
@@ -19,28 +19,28 @@
19
19
  @if nth($B, length($B)) < nth($A, 1) {
20
20
  @return join($B, $A);
21
21
  }
22
-
22
+
23
23
  // Counters start at 1
24
24
  $A-counter: 1;
25
25
  $B-counter: 1;
26
-
26
+
27
27
  // Start looping through all numbers in array
28
28
  @while $A-counter <= length($A) and $B-counter <= length($B) {
29
-
29
+
30
30
  // Check if the A value is smaller
31
31
  // Uses or equal to avoid duplicate numbers
32
32
  @if nth($A, $A-counter) <= nth($B, $B-counter) {
33
33
  $Return: join($Return, nth($A, $A-counter));
34
34
  $A-counter: $A-counter + 1;
35
35
  }
36
-
36
+
37
37
  // Check if the B value is smaller
38
- @elseif nth($A, $A-counter) > nth($B, $B-counter) {
38
+ @else if nth($A, $A-counter) > nth($B, $B-counter) {
39
39
  $Return: join($Return, nth($B, $B-counter));
40
40
  $B-counter: $B-counter + 1;
41
41
  }
42
42
  }
43
-
43
+
44
44
  // Run through remainder values in the list
45
45
  @while $A-counter <= length($A) {
46
46
  $Current: nth($A, $A-counter);
@@ -56,7 +56,7 @@
56
56
  }
57
57
  $B-counter: $B-counter + 1;
58
58
  }
59
-
59
+
60
60
  // Done! return is now sorted and complete
61
61
  @return $Return;
62
62
  }
@@ -65,7 +65,7 @@
65
65
 
66
66
  // Pull it all together
67
67
  @function ms-sort-list($Lists) {
68
-
68
+
69
69
  $Return: ();
70
70
 
71
71
  @each $List in $Lists {
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: modular-scale
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.0
4
+ version: 2.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Scott Kellum
@@ -56,6 +56,7 @@ files:
56
56
  - stylesheets/modular-scale/_round-px.scss
57
57
  - stylesheets/modular-scale/_sort-list.scss
58
58
  - stylesheets/modular-scale/_tests.scss
59
+ - stylesheets/modular-scale.zip
59
60
  - changelog.md
60
61
  - license.md
61
62
  - readme.md