hawgrid_rsp 0.1.4.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +9 -0
- data/.travis.yml +4 -0
- data/Gemfile +4 -0
- data/LICENSE.txt +21 -0
- data/README.md +44 -0
- data/Rakefile +1 -0
- data/app/assets/stylesheets/_lite_settings.scss +15 -0
- data/app/assets/stylesheets/hawgrid_lite.scss +269 -0
- data/app/assets/stylesheets/hawgrid_rsp.css.scss +1 -0
- data/bin/console +14 -0
- data/bin/setup +7 -0
- data/hawgrid_rsp.gemspec +32 -0
- data/lib/hawgrid_rsp.rb +6 -0
- data/lib/hawgrid_rsp/version.rb +3 -0
- metadata +87 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 828e7d071698d571ff28bc4e1c19603a260b8b6d
|
4
|
+
data.tar.gz: a9b4602fd37214137b68d1232d84c34d45799c45
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: ebba129d505fe8069d8eb318f70efbeb95ce4872b61d2cb9961fbaa5490b30d12e68fc1fbf15456de366075c1d00ecfbaf339ec518bc9c568973b5e94368e903
|
7
|
+
data.tar.gz: dbb810ad04903424fa14ad2714d2cd69478d41e123557715d35f542b316c18e0e0aefed7a2d3283e1c5c4f3dde74e6e91ce7069ed48677df02fd7e8bff57fe29
|
data/.gitignore
ADDED
data/.travis.yml
ADDED
data/Gemfile
ADDED
data/LICENSE.txt
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
The MIT License (MIT)
|
2
|
+
|
3
|
+
Copyright (c) 2015 Hawry
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in
|
13
|
+
all copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
21
|
+
THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,44 @@
|
|
1
|
+
# HawgridRsp
|
2
|
+
|
3
|
+
Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/hawgrid_rsp`. To experiment with that code, run `bin/console` for an interactive prompt.
|
4
|
+
|
5
|
+
TODO: Delete this and the text above, and describe your gem
|
6
|
+
|
7
|
+
## Installation
|
8
|
+
|
9
|
+
Add this line to your application's Gemfile:
|
10
|
+
|
11
|
+
```ruby
|
12
|
+
gem 'hawgrid_rsp'
|
13
|
+
```
|
14
|
+
|
15
|
+
And then execute:
|
16
|
+
|
17
|
+
$ bundle
|
18
|
+
|
19
|
+
Or install it yourself as:
|
20
|
+
|
21
|
+
$ gem install hawgrid_rsp
|
22
|
+
|
23
|
+
## Usage
|
24
|
+
|
25
|
+
In your `app/assets/stylesheets/application.css` add the following line:
|
26
|
+
```
|
27
|
+
*= require hawgrid_rsp
|
28
|
+
```
|
29
|
+
|
30
|
+
## Development
|
31
|
+
|
32
|
+
After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake false` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
|
33
|
+
|
34
|
+
To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
|
35
|
+
|
36
|
+
## Contributing
|
37
|
+
|
38
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/hawgrid_rsp.
|
39
|
+
|
40
|
+
|
41
|
+
## License
|
42
|
+
|
43
|
+
The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
|
44
|
+
|
data/Rakefile
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
require "bundler/gem_tasks"
|
@@ -0,0 +1,15 @@
|
|
1
|
+
//HawGrid Lite
|
2
|
+
$lite-max-grids: 12;
|
3
|
+
$lite-gutter: 1em;
|
4
|
+
$font-base-size: 16px;
|
5
|
+
|
6
|
+
//Breakpoints
|
7
|
+
$bp-small: (0,40em);
|
8
|
+
$bp-medium: (40.00001em,64em);
|
9
|
+
$bp-large: (64.00001em,90em);
|
10
|
+
$bp-xlarge: (90.00001, 500000em);
|
11
|
+
|
12
|
+
$row-width-small: 64em;
|
13
|
+
$row-width-medium: $row-width-small;
|
14
|
+
$row-width-large: $row-width-medium;
|
15
|
+
$row-width-xlarge: 80em;
|
@@ -0,0 +1,269 @@
|
|
1
|
+
@import "lite_settings";
|
2
|
+
|
3
|
+
@function to-rem($px,$b: $font-base-size) {
|
4
|
+
@return #{$px/$b}rem;
|
5
|
+
}
|
6
|
+
@function to-em($px,$b: $font-base-size) {
|
7
|
+
@return #{$px/$b}em;
|
8
|
+
}
|
9
|
+
|
10
|
+
//Specific breakpoints
|
11
|
+
$bp-small-up: "only screen";
|
12
|
+
$bp-small-only: "only screen and (max-width: #{nth($bp-small,2)})";
|
13
|
+
$bp-small-down: "only screen and (max-width:#{nth($bp-small,2)})";
|
14
|
+
|
15
|
+
$bp-medium-up: "only screen and (min-width: #{nth($bp-medium,1)})";
|
16
|
+
$bp-medium-only: "only screen and (min-width: #{nth($bp-medium,1)}) and (max-width:#{nth($bp-medium,2)})";
|
17
|
+
$bp-medium-down: "only screen and (max-width:#{nth($bp-medium,2)})";
|
18
|
+
|
19
|
+
$bp-large-up: "only screen and (min-width: #{nth($bp-large,1)})";
|
20
|
+
$bp-large-only: "only screen and (min-width: #{nth($bp-large,1)}) and (max-width:#{nth($bp-large,2)})";
|
21
|
+
$bp-large-down: "only screen and (max-width:#{nth($bp-large,2)})";
|
22
|
+
|
23
|
+
$bp-xlarge-up: "only screen and (min-width: #{nth($bp-xlarge,1)})";
|
24
|
+
$bp-xlarge-only: "only screen and (min-width: #{nth($bp-xlarge,1)}) and (max-width:#{nth($bp-xlarge,2)})";
|
25
|
+
$bp-xlarge-down: "only screen";
|
26
|
+
|
27
|
+
%clearfix {
|
28
|
+
*zoom:1;
|
29
|
+
&:before,&:after {
|
30
|
+
content:"";
|
31
|
+
display:table;
|
32
|
+
}
|
33
|
+
&:after {
|
34
|
+
clear:both;
|
35
|
+
}
|
36
|
+
}
|
37
|
+
$g: $lite-max-grids;
|
38
|
+
@mixin create-columns($s) {
|
39
|
+
@for $i from 1 through $g {
|
40
|
+
.#{$s}-#{$i} {
|
41
|
+
width: 100% / $g * $i;
|
42
|
+
}
|
43
|
+
}
|
44
|
+
}
|
45
|
+
@mixin create-offset($size) {
|
46
|
+
$stop: $g - 1;
|
47
|
+
@for $i from 1 through $stop {
|
48
|
+
.#{$size}-offset-#{$i} {
|
49
|
+
margin-left: (100% / $g)*$i !important;
|
50
|
+
}
|
51
|
+
}
|
52
|
+
}
|
53
|
+
@mixin show-only($size) {
|
54
|
+
$show-small: none;
|
55
|
+
$show-medium: none;
|
56
|
+
$show-large: none;
|
57
|
+
$show-xlarge: none;
|
58
|
+
|
59
|
+
@if $size=="small" {
|
60
|
+
$show-small: inherit;
|
61
|
+
}
|
62
|
+
@if $size=="medium" {
|
63
|
+
$show-medium: inherit;
|
64
|
+
}
|
65
|
+
@if $size=="large" {
|
66
|
+
$show-large: inherit;
|
67
|
+
}
|
68
|
+
@if $size=="xlarge" {
|
69
|
+
$show-xlarge: inherit;
|
70
|
+
}
|
71
|
+
|
72
|
+
.small-only {
|
73
|
+
display:$show-small;
|
74
|
+
}
|
75
|
+
.medium-only {
|
76
|
+
display:$show-medium;
|
77
|
+
}
|
78
|
+
.large-only {
|
79
|
+
display:$show-large;
|
80
|
+
}
|
81
|
+
.xlarge-only {
|
82
|
+
display:$show-xlarge;
|
83
|
+
}
|
84
|
+
}
|
85
|
+
@mixin show-up($self) {
|
86
|
+
@if $self == "small" {
|
87
|
+
.small-up {
|
88
|
+
display:inherit;
|
89
|
+
&.text-middle {
|
90
|
+
display:flex;
|
91
|
+
}
|
92
|
+
}
|
93
|
+
.medium-up,.large-up, .xlarge-up {
|
94
|
+
display:none;
|
95
|
+
&.text-middle {
|
96
|
+
display:none;
|
97
|
+
}
|
98
|
+
}
|
99
|
+
}
|
100
|
+
|
101
|
+
@if $self == "medium" {
|
102
|
+
.small-up,.medium-up {
|
103
|
+
display:inherit;
|
104
|
+
&.text-middle {
|
105
|
+
display:flex;
|
106
|
+
}
|
107
|
+
}
|
108
|
+
.large-up, .xlarge-up {
|
109
|
+
display:none;
|
110
|
+
&.text-middle {
|
111
|
+
display:none;
|
112
|
+
}
|
113
|
+
}
|
114
|
+
}
|
115
|
+
|
116
|
+
@if $self == "large" {
|
117
|
+
.small-up, .medium-up, .large-up {
|
118
|
+
display:inherit;
|
119
|
+
&.text-middle {
|
120
|
+
display:flex;
|
121
|
+
}
|
122
|
+
}
|
123
|
+
}
|
124
|
+
|
125
|
+
@if $self=="xlarge" {
|
126
|
+
.small-up, .medium-up, .large-up, .xlarge-up {
|
127
|
+
display:inherit;
|
128
|
+
&.text-middle {
|
129
|
+
display:flex;
|
130
|
+
}
|
131
|
+
}
|
132
|
+
}
|
133
|
+
}
|
134
|
+
@mixin show-down($self) {
|
135
|
+
@if $self=="small" {
|
136
|
+
.small-down, .medium-down, .large-down, .xlarge-down {
|
137
|
+
display:inherit;
|
138
|
+
}
|
139
|
+
}
|
140
|
+
@if $self=="medium" {
|
141
|
+
.medium-down, .large-down, .xlarge-down {
|
142
|
+
display:inherit;
|
143
|
+
}
|
144
|
+
.small-down, {
|
145
|
+
display:none;
|
146
|
+
}
|
147
|
+
}
|
148
|
+
@if $self=="large" {
|
149
|
+
.large-down, .xlarge-down {
|
150
|
+
display:inherit;
|
151
|
+
}
|
152
|
+
.small-down, .medium-down {
|
153
|
+
display:none;
|
154
|
+
}
|
155
|
+
}
|
156
|
+
@if $self=="xlarge" {
|
157
|
+
.xlarge-down {
|
158
|
+
display:inherit;
|
159
|
+
}
|
160
|
+
.small-down, .medium-down, .large-down {
|
161
|
+
display:none;
|
162
|
+
}
|
163
|
+
}
|
164
|
+
}
|
165
|
+
@mixin box-sizing {
|
166
|
+
-webkit-box-sizing: border-box;
|
167
|
+
-moz-box-sizing: border-box;
|
168
|
+
box-sizing: border-box;
|
169
|
+
}
|
170
|
+
@mixin column-shortcut($s) {
|
171
|
+
@include create-columns($s);
|
172
|
+
@include create-offset($s);
|
173
|
+
@include show-only($s);
|
174
|
+
@include show-up($s);
|
175
|
+
@include show-down($s);
|
176
|
+
}
|
177
|
+
*,*:before,*:after {
|
178
|
+
margin:0;
|
179
|
+
padding:0;
|
180
|
+
@include box-sizing;
|
181
|
+
}
|
182
|
+
body {
|
183
|
+
font-size: $font-base-size;
|
184
|
+
@extend %clearfix;
|
185
|
+
}
|
186
|
+
.row {
|
187
|
+
margin:0 auto;
|
188
|
+
@extend %clearfix;
|
189
|
+
}
|
190
|
+
img {
|
191
|
+
width:auto;
|
192
|
+
max-width:100%;
|
193
|
+
height: auto !important;
|
194
|
+
}
|
195
|
+
[class*='small-'],[class*='medium-'],[class*='large-'],[class*='xlarge-'] {
|
196
|
+
float: left;
|
197
|
+
padding: 0.2rem $lite-gutter 0.2rem $lite-gutter;
|
198
|
+
min-height: 0.1em;
|
199
|
+
}
|
200
|
+
.text- {
|
201
|
+
&left {
|
202
|
+
text-align:left;
|
203
|
+
}
|
204
|
+
&justify {
|
205
|
+
text-align: justify;
|
206
|
+
}
|
207
|
+
¢er {
|
208
|
+
text-align: center;
|
209
|
+
}
|
210
|
+
&right {
|
211
|
+
text-align: right;
|
212
|
+
}
|
213
|
+
}
|
214
|
+
@media #{$bp-small-up} {
|
215
|
+
.row {
|
216
|
+
max-width: $row-width-small;
|
217
|
+
}
|
218
|
+
@include create-columns("small");
|
219
|
+
@include create-offset("small");
|
220
|
+
@include show-up("small");
|
221
|
+
//@include show-down("small");
|
222
|
+
}
|
223
|
+
@media #{$bp-small-only} {
|
224
|
+
@include show-only("small");
|
225
|
+
}
|
226
|
+
@media #{$bp-small-down} {
|
227
|
+
}
|
228
|
+
|
229
|
+
@media #{$bp-medium-up} {
|
230
|
+
.row {
|
231
|
+
max-width: $row-width-medium;
|
232
|
+
}
|
233
|
+
@include create-columns("medium");
|
234
|
+
@include create-offset("medium");
|
235
|
+
@include show-up("medium");}
|
236
|
+
//@include show-down("medium");
|
237
|
+
@media #{$bp-medium-only} {
|
238
|
+
@include show-only("medium");
|
239
|
+
}
|
240
|
+
@media #{$bp-medium-down} {
|
241
|
+
}
|
242
|
+
|
243
|
+
@media #{$bp-large-up} {
|
244
|
+
.row {
|
245
|
+
max-width: $row-width-large;
|
246
|
+
}
|
247
|
+
@include create-columns("large");
|
248
|
+
@include create-offset("large");
|
249
|
+
@include show-up("large");}
|
250
|
+
//@include show-down("large");
|
251
|
+
@media #{$bp-large-only} {
|
252
|
+
@include show-only("large");
|
253
|
+
}
|
254
|
+
@media #{$bp-large-down} {
|
255
|
+
}
|
256
|
+
|
257
|
+
@media #{$bp-xlarge-up} {
|
258
|
+
.row {
|
259
|
+
max-width: $row-width-xlarge;
|
260
|
+
}
|
261
|
+
@include create-columns("xlarge");
|
262
|
+
@include create-offset("xlarge");
|
263
|
+
@include show-up("xlarge");}
|
264
|
+
// @include show-down("xlarge");
|
265
|
+
@media #{$bp-xlarge-only} {
|
266
|
+
@include show-only("xlarge");
|
267
|
+
}
|
268
|
+
@media #{$bp-xlarge-down} {
|
269
|
+
}
|
@@ -0,0 +1 @@
|
|
1
|
+
@import "hawgrid_lite";
|
data/bin/console
ADDED
@@ -0,0 +1,14 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
|
3
|
+
require "bundler/setup"
|
4
|
+
require "hawgrid_rsp"
|
5
|
+
|
6
|
+
# You can add fixtures and/or initialization code here to make experimenting
|
7
|
+
# with your gem easier. You can also use a different console, if you like.
|
8
|
+
|
9
|
+
# (If you use this, don't forget to add pry to your Gemfile!)
|
10
|
+
# require "pry"
|
11
|
+
# Pry.start
|
12
|
+
|
13
|
+
require "irb"
|
14
|
+
IRB.start
|
data/bin/setup
ADDED
data/hawgrid_rsp.gemspec
ADDED
@@ -0,0 +1,32 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
lib = File.expand_path('../lib', __FILE__)
|
3
|
+
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
|
+
require 'hawgrid_rsp/version'
|
5
|
+
|
6
|
+
Gem::Specification.new do |spec|
|
7
|
+
spec.name = "hawgrid_rsp"
|
8
|
+
spec.version = HawgridRsp::VERSION
|
9
|
+
spec.authors = ["Hawry"]
|
10
|
+
spec.email = ["hawry@hawry.net"]
|
11
|
+
|
12
|
+
spec.summary = %q{Lightweight responsive CSS tool for web development.}
|
13
|
+
spec.description = %q{A lightweight tool to help you quickly create responsive web sites with the use of pure CSS.}
|
14
|
+
spec.homepage = "https://github.com/hawry/hawgrid-lite"
|
15
|
+
spec.license = "MIT"
|
16
|
+
|
17
|
+
# Prevent pushing this gem to RubyGems.org by setting 'allowed_push_host', or
|
18
|
+
# delete this section to allow pushing this gem to any host.
|
19
|
+
# if spec.respond_to?(:metadata)
|
20
|
+
# spec.metadata['allowed_push_host'] = "TODO: Set to 'http://mygemserver.com'"
|
21
|
+
# else
|
22
|
+
# raise "RubyGems 2.0 or newer is required to protect against public gem pushes."
|
23
|
+
# end
|
24
|
+
|
25
|
+
spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
26
|
+
spec.bindir = "exe"
|
27
|
+
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
28
|
+
spec.require_paths = ["lib"]
|
29
|
+
|
30
|
+
spec.add_development_dependency "bundler", "~> 1.10"
|
31
|
+
spec.add_development_dependency "rake", "~> 10.0"
|
32
|
+
end
|
data/lib/hawgrid_rsp.rb
ADDED
metadata
ADDED
@@ -0,0 +1,87 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: hawgrid_rsp
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.1.4.1
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Hawry
|
8
|
+
autorequire:
|
9
|
+
bindir: exe
|
10
|
+
cert_chain: []
|
11
|
+
date: 2015-10-01 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.10'
|
20
|
+
type: :development
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '1.10'
|
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
|
+
description: A lightweight tool to help you quickly create responsive web sites with
|
42
|
+
the use of pure CSS.
|
43
|
+
email:
|
44
|
+
- hawry@hawry.net
|
45
|
+
executables: []
|
46
|
+
extensions: []
|
47
|
+
extra_rdoc_files: []
|
48
|
+
files:
|
49
|
+
- ".gitignore"
|
50
|
+
- ".travis.yml"
|
51
|
+
- Gemfile
|
52
|
+
- LICENSE.txt
|
53
|
+
- README.md
|
54
|
+
- Rakefile
|
55
|
+
- app/assets/stylesheets/_lite_settings.scss
|
56
|
+
- app/assets/stylesheets/hawgrid_lite.scss
|
57
|
+
- app/assets/stylesheets/hawgrid_rsp.css.scss
|
58
|
+
- bin/console
|
59
|
+
- bin/setup
|
60
|
+
- hawgrid_rsp.gemspec
|
61
|
+
- lib/hawgrid_rsp.rb
|
62
|
+
- lib/hawgrid_rsp/version.rb
|
63
|
+
homepage: https://github.com/hawry/hawgrid-lite
|
64
|
+
licenses:
|
65
|
+
- MIT
|
66
|
+
metadata: {}
|
67
|
+
post_install_message:
|
68
|
+
rdoc_options: []
|
69
|
+
require_paths:
|
70
|
+
- lib
|
71
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - ">="
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '0'
|
76
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
77
|
+
requirements:
|
78
|
+
- - ">="
|
79
|
+
- !ruby/object:Gem::Version
|
80
|
+
version: '0'
|
81
|
+
requirements: []
|
82
|
+
rubyforge_project:
|
83
|
+
rubygems_version: 2.2.2
|
84
|
+
signing_key:
|
85
|
+
specification_version: 4
|
86
|
+
summary: Lightweight responsive CSS tool for web development.
|
87
|
+
test_files: []
|