semantic-ui-rails 0.10.3 → 0.11.0
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.
- checksums.yaml +4 -4
- data/app/assets/javascripts/semantic-ui/modules/accordion.js +10 -10
- data/app/assets/javascripts/semantic-ui/modules/behavior/api.js +11 -11
- data/app/assets/javascripts/semantic-ui/modules/behavior/form.js +10 -10
- data/app/assets/javascripts/semantic-ui/modules/behavior/state.js +10 -10
- data/app/assets/javascripts/semantic-ui/modules/checkbox.js +10 -10
- data/app/assets/javascripts/semantic-ui/modules/dimmer.js +11 -11
- data/app/assets/javascripts/semantic-ui/modules/dropdown.js +10 -10
- data/app/assets/javascripts/semantic-ui/modules/modal.js +56 -48
- data/app/assets/javascripts/semantic-ui/modules/nag.js +10 -10
- data/app/assets/javascripts/semantic-ui/modules/popup.js +30 -20
- data/app/assets/javascripts/semantic-ui/modules/rating.js +10 -10
- data/app/assets/javascripts/semantic-ui/modules/search.js +10 -10
- data/app/assets/javascripts/semantic-ui/modules/shape.js +10 -10
- data/app/assets/javascripts/semantic-ui/modules/sidebar.js +10 -10
- data/app/assets/javascripts/semantic-ui/modules/tab.js +11 -11
- data/app/assets/javascripts/semantic-ui/modules/transition.js +233 -110
- data/app/assets/javascripts/semantic-ui/modules/video.js +10 -10
- data/app/assets/stylesheets/semantic-ui/modules/accordion.less +0 -1
- data/app/assets/stylesheets/semantic-ui/modules/dimmer.less +1 -11
- data/app/assets/stylesheets/semantic-ui/modules/popup.less +1 -0
- data/app/assets/stylesheets/semantic-ui/modules/transition.less +5 -4
- data/lib/semantic/ui/rails/version.rb +1 -1
- 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: cab5036ffec4486fce505b51df41cb468e363d51
|
4
|
+
data.tar.gz: b20a43e6556b586ca7aa6cf941d57fa3ea1c13af
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 671da5c38cf30ec6550ac6ea81379018e3921fa84a1999efef65a6b3d071336df02861d818e8cf54590f842bfd9192f9d00cae3ff6182f8894dcde72a351d652
|
7
|
+
data.tar.gz: 4a5e0a34a8e948a39e3988fe159289af6724e91cf940583314378e5175740730294052ec69b0e3fb0258a7414d1336e340add0a5a02015a7c77f70d93b0b82bb
|
@@ -305,13 +305,14 @@ $.fn.accordion = function(parameters) {
|
|
305
305
|
},
|
306
306
|
invoke: function(query, passedArguments, context) {
|
307
307
|
var
|
308
|
+
object = instance,
|
308
309
|
maxDepth,
|
309
310
|
found,
|
310
311
|
response
|
311
312
|
;
|
312
313
|
passedArguments = passedArguments || queryArguments;
|
313
314
|
context = element || context;
|
314
|
-
if(typeof query == 'string' &&
|
315
|
+
if(typeof query == 'string' && object !== undefined) {
|
315
316
|
query = query.split(/[\. ]/);
|
316
317
|
maxDepth = query.length - 1;
|
317
318
|
$.each(query, function(depth, value) {
|
@@ -319,22 +320,21 @@ $.fn.accordion = function(parameters) {
|
|
319
320
|
? value + query[depth + 1].charAt(0).toUpperCase() + query[depth + 1].slice(1)
|
320
321
|
: query
|
321
322
|
;
|
322
|
-
if( $.isPlainObject(
|
323
|
-
|
323
|
+
if( $.isPlainObject( object[camelCaseValue] ) && (depth != maxDepth) ) {
|
324
|
+
object = object[camelCaseValue];
|
324
325
|
}
|
325
|
-
else if(
|
326
|
-
found =
|
326
|
+
else if( object[camelCaseValue] !== undefined ) {
|
327
|
+
found = object[camelCaseValue];
|
327
328
|
return false;
|
328
329
|
}
|
329
|
-
else if( $.isPlainObject(
|
330
|
-
|
330
|
+
else if( $.isPlainObject( object[value] ) && (depth != maxDepth) ) {
|
331
|
+
object = object[value];
|
331
332
|
}
|
332
|
-
else if(
|
333
|
-
found =
|
333
|
+
else if( object[value] !== undefined ) {
|
334
|
+
found = object[value];
|
334
335
|
return false;
|
335
336
|
}
|
336
337
|
else {
|
337
|
-
module.error(error.method, query);
|
338
338
|
return false;
|
339
339
|
}
|
340
340
|
});
|
@@ -450,13 +450,14 @@
|
|
450
450
|
},
|
451
451
|
invoke: function(query, passedArguments, context) {
|
452
452
|
var
|
453
|
+
object = instance,
|
453
454
|
maxDepth,
|
454
455
|
found,
|
455
456
|
response
|
456
457
|
;
|
457
458
|
passedArguments = passedArguments || queryArguments;
|
458
459
|
context = element || context;
|
459
|
-
if(typeof query == 'string' &&
|
460
|
+
if(typeof query == 'string' && object !== undefined) {
|
460
461
|
query = query.split(/[\. ]/);
|
461
462
|
maxDepth = query.length - 1;
|
462
463
|
$.each(query, function(depth, value) {
|
@@ -464,22 +465,21 @@
|
|
464
465
|
? value + query[depth + 1].charAt(0).toUpperCase() + query[depth + 1].slice(1)
|
465
466
|
: query
|
466
467
|
;
|
467
|
-
if( $.isPlainObject(
|
468
|
-
|
468
|
+
if( $.isPlainObject( object[camelCaseValue] ) && (depth != maxDepth) ) {
|
469
|
+
object = object[camelCaseValue];
|
469
470
|
}
|
470
|
-
else if(
|
471
|
-
|
472
|
-
}
|
473
|
-
else if( instance[value] !== undefined ) {
|
474
|
-
found = instance[value];
|
471
|
+
else if( object[camelCaseValue] !== undefined ) {
|
472
|
+
found = object[camelCaseValue];
|
475
473
|
return false;
|
476
474
|
}
|
477
|
-
else if(
|
478
|
-
|
475
|
+
else if( $.isPlainObject( object[value] ) && (depth != maxDepth) ) {
|
476
|
+
object = object[value];
|
477
|
+
}
|
478
|
+
else if( object[value] !== undefined ) {
|
479
|
+
found = object[value];
|
479
480
|
return false;
|
480
481
|
}
|
481
482
|
else {
|
482
|
-
module.error(error.method, query);
|
483
483
|
return false;
|
484
484
|
}
|
485
485
|
});
|
@@ -486,13 +486,14 @@ $.fn.form = function(fields, parameters) {
|
|
486
486
|
},
|
487
487
|
invoke: function(query, passedArguments, context) {
|
488
488
|
var
|
489
|
+
object = instance,
|
489
490
|
maxDepth,
|
490
491
|
found,
|
491
492
|
response
|
492
493
|
;
|
493
494
|
passedArguments = passedArguments || queryArguments;
|
494
495
|
context = element || context;
|
495
|
-
if(typeof query == 'string' &&
|
496
|
+
if(typeof query == 'string' && object !== undefined) {
|
496
497
|
query = query.split(/[\. ]/);
|
497
498
|
maxDepth = query.length - 1;
|
498
499
|
$.each(query, function(depth, value) {
|
@@ -500,22 +501,21 @@ $.fn.form = function(fields, parameters) {
|
|
500
501
|
? value + query[depth + 1].charAt(0).toUpperCase() + query[depth + 1].slice(1)
|
501
502
|
: query
|
502
503
|
;
|
503
|
-
if( $.isPlainObject(
|
504
|
-
|
504
|
+
if( $.isPlainObject( object[camelCaseValue] ) && (depth != maxDepth) ) {
|
505
|
+
object = object[camelCaseValue];
|
505
506
|
}
|
506
|
-
else if(
|
507
|
-
found =
|
507
|
+
else if( object[camelCaseValue] !== undefined ) {
|
508
|
+
found = object[camelCaseValue];
|
508
509
|
return false;
|
509
510
|
}
|
510
|
-
else if( $.isPlainObject(
|
511
|
-
|
511
|
+
else if( $.isPlainObject( object[value] ) && (depth != maxDepth) ) {
|
512
|
+
object = object[value];
|
512
513
|
}
|
513
|
-
else if(
|
514
|
-
found =
|
514
|
+
else if( object[value] !== undefined ) {
|
515
|
+
found = object[value];
|
515
516
|
return false;
|
516
517
|
}
|
517
518
|
else {
|
518
|
-
module.error(error.method, query);
|
519
519
|
return false;
|
520
520
|
}
|
521
521
|
});
|
@@ -542,13 +542,14 @@ $.fn.state = function(parameters) {
|
|
542
542
|
},
|
543
543
|
invoke: function(query, passedArguments, context) {
|
544
544
|
var
|
545
|
+
object = instance,
|
545
546
|
maxDepth,
|
546
547
|
found,
|
547
548
|
response
|
548
549
|
;
|
549
550
|
passedArguments = passedArguments || queryArguments;
|
550
551
|
context = element || context;
|
551
|
-
if(typeof query == 'string' &&
|
552
|
+
if(typeof query == 'string' && object !== undefined) {
|
552
553
|
query = query.split(/[\. ]/);
|
553
554
|
maxDepth = query.length - 1;
|
554
555
|
$.each(query, function(depth, value) {
|
@@ -556,22 +557,21 @@ $.fn.state = function(parameters) {
|
|
556
557
|
? value + query[depth + 1].charAt(0).toUpperCase() + query[depth + 1].slice(1)
|
557
558
|
: query
|
558
559
|
;
|
559
|
-
if( $.isPlainObject(
|
560
|
-
|
560
|
+
if( $.isPlainObject( object[camelCaseValue] ) && (depth != maxDepth) ) {
|
561
|
+
object = object[camelCaseValue];
|
561
562
|
}
|
562
|
-
else if(
|
563
|
-
found =
|
563
|
+
else if( object[camelCaseValue] !== undefined ) {
|
564
|
+
found = object[camelCaseValue];
|
564
565
|
return false;
|
565
566
|
}
|
566
|
-
else if( $.isPlainObject(
|
567
|
-
|
567
|
+
else if( $.isPlainObject( object[value] ) && (depth != maxDepth) ) {
|
568
|
+
object = object[value];
|
568
569
|
}
|
569
|
-
else if(
|
570
|
-
found =
|
570
|
+
else if( object[value] !== undefined ) {
|
571
|
+
found = object[value];
|
571
572
|
return false;
|
572
573
|
}
|
573
574
|
else {
|
574
|
-
module.error(error.method, query);
|
575
575
|
return false;
|
576
576
|
}
|
577
577
|
});
|
@@ -236,13 +236,14 @@ $.fn.checkbox = function(parameters) {
|
|
236
236
|
},
|
237
237
|
invoke: function(query, passedArguments, context) {
|
238
238
|
var
|
239
|
+
object = instance,
|
239
240
|
maxDepth,
|
240
241
|
found,
|
241
242
|
response
|
242
243
|
;
|
243
244
|
passedArguments = passedArguments || queryArguments;
|
244
245
|
context = element || context;
|
245
|
-
if(typeof query == 'string' &&
|
246
|
+
if(typeof query == 'string' && object !== undefined) {
|
246
247
|
query = query.split(/[\. ]/);
|
247
248
|
maxDepth = query.length - 1;
|
248
249
|
$.each(query, function(depth, value) {
|
@@ -250,22 +251,21 @@ $.fn.checkbox = function(parameters) {
|
|
250
251
|
? value + query[depth + 1].charAt(0).toUpperCase() + query[depth + 1].slice(1)
|
251
252
|
: query
|
252
253
|
;
|
253
|
-
if( $.isPlainObject(
|
254
|
-
|
254
|
+
if( $.isPlainObject( object[camelCaseValue] ) && (depth != maxDepth) ) {
|
255
|
+
object = object[camelCaseValue];
|
255
256
|
}
|
256
|
-
else if(
|
257
|
-
found =
|
257
|
+
else if( object[camelCaseValue] !== undefined ) {
|
258
|
+
found = object[camelCaseValue];
|
258
259
|
return false;
|
259
260
|
}
|
260
|
-
else if( $.isPlainObject(
|
261
|
-
|
261
|
+
else if( $.isPlainObject( object[value] ) && (depth != maxDepth) ) {
|
262
|
+
object = object[value];
|
262
263
|
}
|
263
|
-
else if(
|
264
|
-
found =
|
264
|
+
else if( object[value] !== undefined ) {
|
265
|
+
found = object[value];
|
265
266
|
return false;
|
266
267
|
}
|
267
268
|
else {
|
268
|
-
module.error(error.method, query);
|
269
269
|
return false;
|
270
270
|
}
|
271
271
|
});
|
@@ -462,13 +462,14 @@ $.fn.dimmer = function(parameters) {
|
|
462
462
|
},
|
463
463
|
invoke: function(query, passedArguments, context) {
|
464
464
|
var
|
465
|
+
object = instance,
|
465
466
|
maxDepth,
|
466
467
|
found,
|
467
468
|
response
|
468
469
|
;
|
469
470
|
passedArguments = passedArguments || queryArguments;
|
470
471
|
context = element || context;
|
471
|
-
if(typeof query == 'string' &&
|
472
|
+
if(typeof query == 'string' && object !== undefined) {
|
472
473
|
query = query.split(/[\. ]/);
|
473
474
|
maxDepth = query.length - 1;
|
474
475
|
$.each(query, function(depth, value) {
|
@@ -476,22 +477,21 @@ $.fn.dimmer = function(parameters) {
|
|
476
477
|
? value + query[depth + 1].charAt(0).toUpperCase() + query[depth + 1].slice(1)
|
477
478
|
: query
|
478
479
|
;
|
479
|
-
if( $.isPlainObject(
|
480
|
-
|
480
|
+
if( $.isPlainObject( object[camelCaseValue] ) && (depth != maxDepth) ) {
|
481
|
+
object = object[camelCaseValue];
|
481
482
|
}
|
482
|
-
else if(
|
483
|
-
|
484
|
-
}
|
485
|
-
else if( instance[value] !== undefined ) {
|
486
|
-
found = instance[value];
|
483
|
+
else if( object[camelCaseValue] !== undefined ) {
|
484
|
+
found = object[camelCaseValue];
|
487
485
|
return false;
|
488
486
|
}
|
489
|
-
else if(
|
490
|
-
|
487
|
+
else if( $.isPlainObject( object[value] ) && (depth != maxDepth) ) {
|
488
|
+
object = object[value];
|
489
|
+
}
|
490
|
+
else if( object[value] !== undefined ) {
|
491
|
+
found = object[value];
|
491
492
|
return false;
|
492
493
|
}
|
493
494
|
else {
|
494
|
-
module.error(error.method, query);
|
495
495
|
return false;
|
496
496
|
}
|
497
497
|
});
|
@@ -464,7 +464,6 @@ $.fn.dropdown = function(parameters) {
|
|
464
464
|
queue : false
|
465
465
|
})
|
466
466
|
;
|
467
|
-
$currentMenu.transition('force repaint');
|
468
467
|
}
|
469
468
|
else if(settings.transition == 'slide down') {
|
470
469
|
$currentMenu
|
@@ -712,13 +711,14 @@ $.fn.dropdown = function(parameters) {
|
|
712
711
|
},
|
713
712
|
invoke: function(query, passedArguments, context) {
|
714
713
|
var
|
714
|
+
object = instance,
|
715
715
|
maxDepth,
|
716
716
|
found,
|
717
717
|
response
|
718
718
|
;
|
719
719
|
passedArguments = passedArguments || queryArguments;
|
720
720
|
context = element || context;
|
721
|
-
if(typeof query == 'string' &&
|
721
|
+
if(typeof query == 'string' && object !== undefined) {
|
722
722
|
query = query.split(/[\. ]/);
|
723
723
|
maxDepth = query.length - 1;
|
724
724
|
$.each(query, function(depth, value) {
|
@@ -726,18 +726,18 @@ $.fn.dropdown = function(parameters) {
|
|
726
726
|
? value + query[depth + 1].charAt(0).toUpperCase() + query[depth + 1].slice(1)
|
727
727
|
: query
|
728
728
|
;
|
729
|
-
if( $.isPlainObject(
|
730
|
-
|
729
|
+
if( $.isPlainObject( object[camelCaseValue] ) && (depth != maxDepth) ) {
|
730
|
+
object = object[camelCaseValue];
|
731
731
|
}
|
732
|
-
else if(
|
733
|
-
found =
|
732
|
+
else if( object[camelCaseValue] !== undefined ) {
|
733
|
+
found = object[camelCaseValue];
|
734
734
|
return false;
|
735
735
|
}
|
736
|
-
else if( $.isPlainObject(
|
737
|
-
|
736
|
+
else if( $.isPlainObject( object[value] ) && (depth != maxDepth) ) {
|
737
|
+
object = object[value];
|
738
738
|
}
|
739
|
-
else if(
|
740
|
-
found =
|
739
|
+
else if( object[value] !== undefined ) {
|
740
|
+
found = object[value];
|
741
741
|
return false;
|
742
742
|
}
|
743
743
|
else {
|
@@ -71,9 +71,11 @@ $.fn.modal = function(parameters) {
|
|
71
71
|
$dimmable = $context
|
72
72
|
.dimmer({
|
73
73
|
closable : false,
|
74
|
-
useCSS :
|
75
|
-
|
76
|
-
|
74
|
+
useCSS : true,
|
75
|
+
duration: {
|
76
|
+
show : settings.duration * 0.9,
|
77
|
+
hide : settings.duration * 1.1
|
78
|
+
}
|
77
79
|
})
|
78
80
|
.dimmer('add content', $module)
|
79
81
|
;
|
@@ -281,18 +283,22 @@ $.fn.modal = function(parameters) {
|
|
281
283
|
},
|
282
284
|
|
283
285
|
hideDimmer: function() {
|
284
|
-
if(
|
285
|
-
module.debug('Hiding dimmer');
|
286
|
-
if(settings.closable) {
|
287
|
-
$dimmer
|
288
|
-
.off('click' + eventNamespace)
|
289
|
-
;
|
290
|
-
}
|
291
|
-
$dimmable.dimmer('hide');
|
292
|
-
}
|
293
|
-
else {
|
286
|
+
if( !module.is.active() ) {
|
294
287
|
module.debug('Dimmer is not visible cannot hide');
|
288
|
+
return;
|
289
|
+
}
|
290
|
+
module.debug('Hiding dimmer');
|
291
|
+
if(settings.closable) {
|
292
|
+
$dimmer
|
293
|
+
.off('click' + eventNamespace)
|
294
|
+
;
|
295
295
|
}
|
296
|
+
$dimmable.dimmer('hide', function() {
|
297
|
+
$module
|
298
|
+
.transition('reset')
|
299
|
+
;
|
300
|
+
module.remove.active();
|
301
|
+
});
|
296
302
|
},
|
297
303
|
|
298
304
|
hideModal: function(callback) {
|
@@ -300,29 +306,31 @@ $.fn.modal = function(parameters) {
|
|
300
306
|
? callback
|
301
307
|
: function(){}
|
302
308
|
;
|
303
|
-
if( module.is.active() ) {
|
304
|
-
module.debug('
|
305
|
-
|
306
|
-
|
307
|
-
|
308
|
-
|
309
|
-
|
310
|
-
|
311
|
-
|
312
|
-
|
313
|
-
|
314
|
-
|
315
|
-
|
316
|
-
|
317
|
-
|
318
|
-
|
319
|
-
|
320
|
-
|
321
|
-
|
322
|
-
|
323
|
-
|
324
|
-
|
309
|
+
if( !module.is.active() ) {
|
310
|
+
module.debug('Cannot hide modal it is not active');
|
311
|
+
return;
|
312
|
+
}
|
313
|
+
module.debug('Hiding modal');
|
314
|
+
module.remove.keyboardShortcuts();
|
315
|
+
if(settings.transition && $.fn.transition !== undefined && $module.transition('is supported')) {
|
316
|
+
$module
|
317
|
+
.transition(settings.transition + ' out', settings.duration, function() {
|
318
|
+
module.remove.active();
|
319
|
+
module.restore.focus();
|
320
|
+
callback();
|
321
|
+
})
|
322
|
+
;
|
323
|
+
}
|
324
|
+
else {
|
325
|
+
$module
|
326
|
+
.fadeOut(settings.duration, settings.easing, function() {
|
327
|
+
module.remove.active();
|
328
|
+
module.restore.focus();
|
329
|
+
callback();
|
330
|
+
})
|
331
|
+
;
|
325
332
|
}
|
333
|
+
$.proxy(settings.onHide, element)();
|
326
334
|
},
|
327
335
|
|
328
336
|
hideAll: function(callback) {
|
@@ -414,8 +422,8 @@ $.fn.modal = function(parameters) {
|
|
414
422
|
return $module.hasClass(className.active);
|
415
423
|
},
|
416
424
|
modernBrowser: function() {
|
417
|
-
//
|
418
|
-
return (
|
425
|
+
// appName for IE11 reports 'Netscape' can no longer use
|
426
|
+
return !(window.ActiveXObject || "ActiveXObject" in window);
|
419
427
|
}
|
420
428
|
},
|
421
429
|
|
@@ -569,13 +577,14 @@ $.fn.modal = function(parameters) {
|
|
569
577
|
},
|
570
578
|
invoke: function(query, passedArguments, context) {
|
571
579
|
var
|
580
|
+
object = instance,
|
572
581
|
maxDepth,
|
573
582
|
found,
|
574
583
|
response
|
575
584
|
;
|
576
585
|
passedArguments = passedArguments || queryArguments;
|
577
586
|
context = element || context;
|
578
|
-
if(typeof query == 'string' &&
|
587
|
+
if(typeof query == 'string' && object !== undefined) {
|
579
588
|
query = query.split(/[\. ]/);
|
580
589
|
maxDepth = query.length - 1;
|
581
590
|
$.each(query, function(depth, value) {
|
@@ -583,22 +592,21 @@ $.fn.modal = function(parameters) {
|
|
583
592
|
? value + query[depth + 1].charAt(0).toUpperCase() + query[depth + 1].slice(1)
|
584
593
|
: query
|
585
594
|
;
|
586
|
-
if( $.isPlainObject(
|
587
|
-
|
595
|
+
if( $.isPlainObject( object[camelCaseValue] ) && (depth != maxDepth) ) {
|
596
|
+
object = object[camelCaseValue];
|
588
597
|
}
|
589
|
-
else if(
|
590
|
-
found =
|
598
|
+
else if( object[camelCaseValue] !== undefined ) {
|
599
|
+
found = object[camelCaseValue];
|
591
600
|
return false;
|
592
601
|
}
|
593
|
-
else if( $.isPlainObject(
|
594
|
-
|
602
|
+
else if( $.isPlainObject( object[value] ) && (depth != maxDepth) ) {
|
603
|
+
object = object[value];
|
595
604
|
}
|
596
|
-
else if(
|
597
|
-
found =
|
605
|
+
else if( object[value] !== undefined ) {
|
606
|
+
found = object[value];
|
598
607
|
return false;
|
599
608
|
}
|
600
609
|
else {
|
601
|
-
module.error(error.method, query);
|
602
610
|
return false;
|
603
611
|
}
|
604
612
|
});
|
@@ -648,7 +656,7 @@ $.fn.modal.settings = {
|
|
648
656
|
name : 'Modal',
|
649
657
|
namespace : 'modal',
|
650
658
|
|
651
|
-
debug :
|
659
|
+
debug : false,
|
652
660
|
verbose : true,
|
653
661
|
performance : true,
|
654
662
|
|