flint-gs 1.3.5 → 1.3.6
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 +4 -4
- data/README.md +86 -72
- data/lib/flint.rb +2 -2
- data/stylesheets/_flint.scss +3 -3
- data/stylesheets/flint/config/_config.scss +9 -9
- data/stylesheets/flint/functions/helpers/_helpers.scss +37 -31
- data/stylesheets/flint/functions/lib/_calc-breakpoint.scss +14 -11
- data/stylesheets/flint/functions/lib/_calc-margin.scss +13 -13
- data/stylesheets/flint/functions/lib/_calc-width.scss +13 -13
- data/stylesheets/flint/functions/lib/_exists.scss +3 -3
- data/stylesheets/flint/functions/lib/_fluid-width.scss +3 -3
- data/stylesheets/flint/functions/lib/_get-family-instance.scss +3 -3
- data/stylesheets/flint/functions/lib/_get-index.scss +3 -3
- data/stylesheets/flint/functions/lib/_get-instance-value.scss +7 -7
- data/stylesheets/flint/functions/lib/_get-substring.scss +3 -3
- data/stylesheets/flint/functions/lib/_get-value.scss +7 -7
- data/stylesheets/flint/functions/lib/_instance.scss +10 -10
- data/stylesheets/flint/functions/lib/_last.scss +2 -2
- data/stylesheets/flint/functions/lib/_list-to-string.scss +3 -3
- data/stylesheets/flint/functions/lib/_map-fetch.scss +5 -6
- data/stylesheets/flint/functions/lib/_next-index.scss +6 -6
- data/stylesheets/flint/functions/lib/_purge.scss +2 -2
- data/stylesheets/flint/functions/lib/_remove.scss +4 -4
- data/stylesheets/flint/functions/lib/_replace.scss +4 -4
- data/stylesheets/flint/functions/lib/_steal-key.scss +4 -4
- data/stylesheets/flint/functions/lib/_steal-values.scss +3 -3
- data/stylesheets/flint/functions/lib/_string-to-list.scss +4 -4
- data/stylesheets/flint/functions/lib/_string-to-number.scss +3 -3
- data/stylesheets/flint/mixins/lib/_clearfix.scss +3 -2
- data/stylesheets/flint/mixins/lib/_flint-calculate.scss +115 -115
- data/stylesheets/flint/mixins/lib/_flint-main.scss +174 -141
- data/stylesheets/flint/mixins/lib/_new-instance.scss +9 -9
- data/stylesheets/flint/mixins/lib/_print-instance.scss +4 -4
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6d634d2596ab6f3aa67f9fe262a32561c71fdd01
|
4
|
+
data.tar.gz: e37a7f913e9446345993ffdfda2af406110d1c25
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2f78b6604a1f92b16fdce75fd8330ade50b6e2b5cc82cd70080b929ce6fc3b7aa512f7fbb257091ba135009263d5bcf2b346947f5f0fe69f4255ab0e6383c0ab
|
7
|
+
data.tar.gz: f27df87a21beea5e8cae0fb27d23928b43fb9448790d2c243b78980ea3feaaf00dd235a8566bed329c60efd548cce65cf305ae0812e404f0dd338140091ea40f
|
data/README.md
CHANGED
@@ -37,30 +37,30 @@ No mixing of `px` and `em` units. Also, Flint does require that you follow a `DE
|
|
37
37
|
|
38
38
|
```scss
|
39
39
|
// Configuration map
|
40
|
-
|
41
|
-
// @param [
|
40
|
+
//--------------------------------------------------------------------------------
|
41
|
+
// @param [map] : Here you can set up your various breakpoints for your
|
42
42
|
// project. Any number of breakpoints is acceptable. You must include a column
|
43
|
-
// count and breakpoint value for each listed breakpoint.
|
44
|
-
//
|
43
|
+
// count and breakpoint value for each listed breakpoint. Order does not have
|
44
|
+
// to follow `ASC` or `DESC`. Unit chosen here must be used consistently
|
45
45
|
// throughout the rest of the config map.
|
46
|
-
|
47
|
-
// @param default [
|
48
|
-
// @param grid [
|
49
|
-
// @param gutter [
|
50
|
-
// @param float-style [
|
51
|
-
// @param max-width [
|
52
|
-
// @param center-container [
|
53
|
-
// @param border-box-sizing [
|
54
|
-
// @param debug-mode [
|
46
|
+
//--------------------------------------------------------------------------------
|
47
|
+
// @param default [string] : alias of breakpoint that is your grid default
|
48
|
+
// @param grid [string] : style of grid
|
49
|
+
// @param gutter [integer | false] : contextual size of gutter
|
50
|
+
// @param float-style [integer | false] : float direction
|
51
|
+
// @param max-width [integer | bool] : max-width for `containers`
|
52
|
+
// @param center-container [bool] : if you want a centered container
|
53
|
+
// @param border-box-sizing [bool] : if you want box-sizing: border-box applied
|
54
|
+
// @param debug-mode [bool] : ouputs debug properties
|
55
55
|
// -------------------------------------------------------------------------------
|
56
56
|
|
57
57
|
$flint: (
|
58
58
|
// grid configuration
|
59
59
|
"config": (
|
60
|
-
// define breakpoints [any
|
60
|
+
// define breakpoints [any amount of breakpoints]
|
61
61
|
"desktop": ( // [any alias you like, minus reserved flint words (i.e. "settings", etc.)]
|
62
62
|
"columns": 16, // [0-infinity]
|
63
|
-
"breakpoint": 1280px, // [
|
63
|
+
"breakpoint": 1280px, // [0-infinity(unit)]
|
64
64
|
),
|
65
65
|
"laptop": (
|
66
66
|
"columns": 12,
|
@@ -76,14 +76,14 @@ $flint: (
|
|
76
76
|
),
|
77
77
|
// additional grid settings [required]
|
78
78
|
"settings": (
|
79
|
-
"default": "
|
79
|
+
"default": "mobile", // [any breakpoint's alias]
|
80
80
|
"grid": "fluid", // [fluid | fixed]
|
81
|
-
"gutter": 10px, // [
|
81
|
+
"gutter": 10px, // [0-infinity(unit) | false]
|
82
82
|
"float-style": "left", // [left | right]
|
83
|
-
"max-width":
|
83
|
+
"max-width": true, // [true : uses highest breakpoint | false | value(unit)]
|
84
84
|
"center-container": true, // [true | false]
|
85
85
|
"border-box-sizing": true, // [true | false]
|
86
|
-
"debug-mode":
|
86
|
+
"debug-mode": false, // [true | false ]
|
87
87
|
),
|
88
88
|
),
|
89
89
|
);
|
@@ -97,11 +97,11 @@ If you selected `border-box-sizing: true`, then it is *advised* to create a glob
|
|
97
97
|
@include _(foundation);
|
98
98
|
```
|
99
99
|
|
100
|
-
That way your output won't be riddled with `box-sizing` declarations everytime you define a span. This will automatically output the rules onto the global selector `*`. In the future this might be automatic, but for now I'll keep it manual.
|
100
|
+
That way your output won't be riddled with `"box-sizing"` declarations everytime you define a span. This will automatically output the rules onto the global selector `*`. In the future this might be automatic, but for now I'll keep it manual.
|
101
101
|
|
102
102
|
###Container
|
103
103
|
|
104
|
-
|
104
|
+
Containers act as a row for each individual breakpoint, and if set in your config, uses a max-width. They do not float, so if you have `"center-container"` set to `true` then it will also center your element using `auto` left and right margins.
|
105
105
|
|
106
106
|
```scss
|
107
107
|
.container {
|
@@ -164,34 +164,36 @@ Outputs, *(with debug mode on)*
|
|
164
164
|
width: 17.1875%;
|
165
165
|
margin-right: 0.78125%;
|
166
166
|
margin-left: 0.78125%;
|
167
|
-
-flint
|
168
|
-
-flint
|
169
|
-
-flint
|
170
|
-
-flint
|
171
|
-
-flint
|
172
|
-
-flint
|
173
|
-
-flint
|
174
|
-
-flint
|
175
|
-
-flint
|
176
|
-
-flint
|
177
|
-
-flint
|
167
|
+
-flint-instance-count: 1;
|
168
|
+
-flint-parent-instance: none;
|
169
|
+
-flint-key: desktop;
|
170
|
+
-flint-breakpoint: 1280px;
|
171
|
+
-flint-columns: 16;
|
172
|
+
-flint-span: 3;
|
173
|
+
-flint-context: null;
|
174
|
+
-flint-gutter: null;
|
175
|
+
-flint-shift: null;
|
176
|
+
-flint-output-width: 17.1875%;
|
177
|
+
-flint-output-margin-right: 0.78125%;
|
178
|
+
-flint-output-margin-left: 0.78125%;
|
178
179
|
}
|
179
180
|
@media only screen and (min-width: 641px) and (max-width: 960px) {
|
180
181
|
.recursive {
|
181
182
|
width: 22.91667%;
|
182
183
|
margin-right: 1.04167%;
|
183
184
|
margin-left: 1.04167%;
|
184
|
-
-flint
|
185
|
-
-flint
|
186
|
-
-flint
|
187
|
-
-flint
|
188
|
-
-flint
|
189
|
-
-flint
|
190
|
-
-flint
|
191
|
-
-flint
|
192
|
-
-flint
|
193
|
-
-flint
|
194
|
-
-flint
|
185
|
+
-flint-instance-count: 2;
|
186
|
+
-flint-parent-instance: none;
|
187
|
+
-flint-key: laptop;
|
188
|
+
-flint-breakpoint: 960px;
|
189
|
+
-flint-columns: 12;
|
190
|
+
-flint-span: 3;
|
191
|
+
-flint-context: null;
|
192
|
+
-flint-gutter: null;
|
193
|
+
-flint-shift: null;
|
194
|
+
-flint-output-width: 22.91667%;
|
195
|
+
-flint-output-margin-right: 1.04167%;
|
196
|
+
-flint-output-margin-left: 1.04167%;
|
195
197
|
}
|
196
198
|
}
|
197
199
|
@media only screen and (min-width: 321px) and (max-width: 640px) {
|
@@ -199,17 +201,18 @@ Outputs, *(with debug mode on)*
|
|
199
201
|
width: 34.375%;
|
200
202
|
margin-right: 1.5625%;
|
201
203
|
margin-left: 1.5625%;
|
202
|
-
-flint
|
203
|
-
-flint
|
204
|
-
-flint
|
205
|
-
-flint
|
206
|
-
-flint
|
207
|
-
-flint
|
208
|
-
-flint
|
209
|
-
-flint
|
210
|
-
-flint
|
211
|
-
-flint
|
212
|
-
-flint
|
204
|
+
-flint-instance-count: 3;
|
205
|
+
-flint-parent-instance: none;
|
206
|
+
-flint-key: tablet;
|
207
|
+
-flint-breakpoint: 640px;
|
208
|
+
-flint-columns: 8;
|
209
|
+
-flint-span: 3;
|
210
|
+
-flint-context: null;
|
211
|
+
-flint-gutter: null;
|
212
|
+
-flint-shift: null;
|
213
|
+
-flint-output-width: 34.375%;
|
214
|
+
-flint-output-margin-right: 1.5625%;
|
215
|
+
-flint-output-margin-left: 1.5625%;
|
213
216
|
}
|
214
217
|
}
|
215
218
|
@media only screen and (min-width: 0) and (max-width: 320px) {
|
@@ -217,24 +220,25 @@ Outputs, *(with debug mode on)*
|
|
217
220
|
width: 68.75%;
|
218
221
|
margin-right: 3.125%;
|
219
222
|
margin-left: 3.125%;
|
220
|
-
-flint
|
221
|
-
-flint
|
222
|
-
-flint
|
223
|
-
-flint
|
224
|
-
-flint
|
225
|
-
-flint
|
226
|
-
-flint
|
227
|
-
-flint
|
228
|
-
-flint
|
229
|
-
-flint
|
230
|
-
-flint
|
223
|
+
-flint-instance-count: 4;
|
224
|
+
-flint-parent-instance: none;
|
225
|
+
-flint-key: mobile;
|
226
|
+
-flint-breakpoint: 320px;
|
227
|
+
-flint-columns: 4;
|
228
|
+
-flint-span: 3;
|
229
|
+
-flint-context: null;
|
230
|
+
-flint-gutter: null;
|
231
|
+
-flint-shift: null;
|
232
|
+
-flint-output-width: 68.75%;
|
233
|
+
-flint-output-margin-right: 3.125%;
|
234
|
+
-flint-output-margin-left: 3.125%;
|
231
235
|
}
|
232
236
|
}
|
233
237
|
```
|
234
238
|
|
235
|
-
As you can see, since `desktop` is the framework `default`, it uses the output for desktop as the base styles. You can set this to any breakpoint you like. **So if you like mobile-first, you can do that.**
|
239
|
+
As you can see, since `"desktop"` is the framework `"default"`, it uses the output for desktop as the base styles. You can set this to any breakpoint you like. **So if you like mobile-first, you can do that.**
|
236
240
|
|
237
|
-
Whatever your `default` is set to, **flint** will not wrap those styles in media-queries, so that they may be used in non-supported browsers.
|
241
|
+
Whatever your `"default"` is set to, **flint** will not wrap those styles in media-queries, so that they may be used in non-supported browsers.
|
238
242
|
|
239
243
|
###Recursive shorthand with identical context
|
240
244
|
|
@@ -703,11 +707,12 @@ Outputs,
|
|
703
707
|
margin-right: 0;
|
704
708
|
margin-left: 7.5%;
|
705
709
|
-flint-instance-count: 9;
|
710
|
+
-flint-parent-instance: none;
|
706
711
|
-flint-key: desktop;
|
707
712
|
-flint-breakpoint: 1280px;
|
708
713
|
-flint-columns: 16;
|
709
714
|
-flint-span: 5.33333;
|
710
|
-
-flint-context:
|
715
|
+
-flint-context: null;
|
711
716
|
-flint-gutter: row;
|
712
717
|
-flint-shift: 1.2;
|
713
718
|
-flint--output-width: 33.33333%;
|
@@ -720,11 +725,12 @@ Outputs,
|
|
720
725
|
margin-right: 0;
|
721
726
|
margin-left: 0%;
|
722
727
|
-flint-instance-count: 10;
|
728
|
+
-flint-parent-instance: none;
|
723
729
|
-flint-key: laptop;
|
724
730
|
-flint-breakpoint: 960px;
|
725
731
|
-flint-columns: 12;
|
726
732
|
-flint-span: 12.1;
|
727
|
-
-flint-context:
|
733
|
+
-flint-context: null;
|
728
734
|
-flint-gutter: row;
|
729
735
|
-flint-shift: 0;
|
730
736
|
-flint--output-width: 100.83333%;
|
@@ -738,11 +744,12 @@ Outputs,
|
|
738
744
|
margin-right: 0;
|
739
745
|
margin-left: 25%;
|
740
746
|
-flint-instance-count: 11;
|
747
|
+
-flint-parent-instance: none;
|
741
748
|
-flint-key: tablet;
|
742
749
|
-flint-breakpoint: 640px;
|
743
750
|
-flint-columns: 8;
|
744
751
|
-flint-span: 8.9;
|
745
|
-
-flint-context:
|
752
|
+
-flint-context: null;
|
746
753
|
-flint-gutter: row;
|
747
754
|
-flint-shift: 2;
|
748
755
|
-flint--output-width: 111.25%;
|
@@ -756,11 +763,12 @@ Outputs,
|
|
756
763
|
margin-right: 0;
|
757
764
|
margin-left: 0%;
|
758
765
|
-flint-instance-count: 12;
|
766
|
+
-flint-parent-instance: none;
|
759
767
|
-flint-key: mobile;
|
760
768
|
-flint-breakpoint: 320px;
|
761
769
|
-flint-columns: 4;
|
762
770
|
-flint-span: 4;
|
763
|
-
-flint-context:
|
771
|
+
-flint-context: null;
|
764
772
|
-flint-gutter: row;
|
765
773
|
-flint-shift: 0;
|
766
774
|
-flint--output-width: 100%;
|
@@ -823,6 +831,12 @@ This will allow the instance functions to properly fallback from `.block .block_
|
|
823
831
|
|
824
832
|
Going to start keeping a log of changes starting (4/11/14).**
|
825
833
|
|
834
|
+
####6/11/14
|
835
|
+
* Cleaning house. Cleaned up function definitions and documentation, quoted all strings, and overall just made the code more tidy.
|
836
|
+
|
837
|
+
####5/20/14
|
838
|
+
* Fixed issue with `(for x y z)` loop not outputting correct breakpoints due to an invalid if statement.
|
839
|
+
|
826
840
|
####5/19/14
|
827
841
|
* Fixed issue with comma seperated parent selectors causing errors and other issues.
|
828
842
|
* Added small clean up functions for comma seperated selector strings for various functions.
|
@@ -854,7 +868,7 @@ Going to start keeping a log of changes starting (4/11/14).**
|
|
854
868
|
|
855
869
|
####4/25/14
|
856
870
|
* Added aliases for `$gutter` modifiers
|
857
|
-
* `
|
871
|
+
* `null > default | regular | normal`
|
858
872
|
* `alpha > no-left`
|
859
873
|
* `omega > no-right`
|
860
874
|
* `row > none`
|
data/lib/flint.rb
CHANGED
@@ -5,8 +5,8 @@ Compass::Frameworks.register('flint', :path => extension_path)
|
|
5
5
|
# Version is a number. If a version contains alphas, it will be created as a prerelease version
|
6
6
|
# Date is in the form of YYYY-MM-DD
|
7
7
|
module Flint
|
8
|
-
VERSION = "1.3.
|
9
|
-
DATE = "2014-
|
8
|
+
VERSION = "1.3.6"
|
9
|
+
DATE = "2014-06-11"
|
10
10
|
end
|
11
11
|
|
12
12
|
# Custom functions
|
data/stylesheets/_flint.scss
CHANGED
@@ -3,11 +3,11 @@
|
|
3
3
|
// -------------------------------------------------------------------------------
|
4
4
|
// @By : Ezekiel Gabrielse
|
5
5
|
// @Repository : https://github.com/ezekg/flint/
|
6
|
-
// @Sass
|
7
|
-
// @Compass
|
6
|
+
// @Sass >=3.3.3
|
7
|
+
// @Compass >=1.0.0.alpha.19
|
8
8
|
// -------------------------------------------------------------------------------
|
9
9
|
|
10
10
|
@import "flint/config/config";
|
11
11
|
@import "flint/functions/functions";
|
12
12
|
@import "flint/globals/globals";
|
13
|
-
@import "flint/mixins/mixins";
|
13
|
+
@import "flint/mixins/mixins";
|
@@ -1,19 +1,19 @@
|
|
1
1
|
// Configuration map
|
2
2
|
//--------------------------------------------------------------------------------
|
3
|
-
// @param [
|
3
|
+
// @param [map] : Here you can set up your various breakpoints for your
|
4
4
|
// project. Any number of breakpoints is acceptable. You must include a column
|
5
5
|
// count and breakpoint value for each listed breakpoint. Order does not have
|
6
6
|
// to follow `ASC` or `DESC`. Unit chosen here must be used consistently
|
7
7
|
// throughout the rest of the config map.
|
8
8
|
//--------------------------------------------------------------------------------
|
9
|
-
// @param default [
|
10
|
-
// @param grid [
|
11
|
-
// @param gutter [
|
12
|
-
// @param float-style [
|
13
|
-
// @param max-width [
|
14
|
-
// @param center-container [
|
15
|
-
// @param border-box-sizing [
|
16
|
-
// @param debug-mode [
|
9
|
+
// @param default [string] : alias of breakpoint that is your grid default
|
10
|
+
// @param grid [string] : style of grid
|
11
|
+
// @param gutter [integer | false] : contextual size of gutter
|
12
|
+
// @param float-style [integer | false] : float direction
|
13
|
+
// @param max-width [integer | bool] : max-width for `containers`
|
14
|
+
// @param center-container [bool] : if you want a centered container
|
15
|
+
// @param border-box-sizing [bool] : if you want box-sizing: border-box applied
|
16
|
+
// @param debug-mode [bool] : ouputs debug properties
|
17
17
|
// -------------------------------------------------------------------------------
|
18
18
|
|
19
19
|
$flint: (
|
@@ -1,8 +1,8 @@
|
|
1
1
|
// Returns truthiness of a value
|
2
2
|
// -------------------------------------------------------------------------------
|
3
|
-
// @param $value [
|
3
|
+
// @param $value [literal] : value
|
4
4
|
// -------------------------------------------------------------------------------
|
5
|
-
// @return [
|
5
|
+
// @return [bool]
|
6
6
|
|
7
7
|
@function is-true($value) {
|
8
8
|
@return if($value == null, false, $value and $value != null and $value != "" and $value != ());
|
@@ -10,9 +10,9 @@
|
|
10
10
|
|
11
11
|
// Checks if item is map
|
12
12
|
//--------------------------------------------------------------------------------
|
13
|
-
// @param $n [
|
13
|
+
// @param $n [map] : value
|
14
14
|
// -------------------------------------------------------------------------------
|
15
|
-
// @return [
|
15
|
+
// @return [bool]
|
16
16
|
|
17
17
|
@function is-map($n) {
|
18
18
|
@return type-of($n) == "map";
|
@@ -20,9 +20,9 @@
|
|
20
20
|
|
21
21
|
// Checks if item is list
|
22
22
|
//--------------------------------------------------------------------------------
|
23
|
-
// @param $n [
|
23
|
+
// @param $n [list] : value
|
24
24
|
// -------------------------------------------------------------------------------
|
25
|
-
// @return [
|
25
|
+
// @return [bool]
|
26
26
|
|
27
27
|
@function is-list($n) {
|
28
28
|
@return type-of($n) == "list";
|
@@ -30,9 +30,9 @@
|
|
30
30
|
|
31
31
|
// Checks if item is number
|
32
32
|
//--------------------------------------------------------------------------------
|
33
|
-
// @param $n [
|
33
|
+
// @param $n [integer] : value
|
34
34
|
// -------------------------------------------------------------------------------
|
35
|
-
// @return [
|
35
|
+
// @return [bool]
|
36
36
|
|
37
37
|
@function is-number($n) {
|
38
38
|
@return type-of($n) == "number";
|
@@ -40,9 +40,9 @@
|
|
40
40
|
|
41
41
|
// Checks if item is string
|
42
42
|
//--------------------------------------------------------------------------------
|
43
|
-
// @param $n [
|
43
|
+
// @param $n [string] : value
|
44
44
|
// -------------------------------------------------------------------------------
|
45
|
-
// @return [
|
45
|
+
// @return [bool]
|
46
46
|
|
47
47
|
@function is-string($n) {
|
48
48
|
@return type-of($n) == "string";
|
@@ -50,40 +50,40 @@
|
|
50
50
|
|
51
51
|
// Checks if item is not string
|
52
52
|
//--------------------------------------------------------------------------------
|
53
|
-
// @param $n [
|
53
|
+
// @param $n [string] : value
|
54
54
|
// -------------------------------------------------------------------------------
|
55
|
-
// @return [
|
55
|
+
// @return [bool]
|
56
56
|
|
57
57
|
@function is-not-string($n) {
|
58
58
|
@return type-of($n) != "string";
|
59
59
|
}
|
60
60
|
|
61
|
-
// Gets each breakpoint's key
|
61
|
+
// Gets list of each breakpoint's key
|
62
62
|
// -------------------------------------------------------------------------------
|
63
|
-
// @return [
|
63
|
+
// @return [list]
|
64
64
|
|
65
65
|
@function get-all-keys() {
|
66
66
|
$all-keys: ();
|
67
67
|
|
68
|
-
@for $i from 1 through (length(map-fetch($flint, config)) - 1) {
|
68
|
+
@for $i from 1 through (length(map-fetch($flint, "config")) - 1) {
|
69
69
|
$key: steal-key($i);
|
70
|
-
$all-keys: append($all-keys, $key,
|
70
|
+
$all-keys: append($all-keys, $key, "comma");
|
71
71
|
}
|
72
72
|
|
73
73
|
@return $all-keys;
|
74
74
|
}
|
75
75
|
|
76
|
-
// Gets all breakpoints
|
76
|
+
// Gets list of all breakpoints
|
77
77
|
// -------------------------------------------------------------------------------
|
78
|
-
// @return [
|
78
|
+
// @return [list]
|
79
79
|
|
80
80
|
@function get-all-breakpoints() {
|
81
81
|
$all-breakpoints: ();
|
82
82
|
|
83
|
-
@each $map, $keys in map-get($flint, config) {
|
83
|
+
@each $map, $keys in map-get($flint, "config") {
|
84
84
|
@each $key, $value in $keys {
|
85
85
|
@if $key == "breakpoint" {
|
86
|
-
$all-breakpoints: append($all-breakpoints, $value,
|
86
|
+
$all-breakpoints: append($all-breakpoints, $value, "comma");
|
87
87
|
}
|
88
88
|
}
|
89
89
|
}
|
@@ -91,28 +91,32 @@
|
|
91
91
|
@return $all-breakpoints;
|
92
92
|
}
|
93
93
|
|
94
|
-
//
|
94
|
+
// Checks if passed $key is the highest breakpoint
|
95
95
|
// -------------------------------------------------------------------------------
|
96
96
|
// @dependence `get-value()`
|
97
97
|
// -------------------------------------------------------------------------------
|
98
|
-
// @
|
98
|
+
// @param $key [string] : alias of breakpoint
|
99
|
+
// -------------------------------------------------------------------------------
|
100
|
+
// @return [bool]
|
99
101
|
|
100
102
|
@function is-highest-breakpoint($key) {
|
101
|
-
@if get-value($key, breakpoint) == max(get-all-breakpoints()...) {
|
103
|
+
@if get-value($key, "breakpoint") == max(get-all-breakpoints()...) {
|
102
104
|
@return true;
|
103
105
|
} @else {
|
104
106
|
@return false;
|
105
107
|
}
|
106
108
|
}
|
107
109
|
|
108
|
-
//
|
110
|
+
// Checks if passed $key is the lowest breakpoint
|
109
111
|
// -------------------------------------------------------------------------------
|
110
112
|
// @dependence `get-value()`
|
111
113
|
// -------------------------------------------------------------------------------
|
112
|
-
// @
|
114
|
+
// @param $key [string] : alias of breakpoint
|
115
|
+
// -------------------------------------------------------------------------------
|
116
|
+
// @return [bool]
|
113
117
|
|
114
118
|
@function is-lowest-breakpoint($key) {
|
115
|
-
@if get-value($key, breakpoint) == min(get-all-breakpoints()...) {
|
119
|
+
@if get-value($key, "breakpoint") == min(get-all-breakpoints()...) {
|
116
120
|
@return true;
|
117
121
|
} @else {
|
118
122
|
@return false;
|
@@ -123,10 +127,12 @@
|
|
123
127
|
// -------------------------------------------------------------------------------
|
124
128
|
// @dependence `get-value()`
|
125
129
|
// -------------------------------------------------------------------------------
|
126
|
-
// @
|
130
|
+
// @param $key [string] : alias of breakpoint
|
131
|
+
// -------------------------------------------------------------------------------
|
132
|
+
// @return [bool]
|
127
133
|
|
128
134
|
@function is-default($key) {
|
129
|
-
@if $key == get-value(settings, default) {
|
135
|
+
@if $key == get-value("settings", "default") {
|
130
136
|
@return true;
|
131
137
|
} @else {
|
132
138
|
@return false;
|
@@ -135,15 +141,15 @@
|
|
135
141
|
|
136
142
|
// Gets all breakpoint column values
|
137
143
|
// -------------------------------------------------------------------------------
|
138
|
-
// @return [
|
144
|
+
// @return [list]
|
139
145
|
|
140
146
|
@function get-all-columns() {
|
141
147
|
$all-columns: ();
|
142
148
|
|
143
|
-
@each $map, $keys in map-get($flint, config) {
|
149
|
+
@each $map, $keys in map-get($flint, "config") {
|
144
150
|
@each $key, $value in $keys {
|
145
151
|
@if $key == "columns" {
|
146
|
-
$all-columns: append($all-columns, $value,
|
152
|
+
$all-columns: append($all-columns, $value, "comma");
|
147
153
|
}
|
148
154
|
}
|
149
155
|
}
|