titon-toolkit 1.0.0 → 1.0.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.
Files changed (40) hide show
  1. checksums.yaml +4 -4
  2. data/readme.md +1 -4
  3. data/scss/toolkit/_common.scss +9 -0
  4. data/scss/toolkit/components/accordion.scss +5 -5
  5. data/scss/toolkit/components/blackout.scss +1 -1
  6. data/scss/toolkit/components/breadcrumb.scss +13 -9
  7. data/scss/toolkit/components/button-group.scss +34 -26
  8. data/scss/toolkit/components/button.scss +4 -4
  9. data/scss/toolkit/components/carousel.scss +18 -18
  10. data/scss/toolkit/components/dropdown.scss +13 -13
  11. data/scss/toolkit/components/flyout.scss +6 -6
  12. data/scss/toolkit/components/grid.scss +2 -2
  13. data/scss/toolkit/components/input-group.scss +16 -15
  14. data/scss/toolkit/components/input.scss +20 -19
  15. data/scss/toolkit/components/label.scss +22 -17
  16. data/scss/toolkit/components/lazy-load.scss +1 -1
  17. data/scss/toolkit/components/matrix.scss +3 -3
  18. data/scss/toolkit/components/modal.scss +34 -34
  19. data/scss/toolkit/components/notice.scss +3 -3
  20. data/scss/toolkit/components/pagination.scss +4 -4
  21. data/scss/toolkit/components/pin.scss +2 -2
  22. data/scss/toolkit/components/popover.scss +12 -12
  23. data/scss/toolkit/components/progress.scss +25 -13
  24. data/scss/toolkit/components/showcase.scss +18 -18
  25. data/scss/toolkit/components/table.scss +10 -10
  26. data/scss/toolkit/components/tabs.scss +6 -6
  27. data/scss/toolkit/components/tooltip.scss +12 -12
  28. data/scss/toolkit/components/type-ahead.scss +7 -7
  29. data/scss/toolkit/effects/oval.scss +3 -3
  30. data/scss/toolkit/effects/pill.scss +17 -17
  31. data/scss/toolkit/effects/skew.scss +19 -19
  32. data/scss/toolkit/effects/visual.scss +4 -4
  33. data/scss/toolkit/layout/base.scss +3 -3
  34. data/scss/toolkit/layout/code.scss +1 -1
  35. data/scss/toolkit/layout/form.scss +44 -44
  36. data/scss/toolkit/mixins/_layout.scss +35 -0
  37. data/scss/toolkit/mixins/_state.scss +16 -12
  38. data/scss/toolkit/themes/titon.scss +2 -1
  39. data/version.md +1 -1
  40. metadata +9 -9
@@ -14,7 +14,7 @@ fieldset {
14
14
  border: 0;
15
15
  border-top: 1px solid $gray-dark;
16
16
 
17
- &.is-legendless {
17
+ &.#{$state-is-prefix}legendless {
18
18
  border: 0;
19
19
  padding: 0;
20
20
  }
@@ -41,26 +41,26 @@ input[type="search"] {
41
41
 
42
42
  // Required values to match browser restrictions
43
43
  label,
44
- .input-static {
44
+ .#{$vendor-prefix}input-static {
45
45
  font-size: inherit;
46
46
  line-height: normal;
47
47
  }
48
48
 
49
49
  //-------------------- Inputs --------------------//
50
50
 
51
- .input,
52
- .input-static,
53
- .input-radio,
54
- .input-checkbox {
51
+ .#{$vendor-prefix}input,
52
+ .#{$vendor-prefix}input-static,
53
+ .#{$vendor-prefix}input-radio,
54
+ .#{$vendor-prefix}input-checkbox {
55
55
  @include reset-inline-block;
56
56
  border: 1px solid $gray-dark;
57
57
  @include size-medium;
58
58
 
59
- &.small { @include size-small; }
60
- &.large { @include size-large; }
59
+ &.#{$size-small-class} { @include size-small; }
60
+ &.#{$size-large-class} { @include size-large; }
61
61
  }
62
62
 
63
- .input {
63
+ .#{$vendor-prefix}input {
64
64
  background: $gray-lightest;
65
65
  border-radius: $round;
66
66
  @include transition(all $default-transition);
@@ -86,17 +86,17 @@ label,
86
86
  }
87
87
  }
88
88
 
89
- .input-static,
90
- .input-radio,
91
- .input-checkbox {
89
+ .#{$vendor-prefix}input-static,
90
+ .#{$vendor-prefix}input-radio,
91
+ .#{$vendor-prefix}input-checkbox {
92
92
  background: transparent;
93
93
  border-color: transparent;
94
94
  padding-left: 0 !important;
95
95
  padding-right: 0 !important;
96
96
  }
97
97
 
98
- .input-radio,
99
- .input-checkbox {
98
+ .#{$vendor-prefix}input-radio,
99
+ .#{$vendor-prefix}input-checkbox {
100
100
  padding: 0;
101
101
 
102
102
  input[type="checkbox"],
@@ -108,92 +108,92 @@ label,
108
108
  }
109
109
  }
110
110
 
111
- select.input {
111
+ select.#{$vendor-prefix}input {
112
112
  -webkit-appearance: none;
113
113
  padding: $medium-padding - .05rem; // fixes vertical alignment
114
114
  }
115
115
 
116
- select.input[multiple] {
116
+ select.#{$vendor-prefix}input[multiple] {
117
117
  min-height: 150px;
118
118
  max-height: 500px;
119
119
  }
120
120
 
121
- textarea.input {
121
+ textarea.#{$vendor-prefix}input {
122
122
  line-height: 135%;
123
123
  min-height: 150px;
124
124
  }
125
125
 
126
126
  //-------------------- Fields, Labels --------------------//
127
127
 
128
- .field {
128
+ .#{$vendor-prefix}field {
129
129
  margin-bottom: $margin;
130
130
 
131
- &.is-required {
132
- .field-label { font-weight: bold; }
131
+ &.#{$state-is-prefix}required {
132
+ .#{$vendor-prefix}field-label { font-weight: bold; }
133
133
  }
134
134
  }
135
135
 
136
- .field:not(.is-disabled) {
137
- &.is-error {
138
- .input {
136
+ .#{$vendor-prefix}field:not(.#{$state-is-prefix}disabled) {
137
+ &.#{$state-is-prefix}error {
138
+ .#{$vendor-prefix}input {
139
139
  border-color: $error;
140
140
 
141
141
  &:focus { box-shadow: 0 0 5px $error-light; }
142
142
  }
143
143
 
144
- .input-radio,
145
- .input-checkbox {
144
+ .#{$vendor-prefix}input-radio,
145
+ .#{$vendor-prefix}input-checkbox {
146
146
  color: $error-dark;
147
147
  }
148
148
  }
149
149
 
150
- &.is-success {
151
- .input {
150
+ &.#{$state-is-prefix}success {
151
+ .#{$vendor-prefix}input {
152
152
  border-color: $success;
153
153
 
154
154
  &:focus { box-shadow: 0 0 5px $success-light; }
155
155
  }
156
156
 
157
- .input-radio,
158
- .input-checkbox {
157
+ .#{$vendor-prefix}input-radio,
158
+ .#{$vendor-prefix}input-checkbox {
159
159
  color: $success-dark;
160
160
  }
161
161
  }
162
162
  }
163
163
 
164
- .field-label {
164
+ .#{$vendor-prefix}field-label {
165
165
  display: block;
166
166
  vertical-align: middle;
167
167
  margin-bottom: .5em;
168
168
  }
169
169
 
170
- .field-help {
170
+ .#{$vendor-prefix}field-help {
171
171
  margin-top: .5em;
172
172
  font-size: $small-size;
173
173
  }
174
174
 
175
- .form-actions {
175
+ .#{$vendor-prefix}form-actions {
176
176
  text-align: center;
177
177
  }
178
178
 
179
179
  //-------------------- Modifiers --------------------//
180
180
 
181
- .form--horizontal {
182
- .field { @include grid-row; }
181
+ .#{$vendor-prefix}form--horizontal {
182
+ .#{$vendor-prefix}field { @include grid-row; }
183
183
 
184
- .field-label {
184
+ .#{$vendor-prefix}field-label {
185
185
  text-align: right;
186
186
  border: 1px solid transparent; // matches input sizes
187
187
  padding-top: $medium-padding;
188
188
  }
189
189
 
190
- .field-col { padding-left: $margin; }
190
+ .#{$vendor-prefix}field-col { padding-left: $margin; }
191
191
  }
192
192
 
193
- .form--inline {
194
- .field,
195
- .field-label,
196
- .form-actions {
193
+ .#{$vendor-prefix}form--inline {
194
+ .#{$vendor-prefix}field,
195
+ .#{$vendor-prefix}field-label,
196
+ .#{$vendor-prefix}form-actions {
197
197
  display: inline-block;
198
198
  vertical-align: middle;
199
199
  line-height: normal;
@@ -201,11 +201,11 @@ textarea.input {
201
201
  margin-bottom: $margin / 2;
202
202
  }
203
203
 
204
- .field-label { margin: 0 ($margin / 2) 0 0; }
205
- .field-help { display: none; }
204
+ .#{$vendor-prefix}field-label { margin: 0 ($margin / 2) 0 0; }
205
+ .#{$vendor-prefix}field-help { display: none; }
206
206
 
207
- .input-radio,
208
- .input-checkbox {
207
+ .#{$vendor-prefix}input-radio,
208
+ .#{$vendor-prefix}input-checkbox {
209
209
  padding: $medium-padding 0;
210
210
  }
211
211
  }
@@ -44,4 +44,39 @@
44
44
  @mixin size-large {
45
45
  font-size: $large-size;
46
46
  padding: $large-padding;
47
+ }
48
+
49
+ // Generate a self selector or parent selector for assigning size classes
50
+ @mixin is-size($size, $self: true, $parent: false) {
51
+ $selectors: ();
52
+
53
+ @if $self {
54
+ $selectors: $selectors, unquote("&." + $size);
55
+ }
56
+
57
+ @if $parent {
58
+ $selectors: $selectors, unquote("." + $size + " &");
59
+ }
60
+
61
+ #{$selectors} {
62
+ @content;
63
+ }
64
+ }
65
+
66
+ @mixin is-small($self: true, $parent: false) {
67
+ @include is-size($size-small-class, $self, $parent) {
68
+ @content;
69
+ }
70
+ }
71
+
72
+ @mixin is-medium($self: true, $parent: false) {
73
+ @include is-size($size-medium-class, $self, $parent) {
74
+ @content;
75
+ }
76
+ }
77
+
78
+ @mixin is-large($self: true, $parent: false) {
79
+ @include is-size($size-large-class, $self, $parent) {
80
+ @content;
81
+ }
47
82
  }
@@ -1,32 +1,36 @@
1
1
 
2
2
  @mixin is-active {
3
- .is-active > &,
4
- .is-active > li > &,
5
- &.is-active,
6
- &.is-active:hover { @content; }
3
+ .#{$state-is-prefix}active > &,
4
+ .#{$state-is-prefix}active > li > &,
5
+ &.#{$state-is-prefix}active,
6
+ &.#{$state-is-prefix}active:hover { @content; }
7
+ }
8
+
9
+ @mixin is-active-parent {
10
+ .#{$state-is-prefix}active & { @content; }
7
11
  }
8
12
 
9
13
  @mixin is-disabled {
10
- .is-disabled > &,
11
- .is-disabled > li > &,
12
- &.is-disabled,
13
- &.is-disabled:hover,
14
+ .#{$state-is-prefix}disabled > &,
15
+ .#{$state-is-prefix}disabled > li > &,
16
+ &.#{$state-is-prefix}disabled,
17
+ &.#{$state-is-prefix}disabled:hover,
14
18
  &[disabled],
15
19
  &[disabled]:hover { @content; }
16
20
  }
17
21
 
18
22
  @mixin is-info {
19
- &.is-info { @content; }
23
+ &.#{$state-is-prefix}info { @content; }
20
24
  }
21
25
 
22
26
  @mixin is-error {
23
- &.is-error { @content; }
27
+ &.#{$state-is-prefix}error { @content; }
24
28
  }
25
29
 
26
30
  @mixin is-warning {
27
- &.is-warning { @content; }
31
+ &.#{$state-is-prefix}warning { @content; }
28
32
  }
29
33
 
30
34
  @mixin is-success {
31
- &.is-success { @content; }
35
+ &.#{$state-is-prefix}success { @content; }
32
36
  }
@@ -251,7 +251,8 @@ mark { background: lighten($warning-light, 25%); }
251
251
  @content;
252
252
  }
253
253
 
254
- .label {
254
+ .label,
255
+ .label--badge {
255
256
  @include label-style($default-light, $default-dark);
256
257
 
257
258
  &.is-info { @include label-style($info-light, $info-dark); }
data/version.md CHANGED
@@ -1 +1 @@
1
- 1.0.0
1
+ 1.0.1
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: titon-toolkit
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Titon
@@ -9,34 +9,34 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-12-04 00:00:00.000000000 Z
12
+ date: 2013-12-13 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: sass
16
16
  requirement: !ruby/object:Gem::Requirement
17
17
  requirements:
18
- - - '>='
18
+ - - ">="
19
19
  - !ruby/object:Gem::Version
20
20
  version: 3.2.0
21
21
  type: :runtime
22
22
  prerelease: false
23
23
  version_requirements: !ruby/object:Gem::Requirement
24
24
  requirements:
25
- - - '>='
25
+ - - ">="
26
26
  - !ruby/object:Gem::Version
27
27
  version: 3.2.0
28
28
  - !ruby/object:Gem::Dependency
29
29
  name: compass
30
30
  requirement: !ruby/object:Gem::Requirement
31
31
  requirements:
32
- - - '>='
32
+ - - ">="
33
33
  - !ruby/object:Gem::Version
34
34
  version: '0.11'
35
35
  type: :runtime
36
36
  prerelease: false
37
37
  version_requirements: !ruby/object:Gem::Requirement
38
38
  requirements:
39
- - - '>='
39
+ - - ">="
40
40
  - !ruby/object:Gem::Version
41
41
  version: '0.11'
42
42
  description: A collection of extensible front-end UI components for the responsive
@@ -106,17 +106,17 @@ require_paths:
106
106
  - lib
107
107
  required_ruby_version: !ruby/object:Gem::Requirement
108
108
  requirements:
109
- - - '>='
109
+ - - ">="
110
110
  - !ruby/object:Gem::Version
111
111
  version: '0'
112
112
  required_rubygems_version: !ruby/object:Gem::Requirement
113
113
  requirements:
114
- - - '>='
114
+ - - ">="
115
115
  - !ruby/object:Gem::Version
116
116
  version: '0'
117
117
  requirements: []
118
118
  rubyforge_project:
119
- rubygems_version: 2.0.3
119
+ rubygems_version: 2.1.11
120
120
  signing_key:
121
121
  specification_version: 4
122
122
  summary: Provides Titon Toolkit Sass files for use in projects.