semantic-ui-rails 0.0.1 → 0.0.2.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (47) hide show
  1. checksums.yaml +4 -4
  2. data/lib/generators/semantic/install/templates/semantic-ui/collections.less +6 -6
  3. data/lib/generators/semantic/install/templates/semantic-ui/elements.less +11 -11
  4. data/lib/generators/semantic/install/templates/semantic-ui/modules.less +16 -18
  5. data/lib/generators/semantic/install/templates/semantic-ui/views.less +5 -6
  6. data/lib/generators/semantic/install/templates/semantic-ui.js +19 -21
  7. data/lib/semantic/ui/rails/version.rb +1 -1
  8. data/semantic-ui-rails.gemspec +5 -0
  9. data/semantic.thor +153 -0
  10. data/vendor/assets/fonts/{icons.eot → semantic-ui/icons.eot} +0 -0
  11. data/vendor/assets/fonts/{icons.svg → semantic-ui/icons.svg} +0 -0
  12. data/vendor/assets/fonts/{icons.ttf → semantic-ui/icons.ttf} +0 -0
  13. data/vendor/assets/fonts/{icons.woff → semantic-ui/icons.woff} +0 -0
  14. data/vendor/assets/javascripts/semantic-ui/{accordion.js → modules/accordion.js} +0 -0
  15. data/vendor/assets/javascripts/semantic-ui/{behavior → modules/behavior}/api.js +0 -0
  16. data/vendor/assets/javascripts/semantic-ui/{behavior → modules/behavior}/colorize.js +0 -0
  17. data/vendor/assets/javascripts/semantic-ui/{behavior → modules/behavior}/form.js +80 -34
  18. data/vendor/assets/javascripts/semantic-ui/{behavior → modules/behavior}/state.js +0 -0
  19. data/vendor/assets/javascripts/semantic-ui/{chatroom.js → modules/chatroom.js} +0 -0
  20. data/vendor/assets/javascripts/semantic-ui/{checkbox.js → modules/checkbox.js} +0 -0
  21. data/vendor/assets/javascripts/semantic-ui/{dimmer.js → modules/dimmer.js} +4 -5
  22. data/vendor/assets/javascripts/semantic-ui/{dropdown.js → modules/dropdown.js} +6 -6
  23. data/vendor/assets/javascripts/semantic-ui/{modal.js → modules/modal.js} +0 -0
  24. data/vendor/assets/javascripts/semantic-ui/{nag.js → modules/nag.js} +0 -0
  25. data/vendor/assets/javascripts/semantic-ui/{popup.js → modules/popup.js} +0 -0
  26. data/vendor/assets/javascripts/semantic-ui/{rating.js → modules/rating.js} +0 -0
  27. data/vendor/assets/javascripts/semantic-ui/{search.js → modules/search.js} +0 -0
  28. data/vendor/assets/javascripts/semantic-ui/{shape.js → modules/shape.js} +0 -0
  29. data/vendor/assets/javascripts/semantic-ui/{sidebar.js → modules/sidebar.js} +0 -0
  30. data/vendor/assets/javascripts/semantic-ui/{tab.js → modules/tab.js} +0 -0
  31. data/vendor/assets/javascripts/semantic-ui/{transition.js → modules/transition.js} +0 -0
  32. data/vendor/assets/javascripts/semantic-ui/{video.js → modules/video.js} +0 -0
  33. data/vendor/assets/stylesheets/semantic-ui/.less +38 -0
  34. data/vendor/assets/stylesheets/semantic-ui/collections/.less +12 -0
  35. data/vendor/assets/stylesheets/semantic-ui/collections/menu.less +8 -5
  36. data/vendor/assets/stylesheets/semantic-ui/elements/.less +11 -0
  37. data/vendor/assets/stylesheets/semantic-ui/elements/icon.less +39 -1
  38. data/vendor/assets/stylesheets/semantic-ui/elements/label.less +20 -1
  39. data/vendor/assets/stylesheets/semantic-ui/modules/.less +16 -0
  40. data/vendor/assets/stylesheets/semantic-ui/views/.less +5 -0
  41. data/vendor/assets/stylesheets/semantic-ui/views/list.less +17 -0
  42. data/vendor/assets/stylesheets/semantic-ui/views/{statistic.less → statistic.css} +27 -34
  43. metadata +88 -30
  44. data/vendor/assets/javascripts/semantic-ui/carousel.js +0 -327
  45. data/vendor/assets/stylesheets/semantic-ui/modules/carousel.less +0 -71
  46. data/vendor/assets/stylesheets/semantic-ui/modules/extra.transition.less +0 -1197
  47. data/vendor/assets/stylesheets/semantic-ui/views/sitemap.less +0 -47
@@ -1,327 +0,0 @@
1
- /* ******************************
2
- Semantic Module: Carousel
3
- Author: Jack Lukic
4
- Notes: First Commit May 28, 2013
5
-
6
- A carousel alternates between
7
- several pieces of content in sequence.
8
-
9
- ****************************** */
10
-
11
- ;(function ( $, window, document, undefined ) {
12
-
13
- $.fn.carousel = function(parameters) {
14
- var
15
- $allModules = $(this),
16
-
17
- settings = $.extend(true, {}, $.fn.carousel.settings, parameters),
18
-
19
- eventNamespace = '.' + settings.namespace,
20
- moduleNamespace = 'module-' + settings.namespace,
21
- moduleSelector = $allModules.selector || '',
22
-
23
- time = new Date().getTime(),
24
- performance = [],
25
-
26
- query = arguments[0],
27
- methodInvoked = (typeof query == 'string'),
28
- queryArguments = [].slice.call(arguments, 1),
29
- invokedResponse
30
- ;
31
-
32
- $allModules
33
- .each(function() {
34
- var
35
- $module = $(this),
36
- $arrows = $(settings.selector.arrows),
37
- $leftArrow = $(settings.selector.leftArrow),
38
- $rightArrow = $(settings.selector.rightArrow),
39
- $content = $(settings.selector.content),
40
- $navigation = $(settings.selector.navigation),
41
- $navItem = $(settings.selector.navItem),
42
-
43
- selector = $module.selector || '',
44
- element = this,
45
- instance = $module.data('module-' + settings.namespace),
46
-
47
- className = settings.className,
48
- namespace = settings.namespace,
49
- errors = settings.errors,
50
- module
51
- ;
52
-
53
- module = {
54
-
55
- initialize: function() {
56
- module.openingAnimation();
57
- module.marquee.autoAdvance();
58
- $leftArrow
59
- .on('click', module.marquee.left)
60
- ;
61
- $rightArrow
62
- .on('click', module.marquee.right)
63
- ;
64
- $navItem
65
- .on('click', module.marquee.change)
66
- ;
67
- },
68
-
69
- destroy: function() {
70
- module.verbose('Destroying previous module for', $module);
71
- $module
72
- .off(eventNamespace)
73
- ;
74
- },
75
-
76
- left: function() {
77
- var
78
- $activeContent = $content.filter('.' + className.active),
79
- currentIndex = $content.index($activeContent),
80
- imageCount = $content.size(),
81
- newIndex = (currentIndex - 1 != -1)
82
- ? (currentIndex - 1)
83
- : (imageCount - 1)
84
- ;
85
- $navItem
86
- .eq(newIndex)
87
- .trigger('click')
88
- ;
89
- },
90
-
91
- right: function() {
92
- var
93
- $activeContent = $content.filter('.' + className.active),
94
- currentIndex = $content.index($activeContent),
95
- imageCount = $content.size(),
96
- newIndex = (currentIndex + 1 != imageCount)
97
- ? (currentIndex + 1)
98
- : 0
99
- ;
100
- $navItem
101
- .eq(newIndex)
102
- .trigger('click')
103
- ;
104
- },
105
-
106
- change: function() {
107
- var
108
- $selected = $(this),
109
- selectedIndex = $navItem.index($selected),
110
- $selectedImage = $content.eq(selectedIndex)
111
- ;
112
- module.marquee.autoAdvance();
113
- $selected
114
- .addClass('active')
115
- .siblings()
116
- .removeClass('active')
117
- ;
118
- $selectedImage
119
- .addClass('active animated fadeIn')
120
- .siblings('.' + className.active)
121
- .removeClass('animated fadeIn scaleIn')
122
- .animate({
123
- opacity: 0
124
- }, 500, function(){
125
- $(this)
126
- .removeClass('active')
127
- .removeAttr('style')
128
- ;
129
- })
130
- ;
131
- },
132
-
133
- autoAdvance: function() {
134
- clearInterval(module.timer);
135
- module.timer = setInterval(module.marquee.right, settings.duration);
136
- },
137
-
138
- setting: function(name, value) {
139
- if(value !== undefined) {
140
- if( $.isPlainObject(name) ) {
141
- module.verbose('Modifying settings object', name, value);
142
- $.extend(true, settings, name);
143
- }
144
- else {
145
- module.verbose('Modifying setting', name, value);
146
- settings[name] = value;
147
- }
148
- }
149
- else {
150
- return settings[name];
151
- }
152
- },
153
- internal: function(name, value) {
154
- if(value !== undefined) {
155
- if( $.isPlainObject(name) ) {
156
- module.verbose('Modifying internal property', name, value);
157
- $.extend(true, module, name);
158
- }
159
- else {
160
- module.verbose('Changing internal method to', value);
161
- module[name] = value;
162
- }
163
- }
164
- else {
165
- return module[name];
166
- }
167
- },
168
- debug: function() {
169
- if(settings.debug) {
170
- if(settings.performance) {
171
- module.performance.log(arguments);
172
- }
173
- else {
174
- module.debug = Function.prototype.bind.call(console.info, console, settings.moduleName + ':');
175
- module.debug.apply(console, arguments);
176
- }
177
- }
178
- },
179
- verbose: function() {
180
- if(settings.verbose && settings.debug) {
181
- if(settings.performance) {
182
- module.performance.log(arguments);
183
- }
184
- else {
185
- module.verbose = Function.prototype.bind.call(console.info, console, settings.moduleName + ':');
186
- module.verbose.apply(console, arguments);
187
- }
188
- }
189
- },
190
- error: function() {
191
- module.error = Function.prototype.bind.call(console.error, console, settings.moduleName + ':');
192
- module.error.apply(console, arguments);
193
- },
194
- performance: {
195
- log: function(message) {
196
- var
197
- currentTime,
198
- executionTime,
199
- previousTime
200
- ;
201
- if(settings.performance) {
202
- currentTime = new Date().getTime();
203
- previousTime = time || currentTime;
204
- executionTime = currentTime - previousTime;
205
- time = currentTime;
206
- performance.push({
207
- 'Element' : element,
208
- 'Name' : message[0],
209
- 'Arguments' : message[1] || 'None',
210
- 'Execution Time' : executionTime
211
- });
212
- clearTimeout(module.performance.timer);
213
- module.performance.timer = setTimeout(module.performance.display, 100);
214
- }
215
- },
216
- display: function() {
217
- var
218
- title = settings.moduleName,
219
- caption = settings.moduleName + ': ' + moduleSelector + '(' + $allModules.size() + ' elements)',
220
- totalExecutionTime = 0
221
- ;
222
- if(moduleSelector) {
223
- title += ' Performance (' + moduleSelector + ')';
224
- }
225
- if( (console.group !== undefined || console.table !== undefined) && performance.length > 0) {
226
- console.groupCollapsed(title);
227
- if(console.table) {
228
- $.each(performance, function(index, data) {
229
- totalExecutionTime += data['Execution Time'];
230
- });
231
- console.table(performance);
232
- }
233
- else {
234
- $.each(performance, function(index, data) {
235
- totalExecutionTime += data['Execution Time'];
236
- console.log(data['Name'] + ': ' + data['Execution Time']+'ms');
237
- });
238
- }
239
- console.log('Total Execution Time:', totalExecutionTime +'ms');
240
- console.groupEnd();
241
- performance = [];
242
- time = false;
243
- }
244
- }
245
- },
246
- invoke: function(query, passedArguments, context) {
247
- var
248
- maxDepth,
249
- found
250
- ;
251
- passedArguments = passedArguments || queryArguments;
252
- context = element || context;
253
- if(typeof query == 'string' && instance !== undefined) {
254
- query = query.split(/[\. ]/);
255
- maxDepth = query.length - 1;
256
- $.each(query, function(depth, value) {
257
- if( $.isPlainObject( instance[value] ) && (depth != maxDepth) ) {
258
- instance = instance[value];
259
- return true;
260
- }
261
- else if( instance[value] !== undefined ) {
262
- found = instance[value];
263
- return true;
264
- }
265
- module.error(errors.method);
266
- return false;
267
- });
268
- }
269
- if ( $.isFunction( found ) ) {
270
- return found.apply(context, passedArguments);
271
- }
272
- return found || false;
273
- }
274
- };
275
-
276
- if(methodInvoked) {
277
- if(instance === undefined) {
278
- module.initialize();
279
- }
280
- module.invoke(query);
281
- }
282
- else {
283
- if(instance !== undefined) {
284
- module.destroy();
285
- }
286
- module.initialize();
287
- }
288
- })
289
- ;
290
- return (invokedResponse !== undefined)
291
- ? invokedResponse
292
- : this
293
- ;
294
- };
295
-
296
- $.fn.carousel.settings = {
297
-
298
- name : 'Carousel',
299
- namespace : 'carousel',
300
-
301
- verbose : true,
302
- debug : true,
303
- performance : true,
304
-
305
- // delegated event context
306
- duration: 5000,
307
-
308
- errors : {
309
- method : 'The method you called is not defined.'
310
- },
311
-
312
- selector : {
313
- arrows : '.arrow',
314
- leftArrow : '.left.arrow',
315
- rightArrow : '.right.arrow',
316
- content : '.content',
317
- navigation : '.navigation',
318
- navItem : '.navigation .icon'
319
- },
320
-
321
- className : {
322
- active : 'active'
323
- }
324
-
325
- };
326
-
327
- })( jQuery, window , document );
@@ -1,71 +0,0 @@
1
- /*
2
- * # Semantic Carousel
3
- * http://github.com/quirkyinc/semantic
4
- *
5
- *
6
- * Copyright 2013 Contributors
7
- * Released under the MIT license
8
- * http://opensource.org/licenses/MIT
9
- *
10
- * Released: June 03, 2013
11
- */
12
-
13
-
14
- /*******************************
15
- Carousel
16
- *******************************/
17
-
18
- .ui.carousel {
19
- position: relative;
20
- overflow: hidden;
21
- }
22
- .ui.carousel .arrow {
23
- position: absolute;
24
- font-size: 1.5em;
25
- top: 50%;
26
- left: 0%;
27
- margin-top: -0.5em;
28
- z-index: 10;
29
- }
30
- .ui.carousel .right.arrow {
31
- left: auto;
32
- right: 0%;
33
- }
34
-
35
- .ui.carousel .slides {
36
- position: relative;
37
- width: 200%;
38
- width: 9999px;
39
- overflow: hidden;
40
- font-size: 0em;
41
- }
42
- .ui.carousel .slides .slide {
43
- display: inline-block;
44
- height: 100%;
45
- font-size: 1rem;
46
- }
47
- .ui.carousel .slides .slide > img {
48
- display: block;
49
- width: 100%;
50
- }
51
-
52
-
53
- /*--------------------
54
- Loading State
55
- ---------------------*/
56
-
57
- /* On Form */
58
- .ui.carousel.loading {
59
- position: relative;
60
- }
61
- .ui.carousel.loading:after {
62
- position: absolute;
63
- top: 0%;
64
- left: 0%;
65
- content: '';
66
-
67
- width: 100%;
68
- height: 100%;
69
- background: rgba(255, 255, 255, 0.8) url(../images/loader-large.gif) no-repeat 50% 50%;
70
- visibility: visible;
71
- }