kentucky 3.0.3 → 3.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/app/assets/stylesheets/base/_normalize.scss +137 -140
- data/kentucky.gemspec +2 -0
- data/lib/kentucky/generator.rb +71 -5
- data/lib/kentucky/version.rb +1 -1
- data/readme.md +0 -9
- 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: c27b2845d374b4def8cdd420c30dfec7c3dd48aa
|
4
|
+
data.tar.gz: 2240ed23ca58fe0499795d3be901c8639f7e373f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 96d0790d05df1ff6c4d80f9537d23edb2e728b6f3d84d7753157f091beaff59c12d75bff4bc3b81ee2c2d5bb748498dac5393fe2f75caddb5814da0e1cc787fe
|
7
|
+
data.tar.gz: 80861c44828620a0a8b4d470707f5f40fa155e90daa3f8cce4e76e0f0a5984937e0d89f2000830290a902bf5a542128017dddf52892e289564f1b9d95eac0754
|
data/CHANGELOG.md
CHANGED
@@ -7,7 +7,7 @@
|
|
7
7
|
|
8
8
|
// 1. Set default box-sizing declaration to border-box.
|
9
9
|
// 2. Set default font family to base font family variable.
|
10
|
-
// 3. Prevent
|
10
|
+
// 3. Prevent adjustments of font size after orientation changes in IE and iOS.
|
11
11
|
html {
|
12
12
|
box-sizing: border-box; // 1
|
13
13
|
font-family: $font-family-base; // 2
|
@@ -33,53 +33,54 @@ body {
|
|
33
33
|
|
34
34
|
/// HTML5 display definitions
|
35
35
|
|
36
|
-
//
|
37
|
-
//
|
38
|
-
//
|
36
|
+
// Add the correct display in IE 9-.
|
37
|
+
// 1. Add the correct display in Edge, IE, and Firefox.
|
38
|
+
// 2. Add the correct display in IE.
|
39
39
|
article,
|
40
40
|
aside,
|
41
|
-
details,
|
41
|
+
details, // 1
|
42
42
|
figcaption,
|
43
43
|
figure,
|
44
44
|
footer,
|
45
45
|
header,
|
46
|
-
|
47
|
-
main,
|
46
|
+
main, // 2
|
48
47
|
menu,
|
49
48
|
nav,
|
50
49
|
section,
|
51
|
-
summary {
|
50
|
+
summary { // 1
|
52
51
|
display: block;
|
53
52
|
}
|
54
53
|
|
55
|
-
//
|
56
|
-
// 2. Normalize vertical alignment of `progress` in Chrome, Firefox, and Opera.
|
54
|
+
// Add the correct display in IE 9-.
|
57
55
|
audio,
|
58
56
|
canvas,
|
59
57
|
progress,
|
60
58
|
video {
|
61
|
-
display: inline-block;
|
62
|
-
vertical-align: baseline; // 2
|
59
|
+
display: inline-block;
|
63
60
|
}
|
64
61
|
|
65
|
-
//
|
66
|
-
// Remove excess height in iOS 5 devices.
|
62
|
+
// Add the correct display in iOS 4-7.
|
67
63
|
audio:not([controls]) {
|
68
64
|
display: none;
|
69
65
|
height: 0;
|
70
66
|
}
|
71
67
|
|
72
|
-
//
|
73
|
-
|
74
|
-
|
75
|
-
|
68
|
+
// Add the correct vertical alignment in Chrome, Firefox, and Opera.
|
69
|
+
progress {
|
70
|
+
vertical-align: baseline;
|
71
|
+
}
|
72
|
+
|
73
|
+
// Add the correct display in IE 10-.
|
74
|
+
// 1. Add the correct display in IE.
|
75
|
+
template, // 1
|
76
|
+
[hidden] {
|
76
77
|
display: none;
|
77
78
|
}
|
78
79
|
|
79
80
|
|
80
81
|
/// Links
|
81
82
|
|
82
|
-
// Remove the gray background
|
83
|
+
// Remove the gray background on active links in IE 10.
|
83
84
|
a {
|
84
85
|
background-color: transparent;
|
85
86
|
}
|
@@ -93,41 +94,51 @@ a:hover {
|
|
93
94
|
|
94
95
|
/// Text-level semantics
|
95
96
|
|
96
|
-
//
|
97
|
+
// 1. Remove the bottom border in Firefox 39-.
|
98
|
+
// 2. Add the correct text decoration in Chrome, Edge, IE, Opera, and Safari.
|
97
99
|
abbr[title] {
|
98
|
-
border-bottom:
|
100
|
+
border-bottom: 0; // 1
|
101
|
+
text-decoration: underline; // 2
|
102
|
+
text-decoration: underline dotted; // 2
|
99
103
|
}
|
100
104
|
|
101
|
-
//
|
105
|
+
// Prevent the duplicate application of `bolder` by the next rule in Safari 6.
|
102
106
|
b,
|
103
107
|
strong {
|
104
|
-
font-weight:
|
108
|
+
font-weight: inherit;
|
105
109
|
}
|
106
110
|
|
107
|
-
//
|
111
|
+
// Add the correct font weight in Chrome, Edge, and Safari.
|
112
|
+
b,
|
113
|
+
strong {
|
114
|
+
font-weight: bolder;
|
115
|
+
}
|
116
|
+
|
117
|
+
// Add the correct font style in Android 4.3-.
|
108
118
|
dfn {
|
109
119
|
font-style: italic;
|
110
120
|
}
|
111
121
|
|
112
|
-
//
|
113
|
-
// contexts in Firefox
|
122
|
+
// Correct the font size and margin on `h1` elements within `section` and
|
123
|
+
// `article` contexts in Chrome, Firefox, and Safari.
|
114
124
|
h1 {
|
115
125
|
margin: .67em 0;
|
116
126
|
font-size: 2em;
|
117
127
|
}
|
118
128
|
|
119
|
-
//
|
129
|
+
// Add the correct background and color in IE 9-.
|
120
130
|
mark {
|
121
131
|
background: #ff0;
|
122
132
|
color: #000;
|
123
133
|
}
|
124
134
|
|
125
|
-
//
|
135
|
+
// Add the correct font size in all browsers.
|
126
136
|
small {
|
127
137
|
font-size: 80%;
|
128
138
|
}
|
129
139
|
|
130
|
-
// Prevent `sub` and `sup` affecting
|
140
|
+
// Prevent `sub` and `sup` elements from affecting the line height in
|
141
|
+
// all browsers.
|
131
142
|
sub,
|
132
143
|
sup {
|
133
144
|
position: relative;
|
@@ -147,12 +158,12 @@ sub {
|
|
147
158
|
|
148
159
|
/// Embedded content
|
149
160
|
|
150
|
-
// Remove border
|
161
|
+
// Remove the border on images inside links in IE 10-.
|
151
162
|
img {
|
152
|
-
border:
|
163
|
+
border-style: none;
|
153
164
|
}
|
154
165
|
|
155
|
-
//
|
166
|
+
// Hide the overflow in IE.
|
156
167
|
svg:not(:root) {
|
157
168
|
overflow: hidden;
|
158
169
|
}
|
@@ -160,163 +171,149 @@ svg:not(:root) {
|
|
160
171
|
|
161
172
|
/// Grouping content
|
162
173
|
|
163
|
-
//
|
174
|
+
// 1. Correct the inheritance and scaling of font size in all browsers.
|
175
|
+
// 2. Correct the odd `em` font sizing in all browsers.
|
176
|
+
code,
|
177
|
+
kbd,
|
178
|
+
pre,
|
179
|
+
samp {
|
180
|
+
font-family: monospace, monospace; // 1
|
181
|
+
font-size: 1em; // 2
|
182
|
+
}
|
183
|
+
|
184
|
+
// Add the correct margin in IE 8.
|
164
185
|
figure {
|
165
186
|
margin: 1em 40px;
|
166
187
|
}
|
167
188
|
|
168
|
-
//
|
189
|
+
// 1. Add the correct box sizing in Firefox.
|
190
|
+
// 2. Show the overflow in Edge and IE.
|
169
191
|
hr {
|
170
|
-
box-sizing: content-box;
|
171
|
-
height: 0;
|
172
|
-
|
173
|
-
|
174
|
-
// Contain overflow in all browsers.
|
175
|
-
pre {
|
176
|
-
overflow: auto;
|
177
|
-
}
|
178
|
-
|
179
|
-
// Address odd `em`-unit font size rendering in all browsers.
|
180
|
-
code,
|
181
|
-
kbd,
|
182
|
-
pre,
|
183
|
-
samp {
|
184
|
-
font-family: monospace, monospace;
|
185
|
-
font-size: 1em;
|
192
|
+
box-sizing: content-box; // 1
|
193
|
+
height: 0; // 1
|
194
|
+
overflow: visible; // 2
|
186
195
|
}
|
187
196
|
|
188
197
|
|
189
198
|
/// Form elements
|
190
|
-
/// Known limitation: by default, Chrome and Safari on OS X allow very limited styling
|
191
|
-
/// of `select`, unless a `border` property is set.
|
192
199
|
|
193
|
-
//
|
194
|
-
// 2. Correct color not being inherited.
|
195
|
-
// Known issue: affects color of disabled elements.
|
196
|
-
// 3. Correct font properties not being inherited.
|
200
|
+
// Change font properties to `inherit` in all browsers (opinionated).
|
197
201
|
|
198
202
|
button,
|
199
203
|
input,
|
200
204
|
optgroup,
|
201
205
|
select,
|
202
206
|
textarea {
|
203
|
-
|
204
|
-
color: inherit; // 2
|
205
|
-
font: inherit; // 3
|
207
|
+
font: inherit;
|
206
208
|
}
|
207
209
|
|
208
|
-
//
|
209
|
-
|
210
|
-
|
210
|
+
// Restore the font weight unset by the previous rule.
|
211
|
+
optgroup {
|
212
|
+
font-weight: bold;
|
211
213
|
}
|
212
214
|
|
213
|
-
//
|
214
|
-
//
|
215
|
-
//
|
216
|
-
// Correct `select` style inheritance in Firefox.
|
215
|
+
// Show the overflow in IE.
|
216
|
+
// 1. Show the overflow in Edge.
|
217
|
+
// 2. Show the overflow in Edge, Firefox, and IE.
|
217
218
|
button,
|
218
|
-
|
219
|
-
|
219
|
+
input, // 1
|
220
|
+
select { // 2
|
221
|
+
overflow: visible;
|
220
222
|
}
|
221
223
|
|
222
|
-
//
|
223
|
-
//
|
224
|
-
// 3. Improve usability and consistency of cursor style between image-type `input` and others.
|
224
|
+
// Remove the margin in Safari.
|
225
|
+
// 1. Remove the margin in Firefox and Safari.
|
225
226
|
button,
|
226
|
-
|
227
|
-
|
228
|
-
|
229
|
-
|
230
|
-
cursor: pointer; // 3
|
231
|
-
}
|
232
|
-
|
233
|
-
// Re-set default cursor for disabled elements.
|
234
|
-
button[disabled],
|
235
|
-
html input[disabled] {
|
236
|
-
cursor: default;
|
237
|
-
}
|
238
|
-
|
239
|
-
// Remove inner padding and border in Firefox 4+.
|
240
|
-
button::-moz-focus-inner,
|
241
|
-
input::-moz-focus-inner {
|
242
|
-
padding: 0;
|
243
|
-
border: 0;
|
227
|
+
input,
|
228
|
+
select,
|
229
|
+
textarea { // 1
|
230
|
+
margin: 0;
|
244
231
|
}
|
245
232
|
|
246
|
-
//
|
247
|
-
// the
|
248
|
-
|
249
|
-
|
233
|
+
// Remove the inheritance of text transform in Edge, Firefox, and IE.
|
234
|
+
// 1. Remove the inheritance of text transform in Firefox.
|
235
|
+
button,
|
236
|
+
select { // 1
|
237
|
+
text-transform: none;
|
250
238
|
}
|
251
239
|
|
252
|
-
//
|
253
|
-
|
254
|
-
|
255
|
-
|
256
|
-
|
257
|
-
|
258
|
-
padding: 0; // 1
|
240
|
+
// Change the cursor in all browsers (opinionated).
|
241
|
+
button,
|
242
|
+
[type="button"],
|
243
|
+
[type="reset"],
|
244
|
+
[type="submit"] {
|
245
|
+
cursor: pointer;
|
259
246
|
}
|
260
247
|
|
261
|
-
//
|
262
|
-
|
263
|
-
|
264
|
-
input[type="number"]::-webkit-inner-spin-button,
|
265
|
-
input[type="number"]::-webkit-outer-spin-button {
|
266
|
-
height: auto;
|
248
|
+
// Restore the default cursor to disabled elements unset by the previous rule.
|
249
|
+
[disabled] {
|
250
|
+
cursor: default;
|
267
251
|
}
|
268
252
|
|
269
|
-
// 1.
|
270
|
-
//
|
271
|
-
//
|
272
|
-
|
273
|
-
|
274
|
-
|
253
|
+
// 1. Prevent a WebKit bug where (2) destroys native `audio` and `video`
|
254
|
+
// controls in Android 4.
|
255
|
+
// 2. Correct the inability to style clickable types in iOS.
|
256
|
+
button,
|
257
|
+
html [type="button"], // 1
|
258
|
+
[type="reset"],
|
259
|
+
[type="submit"] {
|
260
|
+
-webkit-appearance: button; // 2
|
275
261
|
}
|
276
262
|
|
277
|
-
// Remove inner
|
278
|
-
|
279
|
-
|
280
|
-
|
281
|
-
|
282
|
-
-webkit-appearance: none;
|
263
|
+
// Remove the inner border and padding in Firefox.
|
264
|
+
button::-moz-focus-inner,
|
265
|
+
input::-moz-focus-inner {
|
266
|
+
border: 0;
|
267
|
+
padding: 0;
|
283
268
|
}
|
284
269
|
|
285
|
-
//
|
286
|
-
|
287
|
-
|
288
|
-
|
289
|
-
border: 1px solid $color-border-base;
|
270
|
+
// Restore the focus styles unset by the previous rule.
|
271
|
+
button:-moz-focusring,
|
272
|
+
input:-moz-focusring {
|
273
|
+
outline: 1px dotted ButtonText;
|
290
274
|
}
|
291
275
|
|
292
|
-
// 1.
|
293
|
-
// 2.
|
276
|
+
// 1. Correct the text wrapping in Edge and IE.
|
277
|
+
// 2. Correct the color inheritance from `fieldset` elements in IE.
|
278
|
+
// 3. Remove the padding so developers are not caught out when they zero out
|
279
|
+
// `fieldset` elements in all browsers.
|
294
280
|
legend {
|
295
|
-
|
296
|
-
|
281
|
+
box-sizing: border-box; // 1
|
282
|
+
color: inherit; // 2
|
283
|
+
display: table; // 1
|
284
|
+
max-width: 100%; // 1
|
285
|
+
padding: 0; // 3
|
286
|
+
white-space: normal; // 1
|
297
287
|
}
|
298
288
|
|
299
|
-
// Remove default vertical scrollbar in IE
|
289
|
+
// Remove the default vertical scrollbar in IE.
|
300
290
|
textarea {
|
301
291
|
overflow: auto;
|
302
292
|
}
|
303
293
|
|
304
|
-
//
|
305
|
-
//
|
306
|
-
|
307
|
-
|
294
|
+
// 1. Add the correct box sizing in IE 10-.
|
295
|
+
// 2. Remove the padding in IE 10-.
|
296
|
+
[type="checkbox"],
|
297
|
+
[type="radio"] {
|
298
|
+
box-sizing: border-box; // 1
|
299
|
+
padding: 0; // 2
|
308
300
|
}
|
309
301
|
|
302
|
+
// Correct the cursor style of increment and decrement buttons in Chrome.
|
303
|
+
[type="number"]::-webkit-inner-spin-button,
|
304
|
+
[type="number"]::-webkit-outer-spin-button {
|
305
|
+
height: auto;
|
306
|
+
}
|
310
307
|
|
311
|
-
/// Tables
|
312
308
|
|
313
|
-
//
|
314
|
-
|
315
|
-
|
316
|
-
border-spacing: 0;
|
309
|
+
// Correct the odd appearance of search inputs in Chrome and Safari.
|
310
|
+
[type="search"] {
|
311
|
+
-webkit-appearance: textfield;
|
317
312
|
}
|
318
313
|
|
319
|
-
|
320
|
-
|
321
|
-
|
314
|
+
// Remove the inner padding and cancel buttons in Chrome on OS X and
|
315
|
+
// Safari on OS X.
|
316
|
+
[type="search"]::-webkit-search-cancel-button,
|
317
|
+
[type="search"]::-webkit-search-decoration {
|
318
|
+
-webkit-appearance: none;
|
322
319
|
}
|
data/kentucky.gemspec
CHANGED
@@ -15,6 +15,8 @@ Gem::Specification.new do |s|
|
|
15
15
|
Kentucky is a class-independent front-end framework built as a standard project starting point.
|
16
16
|
DESC
|
17
17
|
|
18
|
+
#s.rubyforge_project = "bourbon"
|
19
|
+
|
18
20
|
s.files = `git ls-files`.split("\n")
|
19
21
|
s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
|
20
22
|
s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
|
data/lib/kentucky/generator.rb
CHANGED
@@ -7,10 +7,28 @@ module Kentucky
|
|
7
7
|
map ['-v', '--version'] => :version
|
8
8
|
|
9
9
|
desc 'install', 'Install Kentucky into your project'
|
10
|
-
method_options :path => :string, :dir => :boolean
|
10
|
+
method_options :path => :string, :force => :boolean, :dir => :boolean
|
11
11
|
def install
|
12
|
-
|
13
|
-
|
12
|
+
if kentucky_files_already_exist? && !options[:force]
|
13
|
+
puts "Kentucky files already installed, doing nothing."
|
14
|
+
else
|
15
|
+
create_site_structure if !options[:force]
|
16
|
+
install_files
|
17
|
+
puts "Kentucky files installed to #{install_path_kentucky}/"
|
18
|
+
end
|
19
|
+
end
|
20
|
+
|
21
|
+
desc 'update', 'Update Kentucky'
|
22
|
+
method_options :path => :string
|
23
|
+
def update
|
24
|
+
if kentucky_files_already_exist?
|
25
|
+
remove_kentucky_directory
|
26
|
+
create_kentucky_directory
|
27
|
+
install_files
|
28
|
+
puts "Kentucky files updated."
|
29
|
+
else
|
30
|
+
puts "No existing Kentucky installation. Doing nothing."
|
31
|
+
end
|
14
32
|
end
|
15
33
|
|
16
34
|
desc 'version', 'Show Kentucky version'
|
@@ -20,6 +38,33 @@ module Kentucky
|
|
20
38
|
|
21
39
|
private
|
22
40
|
|
41
|
+
def kentucky_files_already_exist?
|
42
|
+
install_path_kentucky.exist?
|
43
|
+
end
|
44
|
+
|
45
|
+
def create_site_structure
|
46
|
+
make_install_directory
|
47
|
+
if options[:dir]
|
48
|
+
dirs = %w(images scripts scss css)
|
49
|
+
dirs.each do |dir|
|
50
|
+
FileUtils.mkdir(install_path + Pathname.new(dir))
|
51
|
+
end
|
52
|
+
end
|
53
|
+
create_kentucky_directory
|
54
|
+
end
|
55
|
+
|
56
|
+
def make_install_directory
|
57
|
+
FileUtils.mkdir_p(install_path)
|
58
|
+
end
|
59
|
+
|
60
|
+
def create_kentucky_directory
|
61
|
+
FileUtils.mkdir(install_path_kentucky)
|
62
|
+
end
|
63
|
+
|
64
|
+
def remove_kentucky_directory
|
65
|
+
FileUtils.rm_rf(install_path_kentucky)
|
66
|
+
end
|
67
|
+
|
23
68
|
def install_path
|
24
69
|
if options[:path]
|
25
70
|
path = Pathname.new(options[:path])
|
@@ -36,15 +81,36 @@ module Kentucky
|
|
36
81
|
end
|
37
82
|
|
38
83
|
def copy_in_scss_files
|
39
|
-
FileUtils.cp_r(kentucky_stylesheets,
|
84
|
+
FileUtils.cp_r(kentucky_stylesheets, install_path_kentucky)
|
85
|
+
FileUtils.cp(master_stylesheet, install_path_scss)
|
86
|
+
end
|
87
|
+
|
88
|
+
def install_path_scss
|
89
|
+
if options[:dir]
|
90
|
+
return install_path + Pathname.new("scss")
|
91
|
+
else
|
92
|
+
return install_path
|
93
|
+
end
|
94
|
+
end
|
95
|
+
|
96
|
+
def install_path_kentucky
|
97
|
+
return install_path_scss + Pathname.new("kentucky")
|
98
|
+
end
|
99
|
+
|
100
|
+
def master_stylesheet
|
101
|
+
Dir["#{stylesheets_directory}/style.scss"]
|
40
102
|
end
|
41
103
|
|
42
104
|
def kentucky_stylesheets
|
43
105
|
Dir["#{kentucky_directory}/*"]
|
44
106
|
end
|
45
107
|
|
108
|
+
def all_stylesheets
|
109
|
+
Dir["#{stylesheets_directory}/*"]
|
110
|
+
end
|
111
|
+
|
46
112
|
def kentucky_directory
|
47
|
-
File.join(stylesheets_directory)
|
113
|
+
File.join(stylesheets_directory, "kentucky")
|
48
114
|
end
|
49
115
|
|
50
116
|
def stylesheets_directory
|
data/lib/kentucky/version.rb
CHANGED
data/readme.md
CHANGED
@@ -1,15 +1,6 @@
|
|
1
1
|
# Kentucky
|
2
2
|
###### Straight from the source.
|
3
3
|
|
4
|
-
# Usage
|
5
|
-
|
6
|
-
- Run `gem install kentucky` from your Terminal app of choice.
|
7
|
-
- Navigate to your project's `scss` folder.
|
8
|
-
- Run `kentucky install`.
|
9
|
-
- Code and stuff!
|
10
|
-
|
11
|
-
---
|
12
|
-
|
13
4
|
[![Gem Version](https://badge.fury.io/rb/kentucky.svg)](https://badge.fury.io/rb/kentucky)
|
14
5
|
|
15
6
|
**Kentucky is a front-end project kickstart system to allow for rapidly beginning CSS development on a myriad of projects.**
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: kentucky
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.0
|
4
|
+
version: 3.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Aaron Clemmer
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date:
|
13
|
+
date: 2016-03-22 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: sass
|