inuit-rails 6.0.0.beta.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (59) hide show
  1. checksums.yaml +7 -0
  2. data/.bowerrc +3 -0
  3. data/.document +5 -0
  4. data/.gitignore +55 -0
  5. data/.rspec +2 -0
  6. data/.travis.yml +5 -0
  7. data/CODE_OF_CONDUCT.md +49 -0
  8. data/Gemfile +4 -0
  9. data/LICENSE.txt +21 -0
  10. data/README.md +41 -0
  11. data/Rakefile +6 -0
  12. data/bin/console +14 -0
  13. data/bin/setup +8 -0
  14. data/bower.json +19 -0
  15. data/inuit-rails.gemspec +24 -0
  16. data/lib/inuit-rails.rb +2 -0
  17. data/lib/inuit-rails/rails.rb +1 -0
  18. data/lib/inuit-rails/rails/engine.rb +6 -0
  19. data/lib/inuit-rails/rails/version.rb +5 -0
  20. data/vendor/assets/stylesheets/inuitcss/LICENSE +13 -0
  21. data/vendor/assets/stylesheets/inuitcss/circle.yml +17 -0
  22. data/vendor/assets/stylesheets/inuitcss/components/_example.components.buttons.scss +170 -0
  23. data/vendor/assets/stylesheets/inuitcss/elements/_elements.headings.scss +47 -0
  24. data/vendor/assets/stylesheets/inuitcss/elements/_elements.images.scss +28 -0
  25. data/vendor/assets/stylesheets/inuitcss/elements/_elements.page.scss +22 -0
  26. data/vendor/assets/stylesheets/inuitcss/elements/_elements.tables.scss +11 -0
  27. data/vendor/assets/stylesheets/inuitcss/example.main.scss +154 -0
  28. data/vendor/assets/stylesheets/inuitcss/generic/_generic.box-sizing.scss +22 -0
  29. data/vendor/assets/stylesheets/inuitcss/generic/_generic.normalize.scss +461 -0
  30. data/vendor/assets/stylesheets/inuitcss/generic/_generic.reset.scss +53 -0
  31. data/vendor/assets/stylesheets/inuitcss/generic/_generic.shared.scss +36 -0
  32. data/vendor/assets/stylesheets/inuitcss/objects/_objects.block.scss +63 -0
  33. data/vendor/assets/stylesheets/inuitcss/objects/_objects.box.scss +48 -0
  34. data/vendor/assets/stylesheets/inuitcss/objects/_objects.crop.scss +99 -0
  35. data/vendor/assets/stylesheets/inuitcss/objects/_objects.flag.scss +214 -0
  36. data/vendor/assets/stylesheets/inuitcss/objects/_objects.layout.scss +247 -0
  37. data/vendor/assets/stylesheets/inuitcss/objects/_objects.list-bare.scss +13 -0
  38. data/vendor/assets/stylesheets/inuitcss/objects/_objects.list-inline.scss +53 -0
  39. data/vendor/assets/stylesheets/inuitcss/objects/_objects.media.scss +152 -0
  40. data/vendor/assets/stylesheets/inuitcss/objects/_objects.pack.scss +90 -0
  41. data/vendor/assets/stylesheets/inuitcss/objects/_objects.ratio.scss +85 -0
  42. data/vendor/assets/stylesheets/inuitcss/objects/_objects.tables.scss +74 -0
  43. data/vendor/assets/stylesheets/inuitcss/objects/_objects.wrapper.scss +51 -0
  44. data/vendor/assets/stylesheets/inuitcss/settings/_example.settings.config.scss +24 -0
  45. data/vendor/assets/stylesheets/inuitcss/settings/_example.settings.global.scss +9 -0
  46. data/vendor/assets/stylesheets/inuitcss/settings/_settings.core.scss +93 -0
  47. data/vendor/assets/stylesheets/inuitcss/tools/_tools.clearfix.scss +19 -0
  48. data/vendor/assets/stylesheets/inuitcss/tools/_tools.font-size.scss +44 -0
  49. data/vendor/assets/stylesheets/inuitcss/tools/_tools.hidden.scss +15 -0
  50. data/vendor/assets/stylesheets/inuitcss/tools/_tools.rem.scss +48 -0
  51. data/vendor/assets/stylesheets/inuitcss/utilities/_utilities.clearfix.scss +11 -0
  52. data/vendor/assets/stylesheets/inuitcss/utilities/_utilities.headings.scss +36 -0
  53. data/vendor/assets/stylesheets/inuitcss/utilities/_utilities.hide.scss +21 -0
  54. data/vendor/assets/stylesheets/inuitcss/utilities/_utilities.print.scss +90 -0
  55. data/vendor/assets/stylesheets/inuitcss/utilities/_utilities.spacing.scss +57 -0
  56. data/vendor/assets/stylesheets/inuitcss/utilities/_utilities.widths.scss +167 -0
  57. data/vendor/assets/stylesheets/sass-mq/_mq.scss +287 -0
  58. data/vendor/assets/stylesheets/sass-mq/show-breakpoints.gif +0 -0
  59. metadata +144 -0
@@ -0,0 +1,287 @@
1
+ @charset "UTF-8"; // Fixes an issue where Ruby locale is not set properly
2
+ // See https://github.com/sass-mq/sass-mq/pull/10
3
+
4
+ /// Base font size on the `<body>` element
5
+ /// @type Number (unit)
6
+ $mq-base-font-size: 16px !default;
7
+
8
+ /// Responsive mode
9
+ ///
10
+ /// Set to `false` to enable support for browsers that do not support @media queries,
11
+ /// (IE <= 8, Firefox <= 3, Opera <= 9)
12
+ ///
13
+ /// You could create a stylesheet served exclusively to older browsers,
14
+ /// where @media queries are rasterized
15
+ ///
16
+ /// @example scss
17
+ /// // old-ie.scss
18
+ /// $mq-responsive: false;
19
+ /// @import 'main'; // @media queries in this file will be rasterized up to $mq-static-breakpoint
20
+ /// // larger breakpoints will be ignored
21
+ ///
22
+ /// @type Boolean
23
+ /// @link https://github.com/sass-mq/sass-mq#responsive-mode-off Disabled responsive mode documentation
24
+ $mq-responsive: true !default;
25
+
26
+ /// Breakpoint list
27
+ ///
28
+ /// Name your breakpoints in a way that creates a ubiquitous language
29
+ /// across team members. It will improve communication between
30
+ /// stakeholders, designers, developers, and testers.
31
+ ///
32
+ /// @type Map
33
+ /// @link https://github.com/sass-mq/sass-mq#seeing-the-currently-active-breakpoint Full documentation and examples
34
+ $mq-breakpoints: (
35
+ mobile: 320px,
36
+ tablet: 740px,
37
+ desktop: 980px,
38
+ wide: 1300px
39
+ ) !default;
40
+
41
+ /// Static breakpoint (for fixed-width layouts)
42
+ ///
43
+ /// Define the breakpoint from $mq-breakpoints that should
44
+ /// be used as the target width for the fixed-width layout
45
+ /// (i.e. when $mq-responsive is set to 'false') in a old-ie.scss
46
+ ///
47
+ /// @example scss
48
+ /// // tablet-only.scss
49
+ /// //
50
+ /// // Ignore all styles above tablet breakpoint,
51
+ /// // and fix the styles (e.g. layout) at tablet width
52
+ /// $mq-responsive: false;
53
+ /// $mq-static-breakpoint: tablet;
54
+ /// @import 'main'; // @media queries in this file will be rasterized up to tablet
55
+ /// // larger breakpoints will be ignored
56
+ ///
57
+ /// @type String
58
+ /// @link https://github.com/sass-mq/sass-mq#adding-custom-breakpoints Full documentation and examples
59
+ $mq-static-breakpoint: desktop !default;
60
+
61
+ /// Show breakpoints in the top right corner
62
+ ///
63
+ /// If you want to display the currently active breakpoint in the top
64
+ /// right corner of your site during development, add the breakpoints
65
+ /// to this list, ordered by width, e.g. (mobile, tablet, desktop).
66
+ ///
67
+ /// @type map
68
+ $mq-show-breakpoints: () !default;
69
+
70
+ /// Customize the media type (e.g. `@media screen` or `@media print`)
71
+ /// By default sass-mq uses an "all" media type (`@media all and …`)
72
+ ///
73
+ /// @type String
74
+ /// @link https://github.com/sass-mq/sass-mq#changing-media-type Full documentation and examples
75
+ $mq-media-type: all !default;
76
+
77
+ /// Convert pixels to ems
78
+ ///
79
+ /// @param {Number} $px - value to convert
80
+ /// @param {Number} $base-font-size ($mq-base-font-size) - `<body>` font size
81
+ ///
82
+ /// @example scss
83
+ /// $font-size-in-ems: mq-px2em(16px);
84
+ /// p { font-size: mq-px2em(16px); }
85
+ ///
86
+ /// @requires $mq-base-font-size
87
+ /// @returns {Number}
88
+ @function mq-px2em($px, $base-font-size: $mq-base-font-size) {
89
+ @if unitless($px) {
90
+ @warn "Assuming #{$px} to be in pixels, attempting to convert it into pixels.";
91
+ @return mq-px2em($px * 1px, $base-font-size);
92
+ } @else if unit($px) == em {
93
+ @return $px;
94
+ }
95
+ @return ($px / $base-font-size) * 1em;
96
+ }
97
+
98
+ /// Get a breakpoint's width
99
+ ///
100
+ /// @param {String} $name - Name of the breakpoint. One of $mq-breakpoints
101
+ ///
102
+ /// @example scss
103
+ /// $tablet-width: mq-get-breakpoint-width(tablet);
104
+ /// @media (min-width: mq-get-breakpoint-width(desktop)) {}
105
+ ///
106
+ /// @requires {Variable} $mq-breakpoints
107
+ ///
108
+ /// @returns {Number} Value in pixels
109
+ @function mq-get-breakpoint-width($name, $breakpoints: $mq-breakpoints) {
110
+ @if map-has-key($breakpoints, $name) {
111
+ @return map-get($breakpoints, $name);
112
+ } @else {
113
+ @warn "Breakpoint #{$name} wasn't found in $breakpoints.";
114
+ }
115
+ }
116
+
117
+ /// Media Query mixin
118
+ ///
119
+ /// @param {String | Boolean} $from (false) - One of $mq-breakpoints
120
+ /// @param {String | Boolean} $until (false) - One of $mq-breakpoints
121
+ /// @param {String | Boolean} $and (false) - Additional media query parameters
122
+ /// @param {String} $media-type ($mq-media-type) - Media type: screen, print…
123
+ ///
124
+ /// @ignore Undocumented API, for advanced use only:
125
+ /// @ignore @param {Map} $breakpoints ($mq-breakpoints)
126
+ /// @ignore @param {String} $static-breakpoint ($mq-static-breakpoint)
127
+ ///
128
+ /// @content styling rules, wrapped into a @media query when $responsive is true
129
+ ///
130
+ /// @requires {Variable} $mq-media-type
131
+ /// @requires {Variable} $mq-breakpoints
132
+ /// @requires {Variable} $mq-static-breakpoint
133
+ /// @requires {function} mq-px2em
134
+ /// @requires {function} mq-get-breakpoint-width
135
+ ///
136
+ /// @link https://github.com/sass-mq/sass-mq#responsive-mode-on-default Full documentation and examples
137
+ ///
138
+ /// @example scss
139
+ /// .element {
140
+ /// @include mq($from: mobile) {
141
+ /// color: red;
142
+ /// }
143
+ /// @include mq($until: tablet) {
144
+ /// color: blue;
145
+ /// }
146
+ /// @include mq(mobile, tablet) {
147
+ /// color: green;
148
+ /// }
149
+ /// @include mq($from: tablet, $and: '(orientation: landscape)') {
150
+ /// color: teal;
151
+ /// }
152
+ /// @include mq(950px) {
153
+ /// color: hotpink;
154
+ /// }
155
+ /// @include mq(tablet, $media-type: screen) {
156
+ /// color: hotpink;
157
+ /// }
158
+ /// // Advanced use:
159
+ /// $my-breakpoints: (L: 900px, XL: 1200px);
160
+ /// @include mq(L, $breakpoints: $my-breakpoints, $static-breakpoint: L) {
161
+ /// color: hotpink;
162
+ /// }
163
+ /// }
164
+ @mixin mq(
165
+ $from: false,
166
+ $until: false,
167
+ $and: false,
168
+ $media-type: $mq-media-type,
169
+ $breakpoints: $mq-breakpoints,
170
+ $responsive: $mq-responsive,
171
+ $static-breakpoint: $mq-static-breakpoint
172
+ ) {
173
+ $min-width: 0;
174
+ $max-width: 0;
175
+ $media-query: '';
176
+
177
+ // From: this breakpoint (inclusive)
178
+ @if $from {
179
+ @if type-of($from) == number {
180
+ $min-width: mq-px2em($from);
181
+ } @else {
182
+ $min-width: mq-px2em(mq-get-breakpoint-width($from, $breakpoints));
183
+ }
184
+ }
185
+
186
+ // Until: that breakpoint (exclusive)
187
+ @if $until {
188
+ @if type-of($until) == number {
189
+ $max-width: mq-px2em($until);
190
+ } @else {
191
+ $max-width: mq-px2em(mq-get-breakpoint-width($until, $breakpoints)) - .01em;
192
+ }
193
+ }
194
+
195
+ // Responsive support is disabled, rasterize the output outside @media blocks
196
+ // The browser will rely on the cascade itself.
197
+ @if $responsive == false {
198
+ $static-breakpoint-width: mq-get-breakpoint-width($static-breakpoint, $breakpoints);
199
+ $target-width: mq-px2em($static-breakpoint-width);
200
+
201
+ // Output only rules that start at or span our target width
202
+ @if (
203
+ $and == false
204
+ and $min-width <= $target-width
205
+ and (
206
+ $until == false or $max-width >= $target-width
207
+ )
208
+ ) {
209
+ @content;
210
+ }
211
+ }
212
+
213
+ // Responsive support is enabled, output rules inside @media queries
214
+ @else {
215
+ @if $min-width != 0 { $media-query: '#{$media-query} and (min-width: #{$min-width})'; }
216
+ @if $max-width != 0 { $media-query: '#{$media-query} and (max-width: #{$max-width})'; }
217
+ @if $and { $media-query: '#{$media-query} and #{$and}'; }
218
+
219
+ // Remove unnecessary media query prefix 'all and '
220
+ @if ($media-type == 'all' and $media-query != '') {
221
+ $media-type: '';
222
+ $media-query: str-slice(unquote($media-query), 6);
223
+ }
224
+
225
+ @media #{$media-type + $media-query} {
226
+ @content;
227
+ }
228
+ }
229
+ }
230
+
231
+ /// Add a breakpoint
232
+ ///
233
+ /// @param {String} $name - Name of the breakpoint
234
+ /// @param {Number} $width - Width of the breakpoint
235
+ ///
236
+ /// @requires {Variable} $mq-breakpoints
237
+ ///
238
+ /// @example scss
239
+ /// @include mq-add-breakpoint(tvscreen, 1920px);
240
+ /// @include mq(tvscreen) {}
241
+ @mixin mq-add-breakpoint($name, $width) {
242
+ $new-breakpoint: ($name: $width);
243
+ $mq-breakpoints: map-merge($mq-breakpoints, $new-breakpoint) !global;
244
+ }
245
+
246
+ /// Show the active breakpoint in the top right corner of the viewport
247
+ /// @link https://github.com/sass-mq/sass-mq#seeing-the-currently-active-breakpoint
248
+ ///
249
+ /// @param {List} $show-breakpoints ($mq-show-breakpoints) - List of breakpoints to show in the top right corner
250
+ /// @param {Map} $breakpoints ($mq-breakpoints) - Breakpoint names and sizes
251
+ ///
252
+ /// @requires {Variable} $mq-breakpoints
253
+ /// @requires {Variable} $mq-show-breakpoints
254
+ ///
255
+ /// @example scss
256
+ /// // Show breakpoints using global settings
257
+ /// @include mq-show-breakpoints;
258
+ ///
259
+ /// // Show breakpoints using custom settings
260
+ /// @include mq-show-breakpoints((L, XL), (S: 300px, L: 800px, XL: 1200px));
261
+ @mixin mq-show-breakpoints($show-breakpoints: $mq-show-breakpoints, $breakpoints: $mq-breakpoints) {
262
+ body:before {
263
+ background-color: #FCF8E3;
264
+ border-bottom: 1px solid #FBEED5;
265
+ border-left: 1px solid #FBEED5;
266
+ color: #C09853;
267
+ font: small-caption;
268
+ padding: 3px 6px;
269
+ pointer-events: none;
270
+ position: fixed;
271
+ right: 0;
272
+ top: 0;
273
+ z-index: 100;
274
+
275
+ // Loop through the breakpoints that should be shown
276
+ @each $show-breakpoint in $show-breakpoints {
277
+ $width: mq-get-breakpoint-width($show-breakpoint, $breakpoints);
278
+ @include mq($show-breakpoint, $breakpoints: $breakpoints) {
279
+ content: "#{$show-breakpoint} ≥ #{$width} (#{mq-px2em($width)})";
280
+ }
281
+ }
282
+ }
283
+ }
284
+
285
+ @if length($mq-show-breakpoints) > 0 {
286
+ @include mq-show-breakpoints;
287
+ }
metadata ADDED
@@ -0,0 +1,144 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: inuit-rails
3
+ version: !ruby/object:Gem::Version
4
+ version: 6.0.0.beta.4
5
+ platform: ruby
6
+ authors:
7
+ - Dan Garland
8
+ autorequire:
9
+ bindir: exe
10
+ cert_chain: []
11
+ date: 2016-11-30 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: bundler
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '1.12'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '1.12'
27
+ - !ruby/object:Gem::Dependency
28
+ name: rake
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '10.0'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '10.0'
41
+ - !ruby/object:Gem::Dependency
42
+ name: rspec
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '3.0'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '3.0'
55
+ description:
56
+ email:
57
+ - dan@dangarland.co.uk
58
+ executables: []
59
+ extensions: []
60
+ extra_rdoc_files: []
61
+ files:
62
+ - ".bowerrc"
63
+ - ".document"
64
+ - ".gitignore"
65
+ - ".rspec"
66
+ - ".travis.yml"
67
+ - CODE_OF_CONDUCT.md
68
+ - Gemfile
69
+ - LICENSE.txt
70
+ - README.md
71
+ - Rakefile
72
+ - bin/console
73
+ - bin/setup
74
+ - bower.json
75
+ - inuit-rails.gemspec
76
+ - lib/inuit-rails.rb
77
+ - lib/inuit-rails/rails.rb
78
+ - lib/inuit-rails/rails/engine.rb
79
+ - lib/inuit-rails/rails/version.rb
80
+ - vendor/assets/stylesheets/inuitcss/LICENSE
81
+ - vendor/assets/stylesheets/inuitcss/circle.yml
82
+ - vendor/assets/stylesheets/inuitcss/components/_example.components.buttons.scss
83
+ - vendor/assets/stylesheets/inuitcss/elements/_elements.headings.scss
84
+ - vendor/assets/stylesheets/inuitcss/elements/_elements.images.scss
85
+ - vendor/assets/stylesheets/inuitcss/elements/_elements.page.scss
86
+ - vendor/assets/stylesheets/inuitcss/elements/_elements.tables.scss
87
+ - vendor/assets/stylesheets/inuitcss/example.main.scss
88
+ - vendor/assets/stylesheets/inuitcss/generic/_generic.box-sizing.scss
89
+ - vendor/assets/stylesheets/inuitcss/generic/_generic.normalize.scss
90
+ - vendor/assets/stylesheets/inuitcss/generic/_generic.reset.scss
91
+ - vendor/assets/stylesheets/inuitcss/generic/_generic.shared.scss
92
+ - vendor/assets/stylesheets/inuitcss/objects/_objects.block.scss
93
+ - vendor/assets/stylesheets/inuitcss/objects/_objects.box.scss
94
+ - vendor/assets/stylesheets/inuitcss/objects/_objects.crop.scss
95
+ - vendor/assets/stylesheets/inuitcss/objects/_objects.flag.scss
96
+ - vendor/assets/stylesheets/inuitcss/objects/_objects.layout.scss
97
+ - vendor/assets/stylesheets/inuitcss/objects/_objects.list-bare.scss
98
+ - vendor/assets/stylesheets/inuitcss/objects/_objects.list-inline.scss
99
+ - vendor/assets/stylesheets/inuitcss/objects/_objects.media.scss
100
+ - vendor/assets/stylesheets/inuitcss/objects/_objects.pack.scss
101
+ - vendor/assets/stylesheets/inuitcss/objects/_objects.ratio.scss
102
+ - vendor/assets/stylesheets/inuitcss/objects/_objects.tables.scss
103
+ - vendor/assets/stylesheets/inuitcss/objects/_objects.wrapper.scss
104
+ - vendor/assets/stylesheets/inuitcss/settings/_example.settings.config.scss
105
+ - vendor/assets/stylesheets/inuitcss/settings/_example.settings.global.scss
106
+ - vendor/assets/stylesheets/inuitcss/settings/_settings.core.scss
107
+ - vendor/assets/stylesheets/inuitcss/tools/_tools.clearfix.scss
108
+ - vendor/assets/stylesheets/inuitcss/tools/_tools.font-size.scss
109
+ - vendor/assets/stylesheets/inuitcss/tools/_tools.hidden.scss
110
+ - vendor/assets/stylesheets/inuitcss/tools/_tools.rem.scss
111
+ - vendor/assets/stylesheets/inuitcss/utilities/_utilities.clearfix.scss
112
+ - vendor/assets/stylesheets/inuitcss/utilities/_utilities.headings.scss
113
+ - vendor/assets/stylesheets/inuitcss/utilities/_utilities.hide.scss
114
+ - vendor/assets/stylesheets/inuitcss/utilities/_utilities.print.scss
115
+ - vendor/assets/stylesheets/inuitcss/utilities/_utilities.spacing.scss
116
+ - vendor/assets/stylesheets/inuitcss/utilities/_utilities.widths.scss
117
+ - vendor/assets/stylesheets/sass-mq/_mq.scss
118
+ - vendor/assets/stylesheets/sass-mq/show-breakpoints.gif
119
+ homepage: https://github.com/dmgarland/inuit-rails
120
+ licenses:
121
+ - MIT
122
+ metadata: {}
123
+ post_install_message:
124
+ rdoc_options: []
125
+ require_paths:
126
+ - lib
127
+ required_ruby_version: !ruby/object:Gem::Requirement
128
+ requirements:
129
+ - - ">="
130
+ - !ruby/object:Gem::Version
131
+ version: '0'
132
+ required_rubygems_version: !ruby/object:Gem::Requirement
133
+ requirements:
134
+ - - ">"
135
+ - !ruby/object:Gem::Version
136
+ version: 1.3.1
137
+ requirements: []
138
+ rubyforge_project:
139
+ rubygems_version: 2.6.8
140
+ signing_key:
141
+ specification_version: 4
142
+ summary: A Rails engine that permits the use of the inuit css framework within a Rails
143
+ application.
144
+ test_files: []