├── .gitignore
├── assets
└── bootstrap-3.3.2
│ ├── js
│ ├── tests
│ │ ├── unit
│ │ │ ├── .jshintrc
│ │ │ ├── phantom.js
│ │ │ ├── alert.js
│ │ │ ├── affix.js
│ │ │ ├── button.js
│ │ │ ├── scrollspy.js
│ │ │ ├── tab.js
│ │ │ ├── popover.js
│ │ │ ├── modal.js
│ │ │ └── dropdown.js
│ │ ├── visual
│ │ │ ├── alert.html
│ │ │ ├── popover.html
│ │ │ ├── carousel.html
│ │ │ ├── button.html
│ │ │ ├── tooltip.html
│ │ │ ├── collapse.html
│ │ │ ├── modal.html
│ │ │ └── dropdown.html
│ │ ├── index.html
│ │ └── vendor
│ │ │ └── qunit.css
│ ├── .jshintrc
│ ├── npm.js
│ ├── .jscsrc
│ ├── transition.js
│ ├── alert.js
│ ├── popover.js
│ ├── button.js
│ ├── tab.js
│ ├── dropdown.js
│ ├── scrollspy.js
│ ├── affix.js
│ ├── collapse.js
│ ├── carousel.js
│ └── modal.js
│ └── fonts
│ ├── glyphicons-halflings-regular.eot
│ ├── glyphicons-halflings-regular.ttf
│ ├── glyphicons-halflings-regular.woff
│ └── glyphicons-halflings-regular.woff2
├── gulpfile.js
├── package.json
├── index.html
├── examples
├── fixLeft.html
├── fixRight.html
├── fixMultiLeft.html
├── fixMultiRight.html
├── fixHeader.html
├── fixHeadAndLeft.html
├── fixHeadAndRight.html
├── fixMultiHead.html
├── fixFooter.html
├── fixFooterAndLeft.html
├── fixFooterAndRight.html
├── fixMultiFooter.html
├── fixMultiTable.html
└── cutomStyleHeight.html
└── README.md
/.gitignore:
--------------------------------------------------------------------------------
1 | node_modules
2 | .idea
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/tests/unit/.jshintrc:
--------------------------------------------------------------------------------
1 | {
2 | "extends" : "../../.jshintrc",
3 | "devel" : true,
4 | "qunit" : true
5 | }
6 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/fonts/glyphicons-halflings-regular.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/lai32290/TableHeadFixer/HEAD/assets/bootstrap-3.3.2/fonts/glyphicons-halflings-regular.eot
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/fonts/glyphicons-halflings-regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/lai32290/TableHeadFixer/HEAD/assets/bootstrap-3.3.2/fonts/glyphicons-halflings-regular.ttf
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/fonts/glyphicons-halflings-regular.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/lai32290/TableHeadFixer/HEAD/assets/bootstrap-3.3.2/fonts/glyphicons-halflings-regular.woff
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/fonts/glyphicons-halflings-regular.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/lai32290/TableHeadFixer/HEAD/assets/bootstrap-3.3.2/fonts/glyphicons-halflings-regular.woff2
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/.jshintrc:
--------------------------------------------------------------------------------
1 | {
2 | "asi" : true,
3 | "browser" : true,
4 | "eqeqeq" : false,
5 | "eqnull" : true,
6 | "es3" : true,
7 | "expr" : true,
8 | "jquery" : true,
9 | "latedef" : true,
10 | "laxbreak" : true,
11 | "nonbsp" : true,
12 | "strict" : true,
13 | "undef" : true,
14 | "unused" : true
15 | }
16 |
--------------------------------------------------------------------------------
/gulpfile.js:
--------------------------------------------------------------------------------
1 | var gulp = require("gulp");
2 | var watch = require("gulp-watch");
3 | var livereload = require("gulp-livereload");
4 |
5 | var watchFiles = [
6 | "tableHeadFixer.js",
7 | "examples/*.html"
8 | ];
9 |
10 | gulp.task("watch", function() {
11 | livereload.listen();
12 | gulp.watch(watchFiles, function() {
13 | livereload.reload();
14 | });
15 | });
16 |
17 | gulp.task("default", ["watch"]);
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/npm.js:
--------------------------------------------------------------------------------
1 | // This file is autogenerated via the `commonjs` Grunt task. You can require() this file in a CommonJS environment.
2 | require('../../js/transition.js')
3 | require('../../js/alert.js')
4 | require('../../js/button.js')
5 | require('../../js/carousel.js')
6 | require('../../js/collapse.js')
7 | require('../../js/dropdown.js')
8 | require('../../js/modal.js')
9 | require('../../js/tooltip.js')
10 | require('../../js/popover.js')
11 | require('../../js/scrollspy.js')
12 | require('../../js/tab.js')
13 | require('../../js/affix.js')
--------------------------------------------------------------------------------
/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "TableHeadFixer",
3 | "version": "1.0.1",
4 | "description": "",
5 | "main": "helloFixHeader.js",
6 | "scripts": {
7 | "test": "echo \"Error: no test specified\" && exit 1"
8 | },
9 | "repository": {
10 | "type": "git",
11 | "url": "https://github.com/lai32290/HelloTableFixHeader.git"
12 | },
13 | "author": "",
14 | "license": "MIT",
15 | "bugs": {
16 | "url": "https://github.com/lai32290/HelloTableFixHeader/issues"
17 | },
18 | "homepage": "https://github.com/lai32290/HelloTableFixHeader",
19 | "dependencies": {
20 | "gulp": "^3.8.11",
21 | "gulp-livereload": "^3.8.0",
22 | "gulp-watch": "^4.2.4"
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | Demos of TableHeadFixer
4 |
5 |
6 |
7 |
8 | Demos of TableHeadFixer
9 |
10 |
Basic Examples
11 |
17 |
18 |
19 |
20 |
Multiple Examples
21 |
27 |
28 |
29 |
30 |
Combination Examples
31 |
37 |
38 |
39 |
40 |
Others Exmaples
41 |
44 |
45 |
46 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/tests/visual/alert.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Alert
8 |
9 |
10 |
11 |
12 |
16 |
17 |
18 |
19 |
20 |
21 |
24 |
25 |
26 | ×
27 | Holy guacamole! Best check yo self, you're not looking too good.
28 |
29 |
30 |
31 |
×
32 |
Oh snap! You got an error!
33 |
Change this and that and try again. Duis mollis, est non commodo luctus, nisi erat porttitor ligula, eget lacinia odio sem nec elit. Cras mattis consectetur purus sit amet fermentum.
34 |
35 | Take this action
36 | Or do this
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/.jscsrc:
--------------------------------------------------------------------------------
1 | {
2 | "disallowEmptyBlocks": true,
3 | "disallowKeywords": ["with"],
4 | "disallowMixedSpacesAndTabs": true,
5 | "disallowMultipleLineStrings": true,
6 | "disallowMultipleVarDecl": true,
7 | "disallowQuotedKeysInObjects": "allButReserved",
8 | "disallowSpaceAfterPrefixUnaryOperators": ["++", "--", "+", "-", "~", "!"],
9 | "disallowSpaceBeforeBinaryOperators": [","],
10 | "disallowSpaceBeforePostfixUnaryOperators": ["++", "--"],
11 | "disallowSpacesInNamedFunctionExpression": { "beforeOpeningRoundBrace": true },
12 | "disallowSpacesInsideArrayBrackets": true,
13 | "disallowSpacesInsideParentheses": true,
14 | "disallowTrailingComma": true,
15 | "disallowTrailingWhitespace": true,
16 | "requireCamelCaseOrUpperCaseIdentifiers": true,
17 | "requireCapitalizedConstructors": true,
18 | "requireCommaBeforeLineBreak": true,
19 | "requireDotNotation": true,
20 | "requireLineFeedAtFileEnd": true,
21 | "requireSpaceAfterBinaryOperators": ["+", "-", "/", "*", "=", "==", "===", "!=", "!==", ">", "<", ">=", "<="],
22 | "requireSpaceAfterKeywords": ["if", "else", "for", "while", "do", "switch", "return", "try", "catch"],
23 | "requireSpaceAfterLineComment": true,
24 | "requireSpaceBeforeBinaryOperators": ["+", "-", "/", "*", "=", "==", "===", "!=", "!==", ">", "<", ">=", "<="],
25 | "requireSpaceBetweenArguments": true,
26 | "requireSpacesInAnonymousFunctionExpression": { "beforeOpeningCurlyBrace": true, "beforeOpeningRoundBrace": true },
27 | "requireSpacesInConditionalExpression": true,
28 | "requireSpacesInForStatement": true,
29 | "requireSpacesInFunctionDeclaration": { "beforeOpeningCurlyBrace": true },
30 | "requireSpacesInFunctionExpression": { "beforeOpeningCurlyBrace": true },
31 | "requireSpacesInNamedFunctionExpression": { "beforeOpeningCurlyBrace": true },
32 | "requireSpacesInsideObjectBrackets": "allButNested",
33 | "validateIndentation": 2,
34 | "validateLineBreaks": "LF",
35 | "validateQuoteMarks": "'"
36 | }
37 |
--------------------------------------------------------------------------------
/examples/fixLeft.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
15 |
16 |
21 |
22 |
23 |
24 | TableHeadFixer Fix Left Column
25 |
26 |
27 |
28 |
29 |
30 | Ano
31 | Jan
32 | Fev
33 | Mar
34 | Abr
35 | Maio
36 | Total
37 |
38 |
39 |
40 |
41 | 2012
42 | 110.00
43 | 110.00
44 | 110.00
45 | 110.00
46 | 110.00
47 | 550.00
48 |
49 |
50 | 2012
51 | 110.00
52 | 110.00
53 | 110.00
54 | 110.00
55 | 110.00
56 | 550.00
57 |
58 |
59 | 2012
60 | 110.00
61 | 110.00
62 | 110.00
63 | 110.00
64 | 110.00
65 | 550.00
66 |
67 |
68 | 2012
69 | 110.00
70 | 110.00
71 | 110.00
72 | 110.00
73 | 110.00
74 | 550.00
75 |
76 |
77 | 2012
78 | 110.00
79 | 110.00
80 | 110.00
81 | 110.00
82 | 110.00
83 | 550.00
84 |
85 |
86 |
87 |
88 |
89 |
--------------------------------------------------------------------------------
/examples/fixRight.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
15 |
16 |
21 |
22 |
23 |
24 | TableHeadFixer Fix Right Column
25 |
26 |
27 |
28 |
29 |
30 | Ano
31 | Jan
32 | Fev
33 | Mar
34 | Abr
35 | Maio
36 | Total
37 |
38 |
39 |
40 |
41 | 2012
42 | 110.00
43 | 110.00
44 | 110.00
45 | 110.00
46 | 110.00
47 | 550.00
48 |
49 |
50 | 2012
51 | 110.00
52 | 110.00
53 | 110.00
54 | 110.00
55 | 110.00
56 | 550.00
57 |
58 |
59 | 2012
60 | 110.00
61 | 110.00
62 | 110.00
63 | 110.00
64 | 110.00
65 | 550.00
66 |
67 |
68 | 2012
69 | 110.00
70 | 110.00
71 | 110.00
72 | 110.00
73 | 110.00
74 | 550.00
75 |
76 |
77 | 2012
78 | 110.00
79 | 110.00
80 | 110.00
81 | 110.00
82 | 110.00
83 | 550.00
84 |
85 |
86 |
87 |
88 |
89 |
--------------------------------------------------------------------------------
/examples/fixMultiLeft.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
15 |
16 |
21 |
22 |
23 |
24 | TableHeadFixer Fix Left Multiple Column
25 |
26 |
27 |
28 |
29 |
30 | Ano
31 | Jan
32 | Fev
33 | Mar
34 | Abr
35 | Maio
36 | Total
37 |
38 |
39 |
40 |
41 | 2012
42 | 110.00
43 | 110.00
44 | 110.00
45 | 110.00
46 | 110.00
47 | 550.00
48 |
49 |
50 | 2012
51 | 110.00
52 | 110.00
53 | 110.00
54 | 110.00
55 | 110.00
56 | 550.00
57 |
58 |
59 | 2012
60 | 110.00
61 | 110.00
62 | 110.00
63 | 110.00
64 | 110.00
65 | 550.00
66 |
67 |
68 | 2012
69 | 110.00
70 | 110.00
71 | 110.00
72 | 110.00
73 | 110.00
74 | 550.00
75 |
76 |
77 | 2012
78 | 110.00
79 | 110.00
80 | 110.00
81 | 110.00
82 | 110.00
83 | 550.00
84 |
85 |
86 |
87 |
88 |
89 |
--------------------------------------------------------------------------------
/examples/fixMultiRight.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
15 |
16 |
21 |
22 |
23 |
24 | TableHeadFixer Fix Right Multiple Column
25 |
26 |
27 |
28 |
29 |
30 | Ano
31 | Jan
32 | Fev
33 | Mar
34 | Abr
35 | Maio
36 | Total
37 |
38 |
39 |
40 |
41 | 2012
42 | 110.00
43 | 110.00
44 | 110.00
45 | 110.00
46 | 110.00
47 | 550.00
48 |
49 |
50 | 2012
51 | 110.00
52 | 110.00
53 | 110.00
54 | 110.00
55 | 110.00
56 | 550.00
57 |
58 |
59 | 2012
60 | 110.00
61 | 110.00
62 | 110.00
63 | 110.00
64 | 110.00
65 | 550.00
66 |
67 |
68 | 2012
69 | 110.00
70 | 110.00
71 | 110.00
72 | 110.00
73 | 110.00
74 | 550.00
75 |
76 |
77 | 2012
78 | 110.00
79 | 110.00
80 | 110.00
81 | 110.00
82 | 110.00
83 | 550.00
84 |
85 |
86 |
87 |
88 |
89 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/transition.js:
--------------------------------------------------------------------------------
1 | /* ========================================================================
2 | * Bootstrap: transition.js v3.3.2
3 | * http://getbootstrap.com/javascript/#transitions
4 | * ========================================================================
5 | * Copyright 2011-2015 Twitter, Inc.
6 | * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
7 | * ======================================================================== */
8 |
9 |
10 | +function ($) {
11 | 'use strict';
12 |
13 | // CSS TRANSITION SUPPORT (Shoutout: http://www.modernizr.com/)
14 | // ============================================================
15 |
16 | function transitionEnd() {
17 | var el = document.createElement('bootstrap')
18 |
19 | var transEndEventNames = {
20 | WebkitTransition : 'webkitTransitionEnd',
21 | MozTransition : 'transitionend',
22 | OTransition : 'oTransitionEnd otransitionend',
23 | transition : 'transitionend'
24 | }
25 |
26 | for (var name in transEndEventNames) {
27 | if (el.style[name] !== undefined) {
28 | return { end: transEndEventNames[name] }
29 | }
30 | }
31 |
32 | return false // explicit for ie8 ( ._.)
33 | }
34 |
35 | // http://blog.alexmaccaw.com/css-transitions
36 | $.fn.emulateTransitionEnd = function (duration) {
37 | var called = false
38 | var $el = this
39 | $(this).one('bsTransitionEnd', function () { called = true })
40 | var callback = function () { if (!called) $($el).trigger($.support.transition.end) }
41 | setTimeout(callback, duration)
42 | return this
43 | }
44 |
45 | $(function () {
46 | $.support.transition = transitionEnd()
47 |
48 | if (!$.support.transition) return
49 |
50 | $.event.special.bsTransitionEnd = {
51 | bindType: $.support.transition.end,
52 | delegateType: $.support.transition.end,
53 | handle: function (e) {
54 | if ($(e.target).is(this)) return e.handleObj.handler.apply(this, arguments)
55 | }
56 | }
57 | })
58 |
59 | }(jQuery);
60 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/tests/unit/phantom.js:
--------------------------------------------------------------------------------
1 | /*
2 | * grunt-contrib-qunit
3 | * http://gruntjs.com/
4 | *
5 | * Copyright (c) 2014 "Cowboy" Ben Alman, contributors
6 | * Licensed under the MIT license.
7 | */
8 |
9 | (function () {
10 | 'use strict';
11 |
12 | // Don't re-order tests.
13 | QUnit.config.reorder = false
14 | // Run tests serially, not in parallel.
15 | QUnit.config.autorun = false
16 |
17 | // Send messages to the parent PhantomJS process via alert! Good times!!
18 | function sendMessage() {
19 | var args = [].slice.call(arguments)
20 | alert(JSON.stringify(args))
21 | }
22 |
23 | // These methods connect QUnit to PhantomJS.
24 | QUnit.log(function (obj) {
25 | // What is this I don’t even
26 | if (obj.message === '[object Object], undefined:undefined') { return }
27 |
28 | // Parse some stuff before sending it.
29 | var actual
30 | var expected
31 | if (!obj.result) {
32 | // Dumping large objects can be very slow, and the dump isn't used for
33 | // passing tests, so only dump if the test failed.
34 | actual = QUnit.jsDump.parse(obj.actual)
35 | expected = QUnit.jsDump.parse(obj.expected)
36 | }
37 | // Send it.
38 | sendMessage('qunit.log', obj.result, actual, expected, obj.message, obj.source)
39 | })
40 |
41 | QUnit.testStart(function (obj) {
42 | sendMessage('qunit.testStart', obj.name)
43 | })
44 |
45 | QUnit.testDone(function (obj) {
46 | sendMessage('qunit.testDone', obj.name, obj.failed, obj.passed, obj.total, obj.duration)
47 | })
48 |
49 | QUnit.moduleStart(function (obj) {
50 | sendMessage('qunit.moduleStart', obj.name)
51 | })
52 |
53 | QUnit.moduleDone(function (obj) {
54 | if (obj.failed === 0) {
55 | console.log('\r\u2714 All tests passed in "' + obj.name + '" module')
56 | } else {
57 | console.log('\u2716 ' + obj.failed + ' tests failed in "' + obj.name + '" module')
58 | }
59 | sendMessage('qunit.moduleDone', obj.name, obj.failed, obj.passed, obj.total)
60 | })
61 |
62 | QUnit.begin(function () {
63 | sendMessage('qunit.begin')
64 | console.log('\n\nStarting test suite')
65 | console.log('================================================\n')
66 | })
67 |
68 | QUnit.done(function (obj) {
69 | sendMessage('qunit.done', obj.failed, obj.passed, obj.total, obj.runtime)
70 | })
71 |
72 | }())
73 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/tests/visual/popover.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Popover
8 |
9 |
10 |
11 |
12 |
16 |
17 |
18 |
19 |
20 |
21 |
24 |
25 |
26 | Popover on left
27 |
28 |
29 | Popover on top
30 |
31 |
32 | Popover on bottom
33 |
34 |
35 | Popover on right
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
52 |
53 |
54 |
55 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/tests/visual/carousel.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Carousel
8 |
9 |
10 |
11 |
12 |
16 |
17 |
18 |
19 |
20 |
21 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/tests/visual/button.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Button
8 |
9 |
10 |
11 |
12 |
16 |
17 |
18 |
19 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
73 |
74 |
75 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/alert.js:
--------------------------------------------------------------------------------
1 | /* ========================================================================
2 | * Bootstrap: alert.js v3.3.2
3 | * http://getbootstrap.com/javascript/#alerts
4 | * ========================================================================
5 | * Copyright 2011-2015 Twitter, Inc.
6 | * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
7 | * ======================================================================== */
8 |
9 |
10 | +function ($) {
11 | 'use strict';
12 |
13 | // ALERT CLASS DEFINITION
14 | // ======================
15 |
16 | var dismiss = '[data-dismiss="alert"]'
17 | var Alert = function (el) {
18 | $(el).on('click', dismiss, this.close)
19 | }
20 |
21 | Alert.VERSION = '3.3.2'
22 |
23 | Alert.TRANSITION_DURATION = 150
24 |
25 | Alert.prototype.close = function (e) {
26 | var $this = $(this)
27 | var selector = $this.attr('data-target')
28 |
29 | if (!selector) {
30 | selector = $this.attr('href')
31 | selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '') // strip for ie7
32 | }
33 |
34 | var $parent = $(selector)
35 |
36 | if (e) e.preventDefault()
37 |
38 | if (!$parent.length) {
39 | $parent = $this.closest('.alert')
40 | }
41 |
42 | $parent.trigger(e = $.Event('close.bs.alert'))
43 |
44 | if (e.isDefaultPrevented()) return
45 |
46 | $parent.removeClass('in')
47 |
48 | function removeElement() {
49 | // detach from parent, fire event then clean up data
50 | $parent.detach().trigger('closed.bs.alert').remove()
51 | }
52 |
53 | $.support.transition && $parent.hasClass('fade') ?
54 | $parent
55 | .one('bsTransitionEnd', removeElement)
56 | .emulateTransitionEnd(Alert.TRANSITION_DURATION) :
57 | removeElement()
58 | }
59 |
60 |
61 | // ALERT PLUGIN DEFINITION
62 | // =======================
63 |
64 | function Plugin(option) {
65 | return this.each(function () {
66 | var $this = $(this)
67 | var data = $this.data('bs.alert')
68 |
69 | if (!data) $this.data('bs.alert', (data = new Alert(this)))
70 | if (typeof option == 'string') data[option].call($this)
71 | })
72 | }
73 |
74 | var old = $.fn.alert
75 |
76 | $.fn.alert = Plugin
77 | $.fn.alert.Constructor = Alert
78 |
79 |
80 | // ALERT NO CONFLICT
81 | // =================
82 |
83 | $.fn.alert.noConflict = function () {
84 | $.fn.alert = old
85 | return this
86 | }
87 |
88 |
89 | // ALERT DATA-API
90 | // ==============
91 |
92 | $(document).on('click.bs.alert.data-api', dismiss, Alert.prototype.close)
93 |
94 | }(jQuery);
95 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/tests/unit/alert.js:
--------------------------------------------------------------------------------
1 | $(function () {
2 | 'use strict';
3 |
4 | module('alert plugin')
5 |
6 | test('should be defined on jquery object', function () {
7 | ok($(document.body).alert, 'alert method is defined')
8 | })
9 |
10 | module('alert', {
11 | setup: function () {
12 | // Run all tests in noConflict mode -- it's the only way to ensure that the plugin works in noConflict mode
13 | $.fn.bootstrapAlert = $.fn.alert.noConflict()
14 | },
15 | teardown: function () {
16 | $.fn.alert = $.fn.bootstrapAlert
17 | delete $.fn.bootstrapAlert
18 | }
19 | })
20 |
21 | test('should provide no conflict', function () {
22 | strictEqual($.fn.alert, undefined, 'alert was set back to undefined (org value)')
23 | })
24 |
25 | test('should return jquery collection containing the element', function () {
26 | var $el = $('
')
27 | var $alert = $el.bootstrapAlert()
28 | ok($alert instanceof $, 'returns jquery collection')
29 | strictEqual($alert[0], $el[0], 'collection contains element')
30 | })
31 |
32 | test('should fade element out on clicking .close', function () {
33 | var alertHTML = ''
34 | + '
× '
35 | + '
Holy guacamole! Best check yo self, you\'re not looking too good.
'
36 | + '
'
37 | var $alert = $(alertHTML).bootstrapAlert()
38 |
39 | $alert.find('.close').click()
40 |
41 | equal($alert.hasClass('in'), false, 'remove .in class on .close click')
42 | })
43 |
44 | test('should remove element when clicking .close', function () {
45 | var alertHTML = ''
46 | + '
× '
47 | + '
Holy guacamole! Best check yo self, you\'re not looking too good.
'
48 | + '
'
49 | var $alert = $(alertHTML).appendTo('#qunit-fixture').bootstrapAlert()
50 |
51 | notEqual($('#qunit-fixture').find('.alert').length, 0, 'element added to dom')
52 |
53 | $alert.find('.close').click()
54 |
55 | equal($('#qunit-fixture').find('.alert').length, 0, 'element removed from dom')
56 | })
57 |
58 | test('should not fire closed when close is prevented', function () {
59 | stop()
60 | $('
')
61 | .on('close.bs.alert', function (e) {
62 | e.preventDefault()
63 | ok(true, 'close event fired')
64 | start()
65 | })
66 | .on('closed.bs.alert', function () {
67 | ok(false, 'closed event fired')
68 | })
69 | .bootstrapAlert('close')
70 | })
71 |
72 | })
73 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/tests/visual/tooltip.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Tooltip
8 |
9 |
10 |
11 |
12 |
16 |
17 |
18 |
19 |
20 |
21 |
24 |
25 |
Tight pants next level keffiyeh you probably haven't heard of them. Photo booth beard raw denim letterpress vegan messenger bag stumptown. Farm-to-table seitan, mcsweeney's fixie sustainable quinoa 8-bit american apparel have a terry richardson vinyl chambray. Beard stumptown, cardigans banh mi lomo thundercats. Tofu biodiesel williamsburg marfa, four loko mcsweeney's cleanse vegan chambray. A really ironic artisan whatever keytar , scenester farm-to-table banksy Austin twitter handle freegan cred raw denim single-origin coffee viral.
26 |
27 |
28 |
29 | Tooltip on left
30 | Tooltip on top
31 | Tooltip on bottom
32 | Tooltip on right
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
48 |
49 |
50 |
51 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/tests/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Bootstrap Plugin Test Suite
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
24 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
94 |
95 |
96 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # TableHeadFixer
2 | ### About
3 | TableHeadFixer is a simple [jQuery](http:/jquery.com/ "jQuery") plugin for fixing HTML table header, footer and columns.
4 | This plugin will only add elements' events and css attributes necessary to fix table header, footer and columns. You can customize styles of your table, as this plugin will not influence any styles of your table (width, height, background, font color, etc...)
5 |
6 |
7 | ### Dependiences (Important!)
8 | - [jQuery](http:/jquery.com/ "jQuery")
9 |
10 | ### Get Starting
11 | Before you can use TableHeadFixer plugin, it is required to include jQuery on your website.
12 | To use TableHeadFixer just include the plugin and call $(element).tableHeadFixer([param]) function after the page renders.
13 | The table must be wrapped with a div element with all size styles set.
14 |
15 | ### Example:
16 | #### Fix Table Header
17 | ```javascript
18 | // get your table with jQuery selector
19 | $("#fixTable").tableHeadFixer();
20 | ```
21 |
22 | #### Fix First Left Column
23 | By default, the function .tableHeadFixer() fixes only table header. If you need to fix only footer or columns, it is necessary to disable header fix by parameter.
24 | ```javascript
25 | $("#fixTable").tableHeadFixer({'left' : 1, 'head' : false});
26 | ```
27 |
28 | #### Fix Two Left Columns
29 | ```javascript
30 | $("#fixTable").tableHeadFixer({'left' : 2, 'head' : false});
31 | ```
32 |
33 | #### Fix Table Header and First Right Column
34 | ```javascript
35 | $("#fixTable").tableHeadFixer({'right' : 1});
36 | ```
37 |
38 | #### Fix Table Header and Footer
39 | ```javascript
40 | $("#fixTable").tableHeadFixer({'foot' : true});
41 | ```
42 |
43 | #### If you need to set fixed cells z-index parameter to resolve conflits between jQuery plugins
44 | ```javascript
45 | $("#fixTable").tableHeadFixer({'z-index' : 50});
46 | ```
47 |
48 | #### Fix Multiple Rows in Header or Footer
49 | Fixing multiple rows in header or footer is as easy as adding new tr to either of them, all header's and footer's table rows will be fixed.
50 |
51 | #### More Demos
52 | More demos are available inside examples directory.
53 |
54 | ### Parameters
55 | | attribute | values |default |
56 | |-----------|---------------|-----------|
57 | | head | true/false | true |
58 | | foot | true/false | false |
59 | | left | 1,2,3,4,etc | 0 |
60 | | right | 1,2,3,4,etc | 0 |
61 | | z-index | 10,50,999,etc | 0 |
62 |
63 | ### Note
64 | To be able to fix table header, footer and columns, it is important to have the table contained in a div, with explicitely set `height` (for fixing header or footer) and `width` (for fixing columns) attributes/css styles. This is very important, since this plugin depends on having the area for the table limited.
65 |
66 | #### If fixed cells' border is important for you
67 | If fixed cells' border is important for you, it is necessary to set table cells' styles to `border-collapse: separate`, because with `border-collapse: collapse` style the cell borders cannot separate and maintain the position of fixed cells.
68 |
69 |
70 | ### Update
71 | * Fixed problems with `some function is not defined` issue in old Firefox.
72 |
73 | ### Licence
74 | MIT
75 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/tests/unit/affix.js:
--------------------------------------------------------------------------------
1 | $(function () {
2 | 'use strict';
3 |
4 | module('affix plugin')
5 |
6 | test('should be defined on jquery object', function () {
7 | ok($(document.body).affix, 'affix method is defined')
8 | })
9 |
10 | module('affix', {
11 | setup: function () {
12 | // Run all tests in noConflict mode -- it's the only way to ensure that the plugin works in noConflict mode
13 | $.fn.bootstrapAffix = $.fn.affix.noConflict()
14 | },
15 | teardown: function () {
16 | $.fn.affix = $.fn.bootstrapAffix
17 | delete $.fn.bootstrapAffix
18 | }
19 | })
20 |
21 | test('should provide no conflict', function () {
22 | strictEqual($.fn.affix, undefined, 'affix was set back to undefined (org value)')
23 | })
24 |
25 | test('should return jquery collection containing the element', function () {
26 | var $el = $('
')
27 | var $affix = $el.bootstrapAffix()
28 | ok($affix instanceof $, 'returns jquery collection')
29 | strictEqual($affix[0], $el[0], 'collection contains element')
30 | })
31 |
32 | test('should exit early if element is not visible', function () {
33 | var $affix = $('
').bootstrapAffix()
34 | $affix.data('bs.affix').checkPosition()
35 | ok(!$affix.hasClass('affix'), 'affix class was not added')
36 | })
37 |
38 | test('should trigger affixed event after affix', function () {
39 | stop()
40 |
41 | var templateHTML = ''
42 | + '
'
43 | + 'Please affix '
44 | + 'And unaffix '
45 | + ' '
46 | + '
'
47 | + '
'
48 | $(templateHTML).appendTo(document.body)
49 |
50 | $('#affixTarget').bootstrapAffix({
51 | offset: $('#affixTarget ul').position()
52 | })
53 |
54 | $('#affixTarget')
55 | .on('affix.bs.affix', function () {
56 | ok(true, 'affix event fired')
57 | }).on('affixed.bs.affix', function () {
58 | ok(true, 'affixed event fired')
59 | $('#affixTarget, #affixAfter').remove()
60 | start()
61 | })
62 |
63 | setTimeout(function () {
64 | window.scrollTo(0, document.body.scrollHeight)
65 |
66 | setTimeout(function () {
67 | window.scroll(0, 0)
68 | }, 16) // for testing in a browser
69 | }, 0)
70 | })
71 |
72 | test('should affix-top when scrolling up to offset when parent has padding', function () {
73 | stop()
74 |
75 | var templateHTML = ''
76 | + '
'
77 | + '
Testing affix-top class is added
'
78 | + '
'
79 | + '
'
80 | + '
'
81 | $(templateHTML).appendTo(document.body)
82 |
83 | $('#affixTopTarget')
84 | .bootstrapAffix({
85 | offset: { top: 120, bottom: 0 }
86 | })
87 | .on('affixed-top.bs.affix', function () {
88 | ok($('#affixTopTarget').hasClass('affix-top'), 'affix-top class applied')
89 | $('#padding-offset').remove()
90 | start()
91 | })
92 |
93 | setTimeout(function () {
94 | window.scrollTo(0, document.body.scrollHeight)
95 |
96 | setTimeout(function () {
97 | window.scroll(0, 119)
98 | }, 250)
99 | }, 250)
100 | })
101 | })
102 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/popover.js:
--------------------------------------------------------------------------------
1 | /* ========================================================================
2 | * Bootstrap: popover.js v3.3.2
3 | * http://getbootstrap.com/javascript/#popovers
4 | * ========================================================================
5 | * Copyright 2011-2015 Twitter, Inc.
6 | * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
7 | * ======================================================================== */
8 |
9 |
10 | +function ($) {
11 | 'use strict';
12 |
13 | // POPOVER PUBLIC CLASS DEFINITION
14 | // ===============================
15 |
16 | var Popover = function (element, options) {
17 | this.init('popover', element, options)
18 | }
19 |
20 | if (!$.fn.tooltip) throw new Error('Popover requires tooltip.js')
21 |
22 | Popover.VERSION = '3.3.2'
23 |
24 | Popover.DEFAULTS = $.extend({}, $.fn.tooltip.Constructor.DEFAULTS, {
25 | placement: 'right',
26 | trigger: 'click',
27 | content: '',
28 | template: ''
29 | })
30 |
31 |
32 | // NOTE: POPOVER EXTENDS tooltip.js
33 | // ================================
34 |
35 | Popover.prototype = $.extend({}, $.fn.tooltip.Constructor.prototype)
36 |
37 | Popover.prototype.constructor = Popover
38 |
39 | Popover.prototype.getDefaults = function () {
40 | return Popover.DEFAULTS
41 | }
42 |
43 | Popover.prototype.setContent = function () {
44 | var $tip = this.tip()
45 | var title = this.getTitle()
46 | var content = this.getContent()
47 |
48 | $tip.find('.popover-title')[this.options.html ? 'html' : 'text'](title)
49 | $tip.find('.popover-content').children().detach().end()[ // we use append for html objects to maintain js events
50 | this.options.html ? (typeof content == 'string' ? 'html' : 'append') : 'text'
51 | ](content)
52 |
53 | $tip.removeClass('fade top bottom left right in')
54 |
55 | // IE8 doesn't accept hiding via the `:empty` pseudo selector, we have to do
56 | // this manually by checking the contents.
57 | if (!$tip.find('.popover-title').html()) $tip.find('.popover-title').hide()
58 | }
59 |
60 | Popover.prototype.hasContent = function () {
61 | return this.getTitle() || this.getContent()
62 | }
63 |
64 | Popover.prototype.getContent = function () {
65 | var $e = this.$element
66 | var o = this.options
67 |
68 | return $e.attr('data-content')
69 | || (typeof o.content == 'function' ?
70 | o.content.call($e[0]) :
71 | o.content)
72 | }
73 |
74 | Popover.prototype.arrow = function () {
75 | return (this.$arrow = this.$arrow || this.tip().find('.arrow'))
76 | }
77 |
78 | Popover.prototype.tip = function () {
79 | if (!this.$tip) this.$tip = $(this.options.template)
80 | return this.$tip
81 | }
82 |
83 |
84 | // POPOVER PLUGIN DEFINITION
85 | // =========================
86 |
87 | function Plugin(option) {
88 | return this.each(function () {
89 | var $this = $(this)
90 | var data = $this.data('bs.popover')
91 | var options = typeof option == 'object' && option
92 |
93 | if (!data && option == 'destroy') return
94 | if (!data) $this.data('bs.popover', (data = new Popover(this, options)))
95 | if (typeof option == 'string') data[option]()
96 | })
97 | }
98 |
99 | var old = $.fn.popover
100 |
101 | $.fn.popover = Plugin
102 | $.fn.popover.Constructor = Popover
103 |
104 |
105 | // POPOVER NO CONFLICT
106 | // ===================
107 |
108 | $.fn.popover.noConflict = function () {
109 | $.fn.popover = old
110 | return this
111 | }
112 |
113 | }(jQuery);
114 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/button.js:
--------------------------------------------------------------------------------
1 | /* ========================================================================
2 | * Bootstrap: button.js v3.3.2
3 | * http://getbootstrap.com/javascript/#buttons
4 | * ========================================================================
5 | * Copyright 2011-2015 Twitter, Inc.
6 | * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
7 | * ======================================================================== */
8 |
9 |
10 | +function ($) {
11 | 'use strict';
12 |
13 | // BUTTON PUBLIC CLASS DEFINITION
14 | // ==============================
15 |
16 | var Button = function (element, options) {
17 | this.$element = $(element)
18 | this.options = $.extend({}, Button.DEFAULTS, options)
19 | this.isLoading = false
20 | }
21 |
22 | Button.VERSION = '3.3.2'
23 |
24 | Button.DEFAULTS = {
25 | loadingText: 'loading...'
26 | }
27 |
28 | Button.prototype.setState = function (state) {
29 | var d = 'disabled'
30 | var $el = this.$element
31 | var val = $el.is('input') ? 'val' : 'html'
32 | var data = $el.data()
33 |
34 | state = state + 'Text'
35 |
36 | if (data.resetText == null) $el.data('resetText', $el[val]())
37 |
38 | // push to event loop to allow forms to submit
39 | setTimeout($.proxy(function () {
40 | $el[val](data[state] == null ? this.options[state] : data[state])
41 |
42 | if (state == 'loadingText') {
43 | this.isLoading = true
44 | $el.addClass(d).attr(d, d)
45 | } else if (this.isLoading) {
46 | this.isLoading = false
47 | $el.removeClass(d).removeAttr(d)
48 | }
49 | }, this), 0)
50 | }
51 |
52 | Button.prototype.toggle = function () {
53 | var changed = true
54 | var $parent = this.$element.closest('[data-toggle="buttons"]')
55 |
56 | if ($parent.length) {
57 | var $input = this.$element.find('input')
58 | if ($input.prop('type') == 'radio') {
59 | if ($input.prop('checked') && this.$element.hasClass('active')) changed = false
60 | else $parent.find('.active').removeClass('active')
61 | }
62 | if (changed) $input.prop('checked', !this.$element.hasClass('active')).trigger('change')
63 | } else {
64 | this.$element.attr('aria-pressed', !this.$element.hasClass('active'))
65 | }
66 |
67 | if (changed) this.$element.toggleClass('active')
68 | }
69 |
70 |
71 | // BUTTON PLUGIN DEFINITION
72 | // ========================
73 |
74 | function Plugin(option) {
75 | return this.each(function () {
76 | var $this = $(this)
77 | var data = $this.data('bs.button')
78 | var options = typeof option == 'object' && option
79 |
80 | if (!data) $this.data('bs.button', (data = new Button(this, options)))
81 |
82 | if (option == 'toggle') data.toggle()
83 | else if (option) data.setState(option)
84 | })
85 | }
86 |
87 | var old = $.fn.button
88 |
89 | $.fn.button = Plugin
90 | $.fn.button.Constructor = Button
91 |
92 |
93 | // BUTTON NO CONFLICT
94 | // ==================
95 |
96 | $.fn.button.noConflict = function () {
97 | $.fn.button = old
98 | return this
99 | }
100 |
101 |
102 | // BUTTON DATA-API
103 | // ===============
104 |
105 | $(document)
106 | .on('click.bs.button.data-api', '[data-toggle^="button"]', function (e) {
107 | var $btn = $(e.target)
108 | if (!$btn.hasClass('btn')) $btn = $btn.closest('.btn')
109 | Plugin.call($btn, 'toggle')
110 | e.preventDefault()
111 | })
112 | .on('focus.bs.button.data-api blur.bs.button.data-api', '[data-toggle^="button"]', function (e) {
113 | $(e.target).closest('.btn').toggleClass('focus', /^focus(in)?$/.test(e.type))
114 | })
115 |
116 | }(jQuery);
117 |
--------------------------------------------------------------------------------
/examples/fixHeader.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
11 |
12 |
17 |
18 |
19 |
20 | TableHeadFixer Fix Header
21 |
22 |
23 |
24 |
25 |
26 | Ano
27 | Jan
28 | Fev
29 | Mar
30 | Abr
31 | Maio
32 | Total
33 |
34 |
35 |
36 |
37 | 2010
38 | 100.00
39 | 100.00
40 | 100.00
41 | 100.00
42 | 100.00
43 | 500.00
44 |
45 |
46 | 2011
47 | 110.00
48 | 110.00
49 | 110.00
50 | 110.00
51 | 110.00
52 | 550.00
53 |
54 |
55 | 2012
56 | 110.00
57 | 110.00
58 | 110.00
59 | 110.00
60 | 110.00
61 | 550.00
62 |
63 |
64 | 2012
65 | 110.00
66 | 110.00
67 | 110.00
68 | 110.00
69 | 110.00
70 | 550.00
71 |
72 |
73 | 2012
74 | 110.00
75 | 110.00
76 | 110.00
77 | 110.00
78 | 110.00
79 | 550.00
80 |
81 |
82 | 2012
83 | 110.00
84 | 110.00
85 | 110.00
86 | 110.00
87 | 110.00
88 | 550.00
89 |
90 |
91 | 2012
92 | 110.00
93 | 110.00
94 | 110.00
95 | 110.00
96 | 110.00
97 | 550.00
98 |
99 |
100 | 2012
101 | 110.00
102 | 110.00
103 | 110.00
104 | 110.00
105 | 110.00
106 | 550.00
107 |
108 |
109 | 2012
110 | 110.00
111 | 110.00
112 | 110.00
113 | 110.00
114 | 110.00
115 | 550.00
116 |
117 |
118 | 2012
119 | 110.00
120 | 110.00
121 | 110.00
122 | 110.00
123 | 110.00
124 | 550.00
125 |
126 |
127 | 2012
128 | 110.00
129 | 110.00
130 | 110.00
131 | 110.00
132 | 110.00
133 | 550.00
134 |
135 |
136 | 2012
137 | 110.00
138 | 110.00
139 | 110.00
140 | 110.00
141 | 110.00
142 | 550.00
143 |
144 |
145 | 2012
146 | 110.00
147 | 110.00
148 | 110.00
149 | 110.00
150 | 110.00
151 | 550.00
152 |
153 |
154 | 2012
155 | 110.00
156 | 110.00
157 | 110.00
158 | 110.00
159 | 110.00
160 | 550.00
161 |
162 |
163 | 2012
164 | 110.00
165 | 110.00
166 | 110.00
167 | 110.00
168 | 110.00
169 | 550.00
170 |
171 |
172 |
173 |
174 |
175 |
--------------------------------------------------------------------------------
/examples/fixHeadAndLeft.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
15 |
16 |
21 |
22 |
23 |
24 | TableHeadFixer Fix Head and Left Column
25 |
26 |
27 |
28 |
29 |
30 | Ano
31 | Jan
32 | Fev
33 | Mar
34 | Abr
35 | Maio
36 | Total
37 |
38 |
39 |
40 |
41 | 2010
42 | 100.00
43 | 100.00
44 | 100.00
45 | 100.00
46 | 100.00
47 | 500.00
48 |
49 |
50 | 2011
51 | 110.00
52 | 110.00
53 | 110.00
54 | 110.00
55 | 110.00
56 | 550.00
57 |
58 |
59 | 2012
60 | 110.00
61 | 110.00
62 | 110.00
63 | 110.00
64 | 110.00
65 | 550.00
66 |
67 |
68 | 2012
69 | 110.00
70 | 110.00
71 | 110.00
72 | 110.00
73 | 110.00
74 | 550.00
75 |
76 |
77 | 2012
78 | 110.00
79 | 110.00
80 | 110.00
81 | 110.00
82 | 110.00
83 | 550.00
84 |
85 |
86 | 2012
87 | 110.00
88 | 110.00
89 | 110.00
90 | 110.00
91 | 110.00
92 | 550.00
93 |
94 |
95 | 2012
96 | 110.00
97 | 110.00
98 | 110.00
99 | 110.00
100 | 110.00
101 | 550.00
102 |
103 |
104 | 2012
105 | 110.00
106 | 110.00
107 | 110.00
108 | 110.00
109 | 110.00
110 | 550.00
111 |
112 |
113 | 2012
114 | 110.00
115 | 110.00
116 | 110.00
117 | 110.00
118 | 110.00
119 | 550.00
120 |
121 |
122 | 2012
123 | 110.00
124 | 110.00
125 | 110.00
126 | 110.00
127 | 110.00
128 | 550.00
129 |
130 |
131 | 2012
132 | 110.00
133 | 110.00
134 | 110.00
135 | 110.00
136 | 110.00
137 | 550.00
138 |
139 |
140 | 2012
141 | 110.00
142 | 110.00
143 | 110.00
144 | 110.00
145 | 110.00
146 | 550.00
147 |
148 |
149 | 2012
150 | 110.00
151 | 110.00
152 | 110.00
153 | 110.00
154 | 110.00
155 | 550.00
156 |
157 |
158 | 2012
159 | 110.00
160 | 110.00
161 | 110.00
162 | 110.00
163 | 110.00
164 | 550.00
165 |
166 |
167 | 2012
168 | 110.00
169 | 110.00
170 | 110.00
171 | 110.00
172 | 110.00
173 | 550.00
174 |
175 |
176 |
177 |
178 |
179 |
--------------------------------------------------------------------------------
/examples/fixHeadAndRight.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
15 |
16 |
21 |
22 |
23 |
24 | TableHeadFixer Fix Head and Right Column
25 |
26 |
27 |
28 |
29 |
30 | Ano
31 | Jan
32 | Fev
33 | Mar
34 | Abr
35 | Maio
36 | Total
37 |
38 |
39 |
40 |
41 | 2010
42 | 100.00
43 | 100.00
44 | 100.00
45 | 100.00
46 | 100.00
47 | 500.00
48 |
49 |
50 | 2011
51 | 110.00
52 | 110.00
53 | 110.00
54 | 110.00
55 | 110.00
56 | 550.00
57 |
58 |
59 | 2012
60 | 110.00
61 | 110.00
62 | 110.00
63 | 110.00
64 | 110.00
65 | 550.00
66 |
67 |
68 | 2012
69 | 110.00
70 | 110.00
71 | 110.00
72 | 110.00
73 | 110.00
74 | 550.00
75 |
76 |
77 | 2012
78 | 110.00
79 | 110.00
80 | 110.00
81 | 110.00
82 | 110.00
83 | 550.00
84 |
85 |
86 | 2012
87 | 110.00
88 | 110.00
89 | 110.00
90 | 110.00
91 | 110.00
92 | 550.00
93 |
94 |
95 | 2012
96 | 110.00
97 | 110.00
98 | 110.00
99 | 110.00
100 | 110.00
101 | 550.00
102 |
103 |
104 | 2012
105 | 110.00
106 | 110.00
107 | 110.00
108 | 110.00
109 | 110.00
110 | 550.00
111 |
112 |
113 | 2012
114 | 110.00
115 | 110.00
116 | 110.00
117 | 110.00
118 | 110.00
119 | 550.00
120 |
121 |
122 | 2012
123 | 110.00
124 | 110.00
125 | 110.00
126 | 110.00
127 | 110.00
128 | 550.00
129 |
130 |
131 | 2012
132 | 110.00
133 | 110.00
134 | 110.00
135 | 110.00
136 | 110.00
137 | 550.00
138 |
139 |
140 | 2012
141 | 110.00
142 | 110.00
143 | 110.00
144 | 110.00
145 | 110.00
146 | 550.00
147 |
148 |
149 | 2012
150 | 110.00
151 | 110.00
152 | 110.00
153 | 110.00
154 | 110.00
155 | 550.00
156 |
157 |
158 | 2012
159 | 110.00
160 | 110.00
161 | 110.00
162 | 110.00
163 | 110.00
164 | 550.00
165 |
166 |
167 | 2012
168 | 110.00
169 | 110.00
170 | 110.00
171 | 110.00
172 | 110.00
173 | 550.00
174 |
175 |
176 |
177 |
178 |
179 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/tests/visual/collapse.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Collapse
8 |
9 |
10 |
11 |
12 |
16 |
17 |
18 |
19 |
20 |
21 |
24 |
25 |
26 |
27 |
34 |
35 |
36 | Anim pariatur cliche reprehenderit, enim eiusmod high life accusamus terry richardson ad squid. 3 wolf moon officia aute, non cupidatat skateboard dolor brunch. Food truck quinoa nesciunt laborum eiusmod. Brunch 3 wolf moon tempor, sunt aliqua put a bird on it squid single-origin coffee nulla assumenda shoreditch et. Nihil anim keffiyeh helvetica, craft beer labore wes anderson cred nesciunt sapiente ea proident. Ad vegan excepteur butcher vice lomo. Leggings occaecat craft beer farm-to-table, raw denim aesthetic synth nesciunt you probably haven't heard of them accusamus labore sustainable VHS.
37 |
38 |
39 |
40 |
41 |
48 |
49 |
50 | Anim pariatur cliche reprehenderit, enim eiusmod high life accusamus terry richardson ad squid. 3 wolf moon officia aute, non cupidatat skateboard dolor brunch. Food truck quinoa nesciunt laborum eiusmod. Brunch 3 wolf moon tempor, sunt aliqua put a bird on it squid single-origin coffee nulla assumenda shoreditch et. Nihil anim keffiyeh helvetica, craft beer labore wes anderson cred nesciunt sapiente ea proident. Ad vegan excepteur butcher vice lomo. Leggings occaecat craft beer farm-to-table, raw denim aesthetic synth nesciunt you probably haven't heard of them accusamus labore sustainable VHS.
51 |
52 |
53 |
54 |
55 |
62 |
63 |
64 | Anim pariatur cliche reprehenderit, enim eiusmod high life accusamus terry richardson ad squid. 3 wolf moon officia aute, non cupidatat skateboard dolor brunch. Food truck quinoa nesciunt laborum eiusmod. Brunch 3 wolf moon tempor, sunt aliqua put a bird on it squid single-origin coffee nulla assumenda shoreditch et. Nihil anim keffiyeh helvetica, craft beer labore wes anderson cred nesciunt sapiente ea proident. Ad vegan excepteur butcher vice lomo. Leggings occaecat craft beer farm-to-table, raw denim aesthetic synth nesciunt you probably haven't heard of them accusamus labore sustainable VHS.
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
--------------------------------------------------------------------------------
/examples/fixMultiHead.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
11 |
12 |
17 |
18 |
19 |
20 | TableHeadFixer Fix Head Multiple Row
21 |
22 |
23 |
24 |
25 |
26 | Ano
27 | Jan
28 | Fev
29 | Mar
30 | Abr
31 | Maio
32 | Total
33 |
34 |
35 | Ano
36 | Jan
37 | Fev
38 | Mar
39 | Abr
40 | Maio
41 | Total
42 |
43 |
44 |
45 |
46 | 2010
47 | 100.00
48 | 100.00
49 | 100.00
50 | 100.00
51 | 100.00
52 | 500.00
53 |
54 |
55 | 2011
56 | 110.00
57 | 110.00
58 | 110.00
59 | 110.00
60 | 110.00
61 | 550.00
62 |
63 |
64 | 2012
65 | 110.00
66 | 110.00
67 | 110.00
68 | 110.00
69 | 110.00
70 | 550.00
71 |
72 |
73 | 2012
74 | 110.00
75 | 110.00
76 | 110.00
77 | 110.00
78 | 110.00
79 | 550.00
80 |
81 |
82 | 2012
83 | 110.00
84 | 110.00
85 | 110.00
86 | 110.00
87 | 110.00
88 | 550.00
89 |
90 |
91 | 2012
92 | 110.00
93 | 110.00
94 | 110.00
95 | 110.00
96 | 110.00
97 | 550.00
98 |
99 |
100 | 2012
101 | 110.00
102 | 110.00
103 | 110.00
104 | 110.00
105 | 110.00
106 | 550.00
107 |
108 |
109 | 2012
110 | 110.00
111 | 110.00
112 | 110.00
113 | 110.00
114 | 110.00
115 | 550.00
116 |
117 |
118 | 2012
119 | 110.00
120 | 110.00
121 | 110.00
122 | 110.00
123 | 110.00
124 | 550.00
125 |
126 |
127 | 2012
128 | 110.00
129 | 110.00
130 | 110.00
131 | 110.00
132 | 110.00
133 | 550.00
134 |
135 |
136 | 2012
137 | 110.00
138 | 110.00
139 | 110.00
140 | 110.00
141 | 110.00
142 | 550.00
143 |
144 |
145 | 2012
146 | 110.00
147 | 110.00
148 | 110.00
149 | 110.00
150 | 110.00
151 | 550.00
152 |
153 |
154 | 2012
155 | 110.00
156 | 110.00
157 | 110.00
158 | 110.00
159 | 110.00
160 | 550.00
161 |
162 |
163 | 2012
164 | 110.00
165 | 110.00
166 | 110.00
167 | 110.00
168 | 110.00
169 | 550.00
170 |
171 |
172 | 2012
173 | 110.00
174 | 110.00
175 | 110.00
176 | 110.00
177 | 110.00
178 | 550.00
179 |
180 |
181 |
182 |
183 |
184 |
--------------------------------------------------------------------------------
/examples/fixFooter.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
11 |
12 |
17 |
18 |
19 |
20 | TableHeadFixer Fix Footer
21 |
22 |
23 |
24 |
25 |
26 | Ano
27 | Jan
28 | Fev
29 | Mar
30 | Abr
31 | Maio
32 | Total
33 |
34 |
35 |
36 |
37 | 2010
38 | 100.00
39 | 100.00
40 | 100.00
41 | 100.00
42 | 100.00
43 | 500.00
44 |
45 |
46 | 2011
47 | 110.00
48 | 110.00
49 | 110.00
50 | 110.00
51 | 110.00
52 | 550.00
53 |
54 |
55 | 2012
56 | 110.00
57 | 110.00
58 | 110.00
59 | 110.00
60 | 110.00
61 | 550.00
62 |
63 |
64 | 2012
65 | 110.00
66 | 110.00
67 | 110.00
68 | 110.00
69 | 110.00
70 | 550.00
71 |
72 |
73 | 2012
74 | 110.00
75 | 110.00
76 | 110.00
77 | 110.00
78 | 110.00
79 | 550.00
80 |
81 |
82 | 2012
83 | 110.00
84 | 110.00
85 | 110.00
86 | 110.00
87 | 110.00
88 | 550.00
89 |
90 |
91 | 2012
92 | 110.00
93 | 110.00
94 | 110.00
95 | 110.00
96 | 110.00
97 | 550.00
98 |
99 |
100 | 2012
101 | 110.00
102 | 110.00
103 | 110.00
104 | 110.00
105 | 110.00
106 | 550.00
107 |
108 |
109 | 2012
110 | 110.00
111 | 110.00
112 | 110.00
113 | 110.00
114 | 110.00
115 | 550.00
116 |
117 |
118 | 2012
119 | 110.00
120 | 110.00
121 | 110.00
122 | 110.00
123 | 110.00
124 | 550.00
125 |
126 |
127 | 2012
128 | 110.00
129 | 110.00
130 | 110.00
131 | 110.00
132 | 110.00
133 | 550.00
134 |
135 |
136 | 2012
137 | 110.00
138 | 110.00
139 | 110.00
140 | 110.00
141 | 110.00
142 | 550.00
143 |
144 |
145 | 2012
146 | 110.00
147 | 110.00
148 | 110.00
149 | 110.00
150 | 110.00
151 | 550.00
152 |
153 |
154 | 2012
155 | 110.00
156 | 110.00
157 | 110.00
158 | 110.00
159 | 110.00
160 | 550.00
161 |
162 |
163 | 2012
164 | 110.00
165 | 110.00
166 | 110.00
167 | 110.00
168 | 110.00
169 | 550.00
170 |
171 |
172 |
173 |
174 | 1000.00
175 | 1000.00
176 | 1000.00
177 | 1000.00
178 | 1000.00
179 | 1000.00
180 | 5000.00
181 |
182 |
183 |
184 |
185 |
186 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/tab.js:
--------------------------------------------------------------------------------
1 | /* ========================================================================
2 | * Bootstrap: tab.js v3.3.2
3 | * http://getbootstrap.com/javascript/#tabs
4 | * ========================================================================
5 | * Copyright 2011-2015 Twitter, Inc.
6 | * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
7 | * ======================================================================== */
8 |
9 |
10 | +function ($) {
11 | 'use strict';
12 |
13 | // TAB CLASS DEFINITION
14 | // ====================
15 |
16 | var Tab = function (element) {
17 | this.element = $(element)
18 | }
19 |
20 | Tab.VERSION = '3.3.2'
21 |
22 | Tab.TRANSITION_DURATION = 150
23 |
24 | Tab.prototype.show = function () {
25 | var $this = this.element
26 | var $ul = $this.closest('ul:not(.dropdown-menu)')
27 | var selector = $this.data('target')
28 |
29 | if (!selector) {
30 | selector = $this.attr('href')
31 | selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '') // strip for ie7
32 | }
33 |
34 | if ($this.parent('li').hasClass('active')) return
35 |
36 | var $previous = $ul.find('.active:last a')
37 | var hideEvent = $.Event('hide.bs.tab', {
38 | relatedTarget: $this[0]
39 | })
40 | var showEvent = $.Event('show.bs.tab', {
41 | relatedTarget: $previous[0]
42 | })
43 |
44 | $previous.trigger(hideEvent)
45 | $this.trigger(showEvent)
46 |
47 | if (showEvent.isDefaultPrevented() || hideEvent.isDefaultPrevented()) return
48 |
49 | var $target = $(selector)
50 |
51 | this.activate($this.closest('li'), $ul)
52 | this.activate($target, $target.parent(), function () {
53 | $previous.trigger({
54 | type: 'hidden.bs.tab',
55 | relatedTarget: $this[0]
56 | })
57 | $this.trigger({
58 | type: 'shown.bs.tab',
59 | relatedTarget: $previous[0]
60 | })
61 | })
62 | }
63 |
64 | Tab.prototype.activate = function (element, container, callback) {
65 | var $active = container.find('> .active')
66 | var transition = callback
67 | && $.support.transition
68 | && (($active.length && $active.hasClass('fade')) || !!container.find('> .fade').length)
69 |
70 | function next() {
71 | $active
72 | .removeClass('active')
73 | .find('> .dropdown-menu > .active')
74 | .removeClass('active')
75 | .end()
76 | .find('[data-toggle="tab"]')
77 | .attr('aria-expanded', false)
78 |
79 | element
80 | .addClass('active')
81 | .find('[data-toggle="tab"]')
82 | .attr('aria-expanded', true)
83 |
84 | if (transition) {
85 | element[0].offsetWidth // reflow for transition
86 | element.addClass('in')
87 | } else {
88 | element.removeClass('fade')
89 | }
90 |
91 | if (element.parent('.dropdown-menu')) {
92 | element
93 | .closest('li.dropdown')
94 | .addClass('active')
95 | .end()
96 | .find('[data-toggle="tab"]')
97 | .attr('aria-expanded', true)
98 | }
99 |
100 | callback && callback()
101 | }
102 |
103 | $active.length && transition ?
104 | $active
105 | .one('bsTransitionEnd', next)
106 | .emulateTransitionEnd(Tab.TRANSITION_DURATION) :
107 | next()
108 |
109 | $active.removeClass('in')
110 | }
111 |
112 |
113 | // TAB PLUGIN DEFINITION
114 | // =====================
115 |
116 | function Plugin(option) {
117 | return this.each(function () {
118 | var $this = $(this)
119 | var data = $this.data('bs.tab')
120 |
121 | if (!data) $this.data('bs.tab', (data = new Tab(this)))
122 | if (typeof option == 'string') data[option]()
123 | })
124 | }
125 |
126 | var old = $.fn.tab
127 |
128 | $.fn.tab = Plugin
129 | $.fn.tab.Constructor = Tab
130 |
131 |
132 | // TAB NO CONFLICT
133 | // ===============
134 |
135 | $.fn.tab.noConflict = function () {
136 | $.fn.tab = old
137 | return this
138 | }
139 |
140 |
141 | // TAB DATA-API
142 | // ============
143 |
144 | var clickHandler = function (e) {
145 | e.preventDefault()
146 | Plugin.call($(this), 'show')
147 | }
148 |
149 | $(document)
150 | .on('click.bs.tab.data-api', '[data-toggle="tab"]', clickHandler)
151 | .on('click.bs.tab.data-api', '[data-toggle="pill"]', clickHandler)
152 |
153 | }(jQuery);
154 |
--------------------------------------------------------------------------------
/examples/fixFooterAndLeft.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
15 |
16 |
21 |
22 |
23 |
24 | TableHeadFixer Fix Footer and Left
25 |
26 |
27 |
28 |
29 |
30 | Ano
31 | Jan
32 | Fev
33 | Mar
34 | Abr
35 | Maio
36 | Total
37 |
38 |
39 |
40 |
41 | 2010
42 | 100.00
43 | 100.00
44 | 100.00
45 | 100.00
46 | 100.00
47 | 500.00
48 |
49 |
50 | 2011
51 | 110.00
52 | 110.00
53 | 110.00
54 | 110.00
55 | 110.00
56 | 550.00
57 |
58 |
59 | 2012
60 | 110.00
61 | 110.00
62 | 110.00
63 | 110.00
64 | 110.00
65 | 550.00
66 |
67 |
68 | 2012
69 | 110.00
70 | 110.00
71 | 110.00
72 | 110.00
73 | 110.00
74 | 550.00
75 |
76 |
77 | 2012
78 | 110.00
79 | 110.00
80 | 110.00
81 | 110.00
82 | 110.00
83 | 550.00
84 |
85 |
86 | 2012
87 | 110.00
88 | 110.00
89 | 110.00
90 | 110.00
91 | 110.00
92 | 550.00
93 |
94 |
95 | 2012
96 | 110.00
97 | 110.00
98 | 110.00
99 | 110.00
100 | 110.00
101 | 550.00
102 |
103 |
104 | 2012
105 | 110.00
106 | 110.00
107 | 110.00
108 | 110.00
109 | 110.00
110 | 550.00
111 |
112 |
113 | 2012
114 | 110.00
115 | 110.00
116 | 110.00
117 | 110.00
118 | 110.00
119 | 550.00
120 |
121 |
122 | 2012
123 | 110.00
124 | 110.00
125 | 110.00
126 | 110.00
127 | 110.00
128 | 550.00
129 |
130 |
131 | 2012
132 | 110.00
133 | 110.00
134 | 110.00
135 | 110.00
136 | 110.00
137 | 550.00
138 |
139 |
140 | 2012
141 | 110.00
142 | 110.00
143 | 110.00
144 | 110.00
145 | 110.00
146 | 550.00
147 |
148 |
149 | 2012
150 | 110.00
151 | 110.00
152 | 110.00
153 | 110.00
154 | 110.00
155 | 550.00
156 |
157 |
158 | 2012
159 | 110.00
160 | 110.00
161 | 110.00
162 | 110.00
163 | 110.00
164 | 550.00
165 |
166 |
167 | 2012
168 | 110.00
169 | 110.00
170 | 110.00
171 | 110.00
172 | 110.00
173 | 550.00
174 |
175 |
176 |
177 |
178 | 1000.00
179 | 1000.00
180 | 1000.00
181 | 1000.00
182 | 1000.00
183 | 1000.00
184 | 5000.00
185 |
186 |
187 |
188 |
189 |
190 |
--------------------------------------------------------------------------------
/examples/fixFooterAndRight.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
15 |
16 |
21 |
22 |
23 |
24 | TableHeadFixer Fix Footer and Right
25 |
26 |
27 |
28 |
29 |
30 | Ano
31 | Jan
32 | Fev
33 | Mar
34 | Abr
35 | Maio
36 | Total
37 |
38 |
39 |
40 |
41 | 2010
42 | 100.00
43 | 100.00
44 | 100.00
45 | 100.00
46 | 100.00
47 | 500.00
48 |
49 |
50 | 2011
51 | 110.00
52 | 110.00
53 | 110.00
54 | 110.00
55 | 110.00
56 | 550.00
57 |
58 |
59 | 2012
60 | 110.00
61 | 110.00
62 | 110.00
63 | 110.00
64 | 110.00
65 | 550.00
66 |
67 |
68 | 2012
69 | 110.00
70 | 110.00
71 | 110.00
72 | 110.00
73 | 110.00
74 | 550.00
75 |
76 |
77 | 2012
78 | 110.00
79 | 110.00
80 | 110.00
81 | 110.00
82 | 110.00
83 | 550.00
84 |
85 |
86 | 2012
87 | 110.00
88 | 110.00
89 | 110.00
90 | 110.00
91 | 110.00
92 | 550.00
93 |
94 |
95 | 2012
96 | 110.00
97 | 110.00
98 | 110.00
99 | 110.00
100 | 110.00
101 | 550.00
102 |
103 |
104 | 2012
105 | 110.00
106 | 110.00
107 | 110.00
108 | 110.00
109 | 110.00
110 | 550.00
111 |
112 |
113 | 2012
114 | 110.00
115 | 110.00
116 | 110.00
117 | 110.00
118 | 110.00
119 | 550.00
120 |
121 |
122 | 2012
123 | 110.00
124 | 110.00
125 | 110.00
126 | 110.00
127 | 110.00
128 | 550.00
129 |
130 |
131 | 2012
132 | 110.00
133 | 110.00
134 | 110.00
135 | 110.00
136 | 110.00
137 | 550.00
138 |
139 |
140 | 2012
141 | 110.00
142 | 110.00
143 | 110.00
144 | 110.00
145 | 110.00
146 | 550.00
147 |
148 |
149 | 2012
150 | 110.00
151 | 110.00
152 | 110.00
153 | 110.00
154 | 110.00
155 | 550.00
156 |
157 |
158 | 2012
159 | 110.00
160 | 110.00
161 | 110.00
162 | 110.00
163 | 110.00
164 | 550.00
165 |
166 |
167 | 2012
168 | 110.00
169 | 110.00
170 | 110.00
171 | 110.00
172 | 110.00
173 | 550.00
174 |
175 |
176 |
177 |
178 | 1000.00
179 | 1000.00
180 | 1000.00
181 | 1000.00
182 | 1000.00
183 | 1000.00
184 | 5000.00
185 |
186 |
187 |
188 |
189 |
190 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/tests/visual/modal.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Modal
8 |
9 |
10 |
11 |
12 |
16 |
17 |
18 |
19 |
20 |
21 |
24 |
25 |
26 |
27 |
28 |
29 |
33 |
34 |
Text in a modal
35 |
Duis mollis, est non commodo luctus, nisi erat porttitor ligula.
36 |
37 |
Popover in a modal
38 |
This button should trigger a popover on click.
39 |
40 |
Tooltips in a modal
41 |
This link and that link should have tooltips on hover.
42 |
43 |
44 |
45 |
Overflowing text to show scroll behavior
46 |
Cras mattis consectetur purus sit amet fermentum. Cras justo odio, dapibus ac facilisis in, egestas eget quam. Morbi leo risus, porta ac consectetur ac, vestibulum at eros.
47 |
Praesent commodo cursus magna, vel scelerisque nisl consectetur et. Vivamus sagittis lacus vel augue laoreet rutrum faucibus dolor auctor.
48 |
Aenean lacinia bibendum nulla sed consectetur. Praesent commodo cursus magna, vel scelerisque nisl consectetur et. Donec sed odio dui. Donec ullamcorper nulla non metus auctor fringilla.
49 |
Cras mattis consectetur purus sit amet fermentum. Cras justo odio, dapibus ac facilisis in, egestas eget quam. Morbi leo risus, porta ac consectetur ac, vestibulum at eros.
50 |
Praesent commodo cursus magna, vel scelerisque nisl consectetur et. Vivamus sagittis lacus vel augue laoreet rutrum faucibus dolor auctor.
51 |
Aenean lacinia bibendum nulla sed consectetur. Praesent commodo cursus magna, vel scelerisque nisl consectetur et. Donec sed odio dui. Donec ullamcorper nulla non metus auctor fringilla.
52 |
Cras mattis consectetur purus sit amet fermentum. Cras justo odio, dapibus ac facilisis in, egestas eget quam. Morbi leo risus, porta ac consectetur ac, vestibulum at eros.
53 |
Praesent commodo cursus magna, vel scelerisque nisl consectetur et. Vivamus sagittis lacus vel augue laoreet rutrum faucibus dolor auctor.
54 |
Aenean lacinia bibendum nulla sed consectetur. Praesent commodo cursus magna, vel scelerisque nisl consectetur et. Donec sed odio dui. Donec ullamcorper nulla non metus auctor fringilla.
55 |
56 |
60 |
61 |
62 |
63 |
64 |
65 |
66 | Launch demo modal
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
85 |
86 |
87 |
88 |
--------------------------------------------------------------------------------
/examples/fixMultiFooter.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
11 |
12 |
17 |
18 |
19 |
20 | TableHeadFixer Fix Footer Multiple Row
21 |
22 |
23 |
24 |
25 |
26 | Ano
27 | Jan
28 | Fev
29 | Mar
30 | Abr
31 | Maio
32 | Total
33 |
34 |
35 |
36 |
37 | 2010
38 | 100.00
39 | 100.00
40 | 100.00
41 | 100.00
42 | 100.00
43 | 500.00
44 |
45 |
46 | 2011
47 | 110.00
48 | 110.00
49 | 110.00
50 | 110.00
51 | 110.00
52 | 550.00
53 |
54 |
55 | 2012
56 | 110.00
57 | 110.00
58 | 110.00
59 | 110.00
60 | 110.00
61 | 550.00
62 |
63 |
64 | 2012
65 | 110.00
66 | 110.00
67 | 110.00
68 | 110.00
69 | 110.00
70 | 550.00
71 |
72 |
73 | 2012
74 | 110.00
75 | 110.00
76 | 110.00
77 | 110.00
78 | 110.00
79 | 550.00
80 |
81 |
82 | 2012
83 | 110.00
84 | 110.00
85 | 110.00
86 | 110.00
87 | 110.00
88 | 550.00
89 |
90 |
91 | 2012
92 | 110.00
93 | 110.00
94 | 110.00
95 | 110.00
96 | 110.00
97 | 550.00
98 |
99 |
100 | 2012
101 | 110.00
102 | 110.00
103 | 110.00
104 | 110.00
105 | 110.00
106 | 550.00
107 |
108 |
109 | 2012
110 | 110.00
111 | 110.00
112 | 110.00
113 | 110.00
114 | 110.00
115 | 550.00
116 |
117 |
118 | 2012
119 | 110.00
120 | 110.00
121 | 110.00
122 | 110.00
123 | 110.00
124 | 550.00
125 |
126 |
127 | 2012
128 | 110.00
129 | 110.00
130 | 110.00
131 | 110.00
132 | 110.00
133 | 550.00
134 |
135 |
136 | 2012
137 | 110.00
138 | 110.00
139 | 110.00
140 | 110.00
141 | 110.00
142 | 550.00
143 |
144 |
145 | 2012
146 | 110.00
147 | 110.00
148 | 110.00
149 | 110.00
150 | 110.00
151 | 550.00
152 |
153 |
154 | 2012
155 | 110.00
156 | 110.00
157 | 110.00
158 | 110.00
159 | 110.00
160 | 550.00
161 |
162 |
163 | 2012
164 | 110.00
165 | 110.00
166 | 110.00
167 | 110.00
168 | 110.00
169 | 550.00
170 |
171 |
172 |
173 |
174 | 1000.00
175 | 1000.00
176 | 1000.00
177 | 1000.00
178 | 1000.00
179 | 1000.00
180 | 5000.00
181 |
182 |
183 | 1000.00
184 | 1000.00
185 | 1000.00
186 | 1000.00
187 | 1000.00
188 | 1000.00
189 | 5000.00
190 |
191 |
192 |
193 |
194 |
195 |
--------------------------------------------------------------------------------
/examples/fixMultiTable.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
16 |
17 |
24 |
25 |
26 |
27 | TableHeadFixer Fix Left Column
28 |
29 |
30 |
31 |
32 |
33 |
34 | Ano
35 | Jan
36 | Fev
37 | Mar
38 | Abr
39 | Maio
40 | Total
41 |
42 |
43 |
44 |
45 | 2012
46 | 110.00
47 | 110.00
48 | 110.00
49 | 110.00
50 | 110.00
51 | 550.00
52 |
53 |
54 | 2012
55 | 110.00
56 | 110.00
57 | 110.00
58 | 110.00
59 | 110.00
60 | 550.00
61 |
62 |
63 | 2012
64 | 110.00
65 | 110.00
66 | 110.00
67 | 110.00
68 | 110.00
69 | 550.00
70 |
71 |
72 | 2012
73 | 110.00
74 | 110.00
75 | 110.00
76 | 110.00
77 | 110.00
78 | 550.00
79 |
80 |
81 | 2012
82 | 110.00
83 | 110.00
84 | 110.00
85 | 110.00
86 | 110.00
87 | 550.00
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 | Ano
98 | Jan
99 | Fev
100 | Mar
101 | Abr
102 | Maio
103 | Total
104 |
105 |
106 |
107 |
108 | 2012
109 | 110.00
110 | 110.00
111 | 110.00
112 | 110.00
113 | 110.00
114 | 550.00
115 |
116 |
117 | 2012
118 | 110.00
119 | 110.00
120 | 110.00
121 | 110.00
122 | 110.00
123 | 550.00
124 |
125 |
126 | 2012
127 | 110.00
128 | 110.00
129 | 110.00
130 | 110.00
131 | 110.00
132 | 550.00
133 |
134 |
135 | 2012
136 | 110.00
137 | 110.00
138 | 110.00
139 | 110.00
140 | 110.00
141 | 550.00
142 |
143 |
144 | 2012
145 | 110.00
146 | 110.00
147 | 110.00
148 | 110.00
149 | 110.00
150 | 550.00
151 |
152 |
153 |
154 |
155 |
156 |
157 |
158 |
159 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/dropdown.js:
--------------------------------------------------------------------------------
1 | /* ========================================================================
2 | * Bootstrap: dropdown.js v3.3.2
3 | * http://getbootstrap.com/javascript/#dropdowns
4 | * ========================================================================
5 | * Copyright 2011-2015 Twitter, Inc.
6 | * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
7 | * ======================================================================== */
8 |
9 |
10 | +function ($) {
11 | 'use strict';
12 |
13 | // DROPDOWN CLASS DEFINITION
14 | // =========================
15 |
16 | var backdrop = '.dropdown-backdrop'
17 | var toggle = '[data-toggle="dropdown"]'
18 | var Dropdown = function (element) {
19 | $(element).on('click.bs.dropdown', this.toggle)
20 | }
21 |
22 | Dropdown.VERSION = '3.3.2'
23 |
24 | Dropdown.prototype.toggle = function (e) {
25 | var $this = $(this)
26 |
27 | if ($this.is('.disabled, :disabled')) return
28 |
29 | var $parent = getParent($this)
30 | var isActive = $parent.hasClass('open')
31 |
32 | clearMenus()
33 |
34 | if (!isActive) {
35 | if ('ontouchstart' in document.documentElement && !$parent.closest('.navbar-nav').length) {
36 | // if mobile we use a backdrop because click events don't delegate
37 | $('
').insertAfter($(this)).on('click', clearMenus)
38 | }
39 |
40 | var relatedTarget = { relatedTarget: this }
41 | $parent.trigger(e = $.Event('show.bs.dropdown', relatedTarget))
42 |
43 | if (e.isDefaultPrevented()) return
44 |
45 | $this
46 | .trigger('focus')
47 | .attr('aria-expanded', 'true')
48 |
49 | $parent
50 | .toggleClass('open')
51 | .trigger('shown.bs.dropdown', relatedTarget)
52 | }
53 |
54 | return false
55 | }
56 |
57 | Dropdown.prototype.keydown = function (e) {
58 | if (!/(38|40|27|32)/.test(e.which) || /input|textarea/i.test(e.target.tagName)) return
59 |
60 | var $this = $(this)
61 |
62 | e.preventDefault()
63 | e.stopPropagation()
64 |
65 | if ($this.is('.disabled, :disabled')) return
66 |
67 | var $parent = getParent($this)
68 | var isActive = $parent.hasClass('open')
69 |
70 | if ((!isActive && e.which != 27) || (isActive && e.which == 27)) {
71 | if (e.which == 27) $parent.find(toggle).trigger('focus')
72 | return $this.trigger('click')
73 | }
74 |
75 | var desc = ' li:not(.divider):visible a'
76 | var $items = $parent.find('[role="menu"]' + desc + ', [role="listbox"]' + desc)
77 |
78 | if (!$items.length) return
79 |
80 | var index = $items.index(e.target)
81 |
82 | if (e.which == 38 && index > 0) index-- // up
83 | if (e.which == 40 && index < $items.length - 1) index++ // down
84 | if (!~index) index = 0
85 |
86 | $items.eq(index).trigger('focus')
87 | }
88 |
89 | function clearMenus(e) {
90 | if (e && e.which === 3) return
91 | $(backdrop).remove()
92 | $(toggle).each(function () {
93 | var $this = $(this)
94 | var $parent = getParent($this)
95 | var relatedTarget = { relatedTarget: this }
96 |
97 | if (!$parent.hasClass('open')) return
98 |
99 | $parent.trigger(e = $.Event('hide.bs.dropdown', relatedTarget))
100 |
101 | if (e.isDefaultPrevented()) return
102 |
103 | $this.attr('aria-expanded', 'false')
104 | $parent.removeClass('open').trigger('hidden.bs.dropdown', relatedTarget)
105 | })
106 | }
107 |
108 | function getParent($this) {
109 | var selector = $this.attr('data-target')
110 |
111 | if (!selector) {
112 | selector = $this.attr('href')
113 | selector = selector && /#[A-Za-z]/.test(selector) && selector.replace(/.*(?=#[^\s]*$)/, '') // strip for ie7
114 | }
115 |
116 | var $parent = selector && $(selector)
117 |
118 | return $parent && $parent.length ? $parent : $this.parent()
119 | }
120 |
121 |
122 | // DROPDOWN PLUGIN DEFINITION
123 | // ==========================
124 |
125 | function Plugin(option) {
126 | return this.each(function () {
127 | var $this = $(this)
128 | var data = $this.data('bs.dropdown')
129 |
130 | if (!data) $this.data('bs.dropdown', (data = new Dropdown(this)))
131 | if (typeof option == 'string') data[option].call($this)
132 | })
133 | }
134 |
135 | var old = $.fn.dropdown
136 |
137 | $.fn.dropdown = Plugin
138 | $.fn.dropdown.Constructor = Dropdown
139 |
140 |
141 | // DROPDOWN NO CONFLICT
142 | // ====================
143 |
144 | $.fn.dropdown.noConflict = function () {
145 | $.fn.dropdown = old
146 | return this
147 | }
148 |
149 |
150 | // APPLY TO STANDARD DROPDOWN ELEMENTS
151 | // ===================================
152 |
153 | $(document)
154 | .on('click.bs.dropdown.data-api', clearMenus)
155 | .on('click.bs.dropdown.data-api', '.dropdown form', function (e) { e.stopPropagation() })
156 | .on('click.bs.dropdown.data-api', toggle, Dropdown.prototype.toggle)
157 | .on('keydown.bs.dropdown.data-api', toggle, Dropdown.prototype.keydown)
158 | .on('keydown.bs.dropdown.data-api', '[role="menu"]', Dropdown.prototype.keydown)
159 | .on('keydown.bs.dropdown.data-api', '[role="listbox"]', Dropdown.prototype.keydown)
160 |
161 | }(jQuery);
162 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/scrollspy.js:
--------------------------------------------------------------------------------
1 | /* ========================================================================
2 | * Bootstrap: scrollspy.js v3.3.2
3 | * http://getbootstrap.com/javascript/#scrollspy
4 | * ========================================================================
5 | * Copyright 2011-2015 Twitter, Inc.
6 | * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
7 | * ======================================================================== */
8 |
9 |
10 | +function ($) {
11 | 'use strict';
12 |
13 | // SCROLLSPY CLASS DEFINITION
14 | // ==========================
15 |
16 | function ScrollSpy(element, options) {
17 | var process = $.proxy(this.process, this)
18 |
19 | this.$body = $('body')
20 | this.$scrollElement = $(element).is('body') ? $(window) : $(element)
21 | this.options = $.extend({}, ScrollSpy.DEFAULTS, options)
22 | this.selector = (this.options.target || '') + ' .nav li > a'
23 | this.offsets = []
24 | this.targets = []
25 | this.activeTarget = null
26 | this.scrollHeight = 0
27 |
28 | this.$scrollElement.on('scroll.bs.scrollspy', process)
29 | this.refresh()
30 | this.process()
31 | }
32 |
33 | ScrollSpy.VERSION = '3.3.2'
34 |
35 | ScrollSpy.DEFAULTS = {
36 | offset: 10
37 | }
38 |
39 | ScrollSpy.prototype.getScrollHeight = function () {
40 | return this.$scrollElement[0].scrollHeight || Math.max(this.$body[0].scrollHeight, document.documentElement.scrollHeight)
41 | }
42 |
43 | ScrollSpy.prototype.refresh = function () {
44 | var offsetMethod = 'offset'
45 | var offsetBase = 0
46 |
47 | if (!$.isWindow(this.$scrollElement[0])) {
48 | offsetMethod = 'position'
49 | offsetBase = this.$scrollElement.scrollTop()
50 | }
51 |
52 | this.offsets = []
53 | this.targets = []
54 | this.scrollHeight = this.getScrollHeight()
55 |
56 | var self = this
57 |
58 | this.$body
59 | .find(this.selector)
60 | .map(function () {
61 | var $el = $(this)
62 | var href = $el.data('target') || $el.attr('href')
63 | var $href = /^#./.test(href) && $(href)
64 |
65 | return ($href
66 | && $href.length
67 | && $href.is(':visible')
68 | && [[$href[offsetMethod]().top + offsetBase, href]]) || null
69 | })
70 | .sort(function (a, b) { return a[0] - b[0] })
71 | .each(function () {
72 | self.offsets.push(this[0])
73 | self.targets.push(this[1])
74 | })
75 | }
76 |
77 | ScrollSpy.prototype.process = function () {
78 | var scrollTop = this.$scrollElement.scrollTop() + this.options.offset
79 | var scrollHeight = this.getScrollHeight()
80 | var maxScroll = this.options.offset + scrollHeight - this.$scrollElement.height()
81 | var offsets = this.offsets
82 | var targets = this.targets
83 | var activeTarget = this.activeTarget
84 | var i
85 |
86 | if (this.scrollHeight != scrollHeight) {
87 | this.refresh()
88 | }
89 |
90 | if (scrollTop >= maxScroll) {
91 | return activeTarget != (i = targets[targets.length - 1]) && this.activate(i)
92 | }
93 |
94 | if (activeTarget && scrollTop < offsets[0]) {
95 | this.activeTarget = null
96 | return this.clear()
97 | }
98 |
99 | for (i = offsets.length; i--;) {
100 | activeTarget != targets[i]
101 | && scrollTop >= offsets[i]
102 | && (!offsets[i + 1] || scrollTop <= offsets[i + 1])
103 | && this.activate(targets[i])
104 | }
105 | }
106 |
107 | ScrollSpy.prototype.activate = function (target) {
108 | this.activeTarget = target
109 |
110 | this.clear()
111 |
112 | var selector = this.selector +
113 | '[data-target="' + target + '"],' +
114 | this.selector + '[href="' + target + '"]'
115 |
116 | var active = $(selector)
117 | .parents('li')
118 | .addClass('active')
119 |
120 | if (active.parent('.dropdown-menu').length) {
121 | active = active
122 | .closest('li.dropdown')
123 | .addClass('active')
124 | }
125 |
126 | active.trigger('activate.bs.scrollspy')
127 | }
128 |
129 | ScrollSpy.prototype.clear = function () {
130 | $(this.selector)
131 | .parentsUntil(this.options.target, '.active')
132 | .removeClass('active')
133 | }
134 |
135 |
136 | // SCROLLSPY PLUGIN DEFINITION
137 | // ===========================
138 |
139 | function Plugin(option) {
140 | return this.each(function () {
141 | var $this = $(this)
142 | var data = $this.data('bs.scrollspy')
143 | var options = typeof option == 'object' && option
144 |
145 | if (!data) $this.data('bs.scrollspy', (data = new ScrollSpy(this, options)))
146 | if (typeof option == 'string') data[option]()
147 | })
148 | }
149 |
150 | var old = $.fn.scrollspy
151 |
152 | $.fn.scrollspy = Plugin
153 | $.fn.scrollspy.Constructor = ScrollSpy
154 |
155 |
156 | // SCROLLSPY NO CONFLICT
157 | // =====================
158 |
159 | $.fn.scrollspy.noConflict = function () {
160 | $.fn.scrollspy = old
161 | return this
162 | }
163 |
164 |
165 | // SCROLLSPY DATA-API
166 | // ==================
167 |
168 | $(window).on('load.bs.scrollspy.data-api', function () {
169 | $('[data-spy="scroll"]').each(function () {
170 | var $spy = $(this)
171 | Plugin.call($spy, $spy.data())
172 | })
173 | })
174 |
175 | }(jQuery);
176 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/affix.js:
--------------------------------------------------------------------------------
1 | /* ========================================================================
2 | * Bootstrap: affix.js v3.3.2
3 | * http://getbootstrap.com/javascript/#affix
4 | * ========================================================================
5 | * Copyright 2011-2015 Twitter, Inc.
6 | * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
7 | * ======================================================================== */
8 |
9 |
10 | +function ($) {
11 | 'use strict';
12 |
13 | // AFFIX CLASS DEFINITION
14 | // ======================
15 |
16 | var Affix = function (element, options) {
17 | this.options = $.extend({}, Affix.DEFAULTS, options)
18 |
19 | this.$target = $(this.options.target)
20 | .on('scroll.bs.affix.data-api', $.proxy(this.checkPosition, this))
21 | .on('click.bs.affix.data-api', $.proxy(this.checkPositionWithEventLoop, this))
22 |
23 | this.$element = $(element)
24 | this.affixed =
25 | this.unpin =
26 | this.pinnedOffset = null
27 |
28 | this.checkPosition()
29 | }
30 |
31 | Affix.VERSION = '3.3.2'
32 |
33 | Affix.RESET = 'affix affix-top affix-bottom'
34 |
35 | Affix.DEFAULTS = {
36 | offset: 0,
37 | target: window
38 | }
39 |
40 | Affix.prototype.getState = function (scrollHeight, height, offsetTop, offsetBottom) {
41 | var scrollTop = this.$target.scrollTop()
42 | var position = this.$element.offset()
43 | var targetHeight = this.$target.height()
44 |
45 | if (offsetTop != null && this.affixed == 'top') return scrollTop < offsetTop ? 'top' : false
46 |
47 | if (this.affixed == 'bottom') {
48 | if (offsetTop != null) return (scrollTop + this.unpin <= position.top) ? false : 'bottom'
49 | return (scrollTop + targetHeight <= scrollHeight - offsetBottom) ? false : 'bottom'
50 | }
51 |
52 | var initializing = this.affixed == null
53 | var colliderTop = initializing ? scrollTop : position.top
54 | var colliderHeight = initializing ? targetHeight : height
55 |
56 | if (offsetTop != null && scrollTop <= offsetTop) return 'top'
57 | if (offsetBottom != null && (colliderTop + colliderHeight >= scrollHeight - offsetBottom)) return 'bottom'
58 |
59 | return false
60 | }
61 |
62 | Affix.prototype.getPinnedOffset = function () {
63 | if (this.pinnedOffset) return this.pinnedOffset
64 | this.$element.removeClass(Affix.RESET).addClass('affix')
65 | var scrollTop = this.$target.scrollTop()
66 | var position = this.$element.offset()
67 | return (this.pinnedOffset = position.top - scrollTop)
68 | }
69 |
70 | Affix.prototype.checkPositionWithEventLoop = function () {
71 | setTimeout($.proxy(this.checkPosition, this), 1)
72 | }
73 |
74 | Affix.prototype.checkPosition = function () {
75 | if (!this.$element.is(':visible')) return
76 |
77 | var height = this.$element.height()
78 | var offset = this.options.offset
79 | var offsetTop = offset.top
80 | var offsetBottom = offset.bottom
81 | var scrollHeight = $('body').height()
82 |
83 | if (typeof offset != 'object') offsetBottom = offsetTop = offset
84 | if (typeof offsetTop == 'function') offsetTop = offset.top(this.$element)
85 | if (typeof offsetBottom == 'function') offsetBottom = offset.bottom(this.$element)
86 |
87 | var affix = this.getState(scrollHeight, height, offsetTop, offsetBottom)
88 |
89 | if (this.affixed != affix) {
90 | if (this.unpin != null) this.$element.css('top', '')
91 |
92 | var affixType = 'affix' + (affix ? '-' + affix : '')
93 | var e = $.Event(affixType + '.bs.affix')
94 |
95 | this.$element.trigger(e)
96 |
97 | if (e.isDefaultPrevented()) return
98 |
99 | this.affixed = affix
100 | this.unpin = affix == 'bottom' ? this.getPinnedOffset() : null
101 |
102 | this.$element
103 | .removeClass(Affix.RESET)
104 | .addClass(affixType)
105 | .trigger(affixType.replace('affix', 'affixed') + '.bs.affix')
106 | }
107 |
108 | if (affix == 'bottom') {
109 | this.$element.offset({
110 | top: scrollHeight - height - offsetBottom
111 | })
112 | }
113 | }
114 |
115 |
116 | // AFFIX PLUGIN DEFINITION
117 | // =======================
118 |
119 | function Plugin(option) {
120 | return this.each(function () {
121 | var $this = $(this)
122 | var data = $this.data('bs.affix')
123 | var options = typeof option == 'object' && option
124 |
125 | if (!data) $this.data('bs.affix', (data = new Affix(this, options)))
126 | if (typeof option == 'string') data[option]()
127 | })
128 | }
129 |
130 | var old = $.fn.affix
131 |
132 | $.fn.affix = Plugin
133 | $.fn.affix.Constructor = Affix
134 |
135 |
136 | // AFFIX NO CONFLICT
137 | // =================
138 |
139 | $.fn.affix.noConflict = function () {
140 | $.fn.affix = old
141 | return this
142 | }
143 |
144 |
145 | // AFFIX DATA-API
146 | // ==============
147 |
148 | $(window).on('load', function () {
149 | $('[data-spy="affix"]').each(function () {
150 | var $spy = $(this)
151 | var data = $spy.data()
152 |
153 | data.offset = data.offset || {}
154 |
155 | if (data.offsetBottom != null) data.offset.bottom = data.offsetBottom
156 | if (data.offsetTop != null) data.offset.top = data.offsetTop
157 |
158 | Plugin.call($spy, data)
159 | })
160 | })
161 |
162 | }(jQuery);
163 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/tests/vendor/qunit.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * QUnit 1.15.0
3 | * http://qunitjs.com/
4 | *
5 | * Copyright 2014 jQuery Foundation and other contributors
6 | * Released under the MIT license
7 | * http://jquery.org/license
8 | *
9 | * Date: 2014-08-08T16:00Z
10 | */
11 |
12 | /** Font Family and Sizes */
13 |
14 | #qunit-tests, #qunit-header, #qunit-banner, #qunit-testrunner-toolbar, #qunit-userAgent, #qunit-testresult {
15 | font-family: "Helvetica Neue Light", "HelveticaNeue-Light", "Helvetica Neue", Calibri, Helvetica, Arial, sans-serif;
16 | }
17 |
18 | #qunit-testrunner-toolbar, #qunit-userAgent, #qunit-testresult, #qunit-tests li { font-size: small; }
19 | #qunit-tests { font-size: smaller; }
20 |
21 |
22 | /** Resets */
23 |
24 | #qunit-tests, #qunit-header, #qunit-banner, #qunit-userAgent, #qunit-testresult, #qunit-modulefilter {
25 | margin: 0;
26 | padding: 0;
27 | }
28 |
29 |
30 | /** Header */
31 |
32 | #qunit-header {
33 | padding: 0.5em 0 0.5em 1em;
34 |
35 | color: #8699A4;
36 | background-color: #0D3349;
37 |
38 | font-size: 1.5em;
39 | line-height: 1em;
40 | font-weight: 400;
41 |
42 | border-radius: 5px 5px 0 0;
43 | }
44 |
45 | #qunit-header a {
46 | text-decoration: none;
47 | color: #C2CCD1;
48 | }
49 |
50 | #qunit-header a:hover,
51 | #qunit-header a:focus {
52 | color: #FFF;
53 | }
54 |
55 | #qunit-testrunner-toolbar label {
56 | display: inline-block;
57 | padding: 0 0.5em 0 0.1em;
58 | }
59 |
60 | #qunit-banner {
61 | height: 5px;
62 | }
63 |
64 | #qunit-testrunner-toolbar {
65 | padding: 0.5em 1em 0.5em 1em;
66 | color: #5E740B;
67 | background-color: #EEE;
68 | overflow: hidden;
69 | }
70 |
71 | #qunit-userAgent {
72 | padding: 0.5em 1em 0.5em 1em;
73 | background-color: #2B81AF;
74 | color: #FFF;
75 | text-shadow: rgba(0, 0, 0, 0.5) 2px 2px 1px;
76 | }
77 |
78 | #qunit-modulefilter-container {
79 | float: right;
80 | }
81 |
82 | /** Tests: Pass/Fail */
83 |
84 | #qunit-tests {
85 | list-style-position: inside;
86 | }
87 |
88 | #qunit-tests li {
89 | padding: 0.4em 1em 0.4em 1em;
90 | border-bottom: 1px solid #FFF;
91 | list-style-position: inside;
92 | }
93 |
94 | #qunit-tests.hidepass li.pass, #qunit-tests.hidepass li.running {
95 | display: none;
96 | }
97 |
98 | #qunit-tests li strong {
99 | cursor: pointer;
100 | }
101 |
102 | #qunit-tests li a {
103 | padding: 0.5em;
104 | color: #C2CCD1;
105 | text-decoration: none;
106 | }
107 | #qunit-tests li a:hover,
108 | #qunit-tests li a:focus {
109 | color: #000;
110 | }
111 |
112 | #qunit-tests li .runtime {
113 | float: right;
114 | font-size: smaller;
115 | }
116 |
117 | .qunit-assert-list {
118 | margin-top: 0.5em;
119 | padding: 0.5em;
120 |
121 | background-color: #FFF;
122 |
123 | border-radius: 5px;
124 | }
125 |
126 | .qunit-collapsed {
127 | display: none;
128 | }
129 |
130 | #qunit-tests table {
131 | border-collapse: collapse;
132 | margin-top: 0.2em;
133 | }
134 |
135 | #qunit-tests th {
136 | text-align: right;
137 | vertical-align: top;
138 | padding: 0 0.5em 0 0;
139 | }
140 |
141 | #qunit-tests td {
142 | vertical-align: top;
143 | }
144 |
145 | #qunit-tests pre {
146 | margin: 0;
147 | white-space: pre-wrap;
148 | word-wrap: break-word;
149 | }
150 |
151 | #qunit-tests del {
152 | background-color: #E0F2BE;
153 | color: #374E0C;
154 | text-decoration: none;
155 | }
156 |
157 | #qunit-tests ins {
158 | background-color: #FFCACA;
159 | color: #500;
160 | text-decoration: none;
161 | }
162 |
163 | /*** Test Counts */
164 |
165 | #qunit-tests b.counts { color: #000; }
166 | #qunit-tests b.passed { color: #5E740B; }
167 | #qunit-tests b.failed { color: #710909; }
168 |
169 | #qunit-tests li li {
170 | padding: 5px;
171 | background-color: #FFF;
172 | border-bottom: none;
173 | list-style-position: inside;
174 | }
175 |
176 | /*** Passing Styles */
177 |
178 | #qunit-tests li li.pass {
179 | color: #3C510C;
180 | background-color: #FFF;
181 | border-left: 10px solid #C6E746;
182 | }
183 |
184 | #qunit-tests .pass { color: #528CE0; background-color: #D2E0E6; }
185 | #qunit-tests .pass .test-name { color: #366097; }
186 |
187 | #qunit-tests .pass .test-actual,
188 | #qunit-tests .pass .test-expected { color: #999; }
189 |
190 | #qunit-banner.qunit-pass { background-color: #C6E746; }
191 |
192 | /*** Failing Styles */
193 |
194 | #qunit-tests li li.fail {
195 | color: #710909;
196 | background-color: #FFF;
197 | border-left: 10px solid #EE5757;
198 | white-space: pre;
199 | }
200 |
201 | #qunit-tests > li:last-child {
202 | border-radius: 0 0 5px 5px;
203 | }
204 |
205 | #qunit-tests .fail { color: #000; background-color: #EE5757; }
206 | #qunit-tests .fail .test-name,
207 | #qunit-tests .fail .module-name { color: #000; }
208 |
209 | #qunit-tests .fail .test-actual { color: #EE5757; }
210 | #qunit-tests .fail .test-expected { color: #008000; }
211 |
212 | #qunit-banner.qunit-fail { background-color: #EE5757; }
213 |
214 |
215 | /** Result */
216 |
217 | #qunit-testresult {
218 | padding: 0.5em 1em 0.5em 1em;
219 |
220 | color: #2B81AF;
221 | background-color: #D2E0E6;
222 |
223 | border-bottom: 1px solid #FFF;
224 | }
225 | #qunit-testresult .module-name {
226 | font-weight: 700;
227 | }
228 |
229 | /** Fixture */
230 |
231 | #qunit-fixture {
232 | position: absolute;
233 | top: -10000px;
234 | left: -10000px;
235 | width: 1000px;
236 | height: 1000px;
237 | }
238 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/tests/visual/dropdown.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Dropdown
8 |
9 |
10 |
11 |
12 |
16 |
17 |
18 |
19 |
20 |
21 |
24 |
25 |
26 |
73 |
74 |
75 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/collapse.js:
--------------------------------------------------------------------------------
1 | /* ========================================================================
2 | * Bootstrap: collapse.js v3.3.2
3 | * http://getbootstrap.com/javascript/#collapse
4 | * ========================================================================
5 | * Copyright 2011-2015 Twitter, Inc.
6 | * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
7 | * ======================================================================== */
8 |
9 |
10 | +function ($) {
11 | 'use strict';
12 |
13 | // COLLAPSE PUBLIC CLASS DEFINITION
14 | // ================================
15 |
16 | var Collapse = function (element, options) {
17 | this.$element = $(element)
18 | this.options = $.extend({}, Collapse.DEFAULTS, options)
19 | this.$trigger = $(this.options.trigger).filter('[href="#' + element.id + '"], [data-target="#' + element.id + '"]')
20 | this.transitioning = null
21 |
22 | if (this.options.parent) {
23 | this.$parent = this.getParent()
24 | } else {
25 | this.addAriaAndCollapsedClass(this.$element, this.$trigger)
26 | }
27 |
28 | if (this.options.toggle) this.toggle()
29 | }
30 |
31 | Collapse.VERSION = '3.3.2'
32 |
33 | Collapse.TRANSITION_DURATION = 350
34 |
35 | Collapse.DEFAULTS = {
36 | toggle: true,
37 | trigger: '[data-toggle="collapse"]'
38 | }
39 |
40 | Collapse.prototype.dimension = function () {
41 | var hasWidth = this.$element.hasClass('width')
42 | return hasWidth ? 'width' : 'height'
43 | }
44 |
45 | Collapse.prototype.show = function () {
46 | if (this.transitioning || this.$element.hasClass('in')) return
47 |
48 | var activesData
49 | var actives = this.$parent && this.$parent.children('.panel').children('.in, .collapsing')
50 |
51 | if (actives && actives.length) {
52 | activesData = actives.data('bs.collapse')
53 | if (activesData && activesData.transitioning) return
54 | }
55 |
56 | var startEvent = $.Event('show.bs.collapse')
57 | this.$element.trigger(startEvent)
58 | if (startEvent.isDefaultPrevented()) return
59 |
60 | if (actives && actives.length) {
61 | Plugin.call(actives, 'hide')
62 | activesData || actives.data('bs.collapse', null)
63 | }
64 |
65 | var dimension = this.dimension()
66 |
67 | this.$element
68 | .removeClass('collapse')
69 | .addClass('collapsing')[dimension](0)
70 | .attr('aria-expanded', true)
71 |
72 | this.$trigger
73 | .removeClass('collapsed')
74 | .attr('aria-expanded', true)
75 |
76 | this.transitioning = 1
77 |
78 | var complete = function () {
79 | this.$element
80 | .removeClass('collapsing')
81 | .addClass('collapse in')[dimension]('')
82 | this.transitioning = 0
83 | this.$element
84 | .trigger('shown.bs.collapse')
85 | }
86 |
87 | if (!$.support.transition) return complete.call(this)
88 |
89 | var scrollSize = $.camelCase(['scroll', dimension].join('-'))
90 |
91 | this.$element
92 | .one('bsTransitionEnd', $.proxy(complete, this))
93 | .emulateTransitionEnd(Collapse.TRANSITION_DURATION)[dimension](this.$element[0][scrollSize])
94 | }
95 |
96 | Collapse.prototype.hide = function () {
97 | if (this.transitioning || !this.$element.hasClass('in')) return
98 |
99 | var startEvent = $.Event('hide.bs.collapse')
100 | this.$element.trigger(startEvent)
101 | if (startEvent.isDefaultPrevented()) return
102 |
103 | var dimension = this.dimension()
104 |
105 | this.$element[dimension](this.$element[dimension]())[0].offsetHeight
106 |
107 | this.$element
108 | .addClass('collapsing')
109 | .removeClass('collapse in')
110 | .attr('aria-expanded', false)
111 |
112 | this.$trigger
113 | .addClass('collapsed')
114 | .attr('aria-expanded', false)
115 |
116 | this.transitioning = 1
117 |
118 | var complete = function () {
119 | this.transitioning = 0
120 | this.$element
121 | .removeClass('collapsing')
122 | .addClass('collapse')
123 | .trigger('hidden.bs.collapse')
124 | }
125 |
126 | if (!$.support.transition) return complete.call(this)
127 |
128 | this.$element
129 | [dimension](0)
130 | .one('bsTransitionEnd', $.proxy(complete, this))
131 | .emulateTransitionEnd(Collapse.TRANSITION_DURATION)
132 | }
133 |
134 | Collapse.prototype.toggle = function () {
135 | this[this.$element.hasClass('in') ? 'hide' : 'show']()
136 | }
137 |
138 | Collapse.prototype.getParent = function () {
139 | return $(this.options.parent)
140 | .find('[data-toggle="collapse"][data-parent="' + this.options.parent + '"]')
141 | .each($.proxy(function (i, element) {
142 | var $element = $(element)
143 | this.addAriaAndCollapsedClass(getTargetFromTrigger($element), $element)
144 | }, this))
145 | .end()
146 | }
147 |
148 | Collapse.prototype.addAriaAndCollapsedClass = function ($element, $trigger) {
149 | var isOpen = $element.hasClass('in')
150 |
151 | $element.attr('aria-expanded', isOpen)
152 | $trigger
153 | .toggleClass('collapsed', !isOpen)
154 | .attr('aria-expanded', isOpen)
155 | }
156 |
157 | function getTargetFromTrigger($trigger) {
158 | var href
159 | var target = $trigger.attr('data-target')
160 | || (href = $trigger.attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '') // strip for ie7
161 |
162 | return $(target)
163 | }
164 |
165 |
166 | // COLLAPSE PLUGIN DEFINITION
167 | // ==========================
168 |
169 | function Plugin(option) {
170 | return this.each(function () {
171 | var $this = $(this)
172 | var data = $this.data('bs.collapse')
173 | var options = $.extend({}, Collapse.DEFAULTS, $this.data(), typeof option == 'object' && option)
174 |
175 | if (!data && options.toggle && option == 'show') options.toggle = false
176 | if (!data) $this.data('bs.collapse', (data = new Collapse(this, options)))
177 | if (typeof option == 'string') data[option]()
178 | })
179 | }
180 |
181 | var old = $.fn.collapse
182 |
183 | $.fn.collapse = Plugin
184 | $.fn.collapse.Constructor = Collapse
185 |
186 |
187 | // COLLAPSE NO CONFLICT
188 | // ====================
189 |
190 | $.fn.collapse.noConflict = function () {
191 | $.fn.collapse = old
192 | return this
193 | }
194 |
195 |
196 | // COLLAPSE DATA-API
197 | // =================
198 |
199 | $(document).on('click.bs.collapse.data-api', '[data-toggle="collapse"]', function (e) {
200 | var $this = $(this)
201 |
202 | if (!$this.attr('data-target')) e.preventDefault()
203 |
204 | var $target = getTargetFromTrigger($this)
205 | var data = $target.data('bs.collapse')
206 | var option = data ? 'toggle' : $.extend({}, $this.data(), { trigger: this })
207 |
208 | Plugin.call($target, option)
209 | })
210 |
211 | }(jQuery);
212 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/tests/unit/button.js:
--------------------------------------------------------------------------------
1 | $(function () {
2 | 'use strict';
3 |
4 | module('button plugin')
5 |
6 | test('should be defined on jquery object', function () {
7 | ok($(document.body).button, 'button method is defined')
8 | })
9 |
10 | module('button', {
11 | setup: function () {
12 | // Run all tests in noConflict mode -- it's the only way to ensure that the plugin works in noConflict mode
13 | $.fn.bootstrapButton = $.fn.button.noConflict()
14 | },
15 | teardown: function () {
16 | $.fn.button = $.fn.bootstrapButton
17 | delete $.fn.bootstrapButton
18 | }
19 | })
20 |
21 | test('should provide no conflict', function () {
22 | strictEqual($.fn.button, undefined, 'button was set back to undefined (org value)')
23 | })
24 |
25 | test('should return jquery collection containing the element', function () {
26 | var $el = $('
')
27 | var $button = $el.bootstrapButton()
28 | ok($button instanceof $, 'returns jquery collection')
29 | strictEqual($button[0], $el[0], 'collection contains element')
30 | })
31 |
32 | test('should return set state to loading', function () {
33 | var $btn = $('mdo ')
34 | equal($btn.html(), 'mdo', 'btn text equals mdo')
35 | $btn.bootstrapButton('loading')
36 | stop()
37 | setTimeout(function () {
38 | equal($btn.html(), 'fat', 'btn text equals fat')
39 | ok($btn[0].hasAttribute('disabled'), 'btn is disabled')
40 | ok($btn.hasClass('disabled'), 'btn has disabled class')
41 | start()
42 | }, 0)
43 | })
44 |
45 | test('should return reset state', function () {
46 | var $btn = $('mdo ')
47 | equal($btn.html(), 'mdo', 'btn text equals mdo')
48 | $btn.bootstrapButton('loading')
49 | stop()
50 | setTimeout(function () {
51 | equal($btn.html(), 'fat', 'btn text equals fat')
52 | ok($btn[0].hasAttribute('disabled'), 'btn is disabled')
53 | ok($btn.hasClass('disabled'), 'btn has disabled class')
54 | start()
55 | stop()
56 | $btn.bootstrapButton('reset')
57 | setTimeout(function () {
58 | equal($btn.html(), 'mdo', 'btn text equals mdo')
59 | ok(!$btn[0].hasAttribute('disabled'), 'btn is not disabled')
60 | ok(!$btn.hasClass('disabled'), 'btn does not have disabled class')
61 | start()
62 | }, 0)
63 | }, 0)
64 | })
65 |
66 | test('should work with an empty string as reset state', function () {
67 | var $btn = $(' ')
68 | equal($btn.html(), '', 'btn text equals ""')
69 | $btn.bootstrapButton('loading')
70 | stop()
71 | setTimeout(function () {
72 | equal($btn.html(), 'fat', 'btn text equals fat')
73 | ok($btn[0].hasAttribute('disabled'), 'btn is disabled')
74 | ok($btn.hasClass('disabled'), 'btn has disabled class')
75 | start()
76 | stop()
77 | $btn.bootstrapButton('reset')
78 | setTimeout(function () {
79 | equal($btn.html(), '', 'btn text equals ""')
80 | ok(!$btn[0].hasAttribute('disabled'), 'btn is not disabled')
81 | ok(!$btn.hasClass('disabled'), 'btn does not have disabled class')
82 | start()
83 | }, 0)
84 | }, 0)
85 | })
86 |
87 | test('should toggle active', function () {
88 | var $btn = $('mdo ')
89 | ok(!$btn.hasClass('active'), 'btn does not have active class')
90 | $btn.bootstrapButton('toggle')
91 | ok($btn.hasClass('active'), 'btn has class active')
92 | })
93 |
94 | test('should toggle active when btn children are clicked', function () {
95 | var $btn = $('mdo ')
96 | var $inner = $(' ')
97 | $btn
98 | .append($inner)
99 | .appendTo('#qunit-fixture')
100 | ok(!$btn.hasClass('active'), 'btn does not have active class')
101 | $inner.click()
102 | ok($btn.hasClass('active'), 'btn has class active')
103 | })
104 |
105 | test('should toggle aria-pressed', function () {
106 | var $btn = $('redux ')
107 | equal($btn.attr('aria-pressed'), 'false', 'btn aria-pressed state is false')
108 | $btn.bootstrapButton('toggle')
109 | equal($btn.attr('aria-pressed'), 'true', 'btn aria-pressed state is true')
110 | })
111 |
112 | test('should toggle aria-pressed when btn children are clicked', function () {
113 | var $btn = $('redux ')
114 | var $inner = $(' ')
115 | $btn
116 | .append($inner)
117 | .appendTo('#qunit-fixture')
118 | equal($btn.attr('aria-pressed'), 'false', 'btn aria-pressed state is false')
119 | $inner.click()
120 | equal($btn.attr('aria-pressed'), 'true', 'btn aria-pressed state is true')
121 | })
122 |
123 | test('should toggle active when btn children are clicked within btn-group', function () {
124 | var $btngroup = $('
')
125 | var $btn = $('fat ')
126 | var $inner = $(' ')
127 | $btngroup
128 | .append($btn.append($inner))
129 | .appendTo('#qunit-fixture')
130 | ok(!$btn.hasClass('active'), 'btn does not have active class')
131 | $inner.click()
132 | ok($btn.hasClass('active'), 'btn has class active')
133 | })
134 |
135 | test('should check for closest matching toggle', function () {
136 | var groupHTML = ''
137 | + ''
138 | + ' Option 1'
139 | + ' '
140 | + ''
141 | + ' Option 2'
142 | + ' '
143 | + ''
144 | + ' Option 3'
145 | + ' '
146 | + '
'
147 | var $group = $(groupHTML).appendTo('#qunit-fixture')
148 |
149 | var $btn1 = $group.children().eq(0)
150 | var $btn2 = $group.children().eq(1)
151 |
152 | ok($btn1.hasClass('active'), 'btn1 has active class')
153 | ok($btn1.find('input').prop('checked'), 'btn1 is checked')
154 | ok(!$btn2.hasClass('active'), 'btn2 does not have active class')
155 | ok(!$btn2.find('input').prop('checked'), 'btn2 is not checked')
156 | $btn2.find('input').click()
157 | ok(!$btn1.hasClass('active'), 'btn1 does not have active class')
158 | ok(!$btn1.find('input').prop('checked'), 'btn1 is checked')
159 | ok($btn2.hasClass('active'), 'btn2 has active class')
160 | ok($btn2.find('input').prop('checked'), 'btn2 is checked')
161 |
162 | $btn2.find('input').click() // clicking an already checked radio should not un-check it
163 | ok(!$btn1.hasClass('active'), 'btn1 does not have active class')
164 | ok(!$btn1.find('input').prop('checked'), 'btn1 is checked')
165 | ok($btn2.hasClass('active'), 'btn2 has active class')
166 | ok($btn2.find('input').prop('checked'), 'btn2 is checked')
167 | })
168 |
169 | })
170 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/tests/unit/scrollspy.js:
--------------------------------------------------------------------------------
1 | $(function () {
2 | 'use strict';
3 |
4 | module('scrollspy plugin')
5 |
6 | test('should be defined on jquery object', function () {
7 | ok($(document.body).scrollspy, 'scrollspy method is defined')
8 | })
9 |
10 | module('scrollspy', {
11 | setup: function () {
12 | // Run all tests in noConflict mode -- it's the only way to ensure that the plugin works in noConflict mode
13 | $.fn.bootstrapScrollspy = $.fn.scrollspy.noConflict()
14 | },
15 | teardown: function () {
16 | $.fn.scrollspy = $.fn.bootstrapScrollspy
17 | delete $.fn.bootstrapScrollspy
18 | }
19 | })
20 |
21 | test('should provide no conflict', function () {
22 | strictEqual($.fn.scrollspy, undefined, 'scrollspy was set back to undefined (org value)')
23 | })
24 |
25 | test('should return jquery collection containing the element', function () {
26 | var $el = $('
')
27 | var $scrollspy = $el.bootstrapScrollspy()
28 | ok($scrollspy instanceof $, 'returns jquery collection')
29 | strictEqual($scrollspy[0], $el[0], 'collection contains element')
30 | })
31 |
32 | test('should only switch "active" class on current target', function () {
33 | stop()
34 |
35 | var sectionHTML = ''
36 | + '
'
46 | + '
'
60 | + '
'
61 | var $section = $(sectionHTML).appendTo('#qunit-fixture')
62 |
63 | var $scrollspy = $section
64 | .show()
65 | .find('#scrollspy-example')
66 | .bootstrapScrollspy({ target: '#ss-target' })
67 |
68 | $scrollspy.on('scroll.bs.scrollspy', function () {
69 | ok($section.hasClass('active'), '"active" class still on root node')
70 | start()
71 | })
72 |
73 | $scrollspy.scrollTop(350)
74 | })
75 |
76 | test('should correctly select middle navigation option when large offset is used', function () {
77 | stop()
78 |
79 | var sectionHTML = ''
80 | + ''
81 | + ''
86 | + ' '
87 | + ''
88 | + '
'
89 | + '
'
90 | + '
'
91 | + '
'
92 | var $section = $(sectionHTML).appendTo('#qunit-fixture')
93 | var $scrollspy = $section
94 | .show()
95 | .filter('#content')
96 |
97 | $scrollspy.bootstrapScrollspy({ target: '#navigation', offset: $scrollspy.position().top })
98 |
99 | $scrollspy.on('scroll.bs.scrollspy', function () {
100 | ok(!$section.find('#one-link').parent().hasClass('active'), '"active" class removed from first section')
101 | ok($section.find('#two-link').parent().hasClass('active'), '"active" class on middle section')
102 | ok(!$section.find('#three-link').parent().hasClass('active'), '"active" class not on last section')
103 | start()
104 | })
105 |
106 | $scrollspy.scrollTop(550)
107 | })
108 |
109 | test('should add the active class to the correct element', function () {
110 | var navbarHtml =
111 | ''
112 | + ''
116 | + ' '
117 | var contentHtml =
118 | ''
119 | + '
div 1
'
120 | + '
div 2
'
121 | + '
'
122 |
123 | $(navbarHtml).appendTo('#qunit-fixture')
124 | var $content = $(contentHtml)
125 | .appendTo('#qunit-fixture')
126 | .bootstrapScrollspy({ offset: 0, target: '.navbar' })
127 |
128 | var testElementIsActiveAfterScroll = function (element, target) {
129 | var deferred = $.Deferred()
130 | var scrollHeight = Math.ceil($content.scrollTop() + $(target).position().top)
131 | stop()
132 | $content.one('scroll', function () {
133 | ok($(element).hasClass('active'), 'target:' + target + ', element' + element)
134 | start()
135 | deferred.resolve()
136 | })
137 | $content.scrollTop(scrollHeight)
138 | return deferred.promise()
139 | }
140 |
141 | $.when(testElementIsActiveAfterScroll('#li-1', '#div-1'))
142 | .then(function () { return testElementIsActiveAfterScroll('#li-2', '#div-2') })
143 | })
144 |
145 | test('should clear selection if above the first section', function () {
146 | stop()
147 |
148 | var sectionHTML = ''
149 | + ''
150 | + ''
151 | + 'One '
152 | + 'Two '
153 | + 'Three '
154 | + ' '
155 | + ' '
156 | $(sectionHTML).appendTo('#qunit-fixture')
157 |
158 | var scrollspyHTML = ''
159 | + '
'
160 | + '
'
161 | + '
'
162 | + '
'
163 | + '
'
164 | + '
'
165 | var $scrollspy = $(scrollspyHTML).appendTo('#qunit-fixture')
166 |
167 | $scrollspy
168 | .bootstrapScrollspy({
169 | target: '#navigation',
170 | offset: $scrollspy.position().top
171 | })
172 | .one('scroll.bs.scrollspy', function () {
173 | strictEqual($('.active').length, 1, '"active" class on only one element present')
174 | strictEqual($('.active').has('#two-link').length, 1, '"active" class on second section')
175 |
176 | $scrollspy
177 | .one('scroll.bs.scrollspy', function () {
178 | strictEqual($('.active').length, 0, 'selection cleared')
179 | start()
180 | })
181 | .scrollTop(0)
182 | })
183 | .scrollTop(201)
184 | })
185 |
186 | })
187 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/tests/unit/tab.js:
--------------------------------------------------------------------------------
1 | $(function () {
2 | 'use strict';
3 |
4 | module('tabs plugin')
5 |
6 | test('should be defined on jquery object', function () {
7 | ok($(document.body).tab, 'tabs method is defined')
8 | })
9 |
10 | module('tabs', {
11 | setup: function () {
12 | // Run all tests in noConflict mode -- it's the only way to ensure that the plugin works in noConflict mode
13 | $.fn.bootstrapTab = $.fn.tab.noConflict()
14 | },
15 | teardown: function () {
16 | $.fn.tab = $.fn.bootstrapTab
17 | delete $.fn.bootstrapTab
18 | }
19 | })
20 |
21 | test('should provide no conflict', function () {
22 | strictEqual($.fn.tab, undefined, 'tab was set back to undefined (org value)')
23 | })
24 |
25 | test('should return jquery collection containing the element', function () {
26 | var $el = $('
')
27 | var $tab = $el.bootstrapTab()
28 | ok($tab instanceof $, 'returns jquery collection')
29 | strictEqual($tab[0], $el[0], 'collection contains element')
30 | })
31 |
32 | test('should activate element by tab id', function () {
33 | var tabsHTML = ''
37 |
38 | $('').appendTo('#qunit-fixture')
39 |
40 | $(tabsHTML).find('li:last a').bootstrapTab('show')
41 | equal($('#qunit-fixture').find('.active').attr('id'), 'profile')
42 |
43 | $(tabsHTML).find('li:first a').bootstrapTab('show')
44 | equal($('#qunit-fixture').find('.active').attr('id'), 'home')
45 | })
46 |
47 | test('should activate element by tab id', function () {
48 | var pillsHTML = ''
52 |
53 | $('').appendTo('#qunit-fixture')
54 |
55 | $(pillsHTML).find('li:last a').bootstrapTab('show')
56 | equal($('#qunit-fixture').find('.active').attr('id'), 'profile')
57 |
58 | $(pillsHTML).find('li:first a').bootstrapTab('show')
59 | equal($('#qunit-fixture').find('.active').attr('id'), 'home')
60 | })
61 |
62 | test('should not fire shown when show is prevented', function () {
63 | stop()
64 |
65 | $('
')
66 | .on('show.bs.tab', function (e) {
67 | e.preventDefault()
68 | ok(true, 'show event fired')
69 | start()
70 | })
71 | .on('shown.bs.tab', function () {
72 | ok(false, 'shown event fired')
73 | })
74 | .bootstrapTab('show')
75 | })
76 |
77 | test('show and shown events should reference correct relatedTarget', function () {
78 | stop()
79 |
80 | var dropHTML = ''
81 | + '1 '
82 | + ''
86 | + ' '
87 | + ' '
88 |
89 | $(dropHTML)
90 | .find('ul > li:first a')
91 | .bootstrapTab('show')
92 | .end()
93 | .find('ul > li:last a')
94 | .on('show.bs.tab', function (e) {
95 | equal(e.relatedTarget.hash, '#1-1', 'references correct element as relatedTarget')
96 | start()
97 | })
98 | .on('shown.bs.tab', function (e) {
99 | equal(e.relatedTarget.hash, '#1-1', 'references correct element as relatedTarget')
100 | })
101 | .bootstrapTab('show')
102 | })
103 |
104 | test('should fire hide and hidden events', function () {
105 | stop()
106 |
107 | var tabsHTML = ''
111 |
112 | $(tabsHTML)
113 | .find('li:first a')
114 | .on('hide.bs.tab', function () {
115 | ok(true, 'hide event fired')
116 | })
117 | .bootstrapTab('show')
118 | .end()
119 | .find('li:last a')
120 | .bootstrapTab('show')
121 |
122 | $(tabsHTML)
123 | .find('li:first a')
124 | .on('hidden.bs.tab', function () {
125 | ok(true, 'hidden event fired')
126 | start()
127 | })
128 | .bootstrapTab('show')
129 | .end()
130 | .find('li:last a')
131 | .bootstrapTab('show')
132 | })
133 |
134 | test('should not fire hidden when hide is prevented', function () {
135 | stop()
136 |
137 | var tabsHTML = ''
141 |
142 | $(tabsHTML)
143 | .find('li:first a')
144 | .on('hide.bs.tab', function (e) {
145 | e.preventDefault()
146 | ok(true, 'hide event fired')
147 | start()
148 | })
149 | .on('hidden.bs.tab', function () {
150 | ok(false, 'hidden event fired')
151 | })
152 | .bootstrapTab('show')
153 | .end()
154 | .find('li:last a')
155 | .bootstrapTab('show')
156 | })
157 |
158 | test('hide and hidden events contain correct relatedTarget', function () {
159 | stop()
160 |
161 | var tabsHTML = ''
165 |
166 | $(tabsHTML)
167 | .find('li:first a')
168 | .on('hide.bs.tab', function (e) {
169 | equal(e.relatedTarget.hash, '#profile', 'references correct element as relatedTarget')
170 | })
171 | .on('hidden.bs.tab', function (e) {
172 | equal(e.relatedTarget.hash, '#profile', 'references correct element as relatedTarget')
173 | start()
174 | })
175 | .bootstrapTab('show')
176 | .end()
177 | .find('li:last a')
178 | .bootstrapTab('show')
179 | })
180 |
181 | test('selected tab should have aria-expanded', function () {
182 | var tabsHTML = ''
186 | var $tabs = $(tabsHTML).appendTo('#qunit-fixture')
187 |
188 | $tabs.find('li:first a').bootstrapTab('show')
189 | equal($tabs.find('.active a').attr('aria-expanded'), 'true', 'shown tab has aria-expanded = true')
190 | equal($tabs.find('li:not(.active) a').attr('aria-expanded'), 'false', 'hidden tab has aria-expanded = false')
191 |
192 | $tabs.find('li:last a').click()
193 | equal($tabs.find('.active a').attr('aria-expanded'), 'true', 'after click, shown tab has aria-expanded = true')
194 | equal($tabs.find('li:not(.active) a').attr('aria-expanded'), 'false', 'after click, hidden tab has aria-expanded = false')
195 |
196 | $tabs.find('li:first a').bootstrapTab('show')
197 | equal($tabs.find('.active a').attr('aria-expanded'), 'true', 'shown tab has aria-expanded = true')
198 | equal($tabs.find('li:not(.active) a').attr('aria-expanded'), 'false', 'hidden tab has aria-expanded = false')
199 |
200 | $tabs.find('li:first a').click()
201 | equal($tabs.find('.active a').attr('aria-expanded'), 'true', 'after second show event, shown tab still has aria-expanded = true')
202 | equal($tabs.find('li:not(.active) a').attr('aria-expanded'), 'false', 'after second show event, hidden tab has aria-expanded = false')
203 | })
204 |
205 | })
206 |
--------------------------------------------------------------------------------
/examples/cutomStyleHeight.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
19 |
20 |
28 |
29 |
30 |
31 | TableHeadFixer Custom Height
32 |
33 | This table has height: 300px
34 |
35 |
36 |
37 |
38 | Ano
39 | Jan
40 | Fev
41 | Mar
42 | Abr
43 | Maio
44 | Total
45 |
46 |
47 |
48 |
49 | 2010
50 | 100.00
51 | 100.00
52 | 100.00
53 | 100.00
54 | 100.00
55 | 500.00
56 |
57 |
58 | 2011
59 | 110.00
60 | 110.00
61 | 110.00
62 | 110.00
63 | 110.00
64 | 550.00
65 |
66 |
67 | 2012
68 | 110.00
69 | 110.00
70 | 110.00
71 | 110.00
72 | 110.00
73 | 550.00
74 |
75 |
76 | 2011
77 | 110.00
78 | 110.00
79 | 110.00
80 | 110.00
81 | 110.00
82 | 550.00
83 |
84 |
85 | 2012
86 | 110.00
87 | 110.00
88 | 110.00
89 | 110.00
90 | 110.00
91 | 550.00
92 |
93 |
94 | 2011
95 | 110.00
96 | 110.00
97 | 110.00
98 | 110.00
99 | 110.00
100 | 550.00
101 |
102 |
103 | 2012
104 | 110.00
105 | 110.00
106 | 110.00
107 | 110.00
108 | 110.00
109 | 550.00
110 |
111 |
112 | 2011
113 | 110.00
114 | 110.00
115 | 110.00
116 | 110.00
117 | 110.00
118 | 550.00
119 |
120 |
121 | 2012
122 | 110.00
123 | 110.00
124 | 110.00
125 | 110.00
126 | 110.00
127 | 550.00
128 |
129 |
130 |
131 |
132 | This table has max-height: 300px
133 |
134 |
135 |
136 |
137 | Ano
138 | Jan
139 | Fev
140 | Mar
141 | Abr
142 | Maio
143 | Total
144 |
145 |
146 |
147 |
148 | 2010
149 | 100.00
150 | 100.00
151 | 100.00
152 | 100.00
153 | 100.00
154 | 500.00
155 |
156 |
157 | 2011
158 | 110.00
159 | 110.00
160 | 110.00
161 | 110.00
162 | 110.00
163 | 550.00
164 |
165 |
166 | 2012
167 | 110.00
168 | 110.00
169 | 110.00
170 | 110.00
171 | 110.00
172 | 550.00
173 |
174 |
175 | 2011
176 | 110.00
177 | 110.00
178 | 110.00
179 | 110.00
180 | 110.00
181 | 550.00
182 |
183 |
184 | 2012
185 | 110.00
186 | 110.00
187 | 110.00
188 | 110.00
189 | 110.00
190 | 550.00
191 |
192 |
193 | 2011
194 | 110.00
195 | 110.00
196 | 110.00
197 | 110.00
198 | 110.00
199 | 550.00
200 |
201 |
202 | 2012
203 | 110.00
204 | 110.00
205 | 110.00
206 | 110.00
207 | 110.00
208 | 550.00
209 |
210 |
211 | 2011
212 | 110.00
213 | 110.00
214 | 110.00
215 | 110.00
216 | 110.00
217 | 550.00
218 |
219 |
220 | 2012
221 | 110.00
222 | 110.00
223 | 110.00
224 | 110.00
225 | 110.00
226 | 550.00
227 |
228 |
229 |
230 |
231 | This table has min-height: 300px
232 |
233 |
234 |
235 |
236 | Ano
237 | Jan
238 | Fev
239 | Mar
240 | Abr
241 | Maio
242 | Total
243 |
244 |
245 |
246 |
247 | 2010
248 | 100.00
249 | 100.00
250 | 100.00
251 | 100.00
252 | 100.00
253 | 500.00
254 |
255 |
256 | 2011
257 | 110.00
258 | 110.00
259 | 110.00
260 | 110.00
261 | 110.00
262 | 550.00
263 |
264 |
265 | 2012
266 | 110.00
267 | 110.00
268 | 110.00
269 | 110.00
270 | 110.00
271 | 550.00
272 |
273 |
274 | 2011
275 | 110.00
276 | 110.00
277 | 110.00
278 | 110.00
279 | 110.00
280 | 550.00
281 |
282 |
283 | 2012
284 | 110.00
285 | 110.00
286 | 110.00
287 | 110.00
288 | 110.00
289 | 550.00
290 |
291 |
292 | 2011
293 | 110.00
294 | 110.00
295 | 110.00
296 | 110.00
297 | 110.00
298 | 550.00
299 |
300 |
301 | 2012
302 | 110.00
303 | 110.00
304 | 110.00
305 | 110.00
306 | 110.00
307 | 550.00
308 |
309 |
310 | 2011
311 | 110.00
312 | 110.00
313 | 110.00
314 | 110.00
315 | 110.00
316 | 550.00
317 |
318 |
319 | 2012
320 | 110.00
321 | 110.00
322 | 110.00
323 | 110.00
324 | 110.00
325 | 550.00
326 |
327 |
328 |
329 |
330 |
331 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/carousel.js:
--------------------------------------------------------------------------------
1 | /* ========================================================================
2 | * Bootstrap: carousel.js v3.3.2
3 | * http://getbootstrap.com/javascript/#carousel
4 | * ========================================================================
5 | * Copyright 2011-2015 Twitter, Inc.
6 | * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
7 | * ======================================================================== */
8 |
9 |
10 | +function ($) {
11 | 'use strict';
12 |
13 | // CAROUSEL CLASS DEFINITION
14 | // =========================
15 |
16 | var Carousel = function (element, options) {
17 | this.$element = $(element)
18 | this.$indicators = this.$element.find('.carousel-indicators')
19 | this.options = options
20 | this.paused =
21 | this.sliding =
22 | this.interval =
23 | this.$active =
24 | this.$items = null
25 |
26 | this.options.keyboard && this.$element.on('keydown.bs.carousel', $.proxy(this.keydown, this))
27 |
28 | this.options.pause == 'hover' && !('ontouchstart' in document.documentElement) && this.$element
29 | .on('mouseenter.bs.carousel', $.proxy(this.pause, this))
30 | .on('mouseleave.bs.carousel', $.proxy(this.cycle, this))
31 | }
32 |
33 | Carousel.VERSION = '3.3.2'
34 |
35 | Carousel.TRANSITION_DURATION = 600
36 |
37 | Carousel.DEFAULTS = {
38 | interval: 5000,
39 | pause: 'hover',
40 | wrap: true,
41 | keyboard: true
42 | }
43 |
44 | Carousel.prototype.keydown = function (e) {
45 | if (/input|textarea/i.test(e.target.tagName)) return
46 | switch (e.which) {
47 | case 37: this.prev(); break
48 | case 39: this.next(); break
49 | default: return
50 | }
51 |
52 | e.preventDefault()
53 | }
54 |
55 | Carousel.prototype.cycle = function (e) {
56 | e || (this.paused = false)
57 |
58 | this.interval && clearInterval(this.interval)
59 |
60 | this.options.interval
61 | && !this.paused
62 | && (this.interval = setInterval($.proxy(this.next, this), this.options.interval))
63 |
64 | return this
65 | }
66 |
67 | Carousel.prototype.getItemIndex = function (item) {
68 | this.$items = item.parent().children('.item')
69 | return this.$items.index(item || this.$active)
70 | }
71 |
72 | Carousel.prototype.getItemForDirection = function (direction, active) {
73 | var activeIndex = this.getItemIndex(active)
74 | var willWrap = (direction == 'prev' && activeIndex === 0)
75 | || (direction == 'next' && activeIndex == (this.$items.length - 1))
76 | if (willWrap && !this.options.wrap) return active
77 | var delta = direction == 'prev' ? -1 : 1
78 | var itemIndex = (activeIndex + delta) % this.$items.length
79 | return this.$items.eq(itemIndex)
80 | }
81 |
82 | Carousel.prototype.to = function (pos) {
83 | var that = this
84 | var activeIndex = this.getItemIndex(this.$active = this.$element.find('.item.active'))
85 |
86 | if (pos > (this.$items.length - 1) || pos < 0) return
87 |
88 | if (this.sliding) return this.$element.one('slid.bs.carousel', function () { that.to(pos) }) // yes, "slid"
89 | if (activeIndex == pos) return this.pause().cycle()
90 |
91 | return this.slide(pos > activeIndex ? 'next' : 'prev', this.$items.eq(pos))
92 | }
93 |
94 | Carousel.prototype.pause = function (e) {
95 | e || (this.paused = true)
96 |
97 | if (this.$element.find('.next, .prev').length && $.support.transition) {
98 | this.$element.trigger($.support.transition.end)
99 | this.cycle(true)
100 | }
101 |
102 | this.interval = clearInterval(this.interval)
103 |
104 | return this
105 | }
106 |
107 | Carousel.prototype.next = function () {
108 | if (this.sliding) return
109 | return this.slide('next')
110 | }
111 |
112 | Carousel.prototype.prev = function () {
113 | if (this.sliding) return
114 | return this.slide('prev')
115 | }
116 |
117 | Carousel.prototype.slide = function (type, next) {
118 | var $active = this.$element.find('.item.active')
119 | var $next = next || this.getItemForDirection(type, $active)
120 | var isCycling = this.interval
121 | var direction = type == 'next' ? 'left' : 'right'
122 | var that = this
123 |
124 | if ($next.hasClass('active')) return (this.sliding = false)
125 |
126 | var relatedTarget = $next[0]
127 | var slideEvent = $.Event('slide.bs.carousel', {
128 | relatedTarget: relatedTarget,
129 | direction: direction
130 | })
131 | this.$element.trigger(slideEvent)
132 | if (slideEvent.isDefaultPrevented()) return
133 |
134 | this.sliding = true
135 |
136 | isCycling && this.pause()
137 |
138 | if (this.$indicators.length) {
139 | this.$indicators.find('.active').removeClass('active')
140 | var $nextIndicator = $(this.$indicators.children()[this.getItemIndex($next)])
141 | $nextIndicator && $nextIndicator.addClass('active')
142 | }
143 |
144 | var slidEvent = $.Event('slid.bs.carousel', { relatedTarget: relatedTarget, direction: direction }) // yes, "slid"
145 | if ($.support.transition && this.$element.hasClass('slide')) {
146 | $next.addClass(type)
147 | $next[0].offsetWidth // force reflow
148 | $active.addClass(direction)
149 | $next.addClass(direction)
150 | $active
151 | .one('bsTransitionEnd', function () {
152 | $next.removeClass([type, direction].join(' ')).addClass('active')
153 | $active.removeClass(['active', direction].join(' '))
154 | that.sliding = false
155 | setTimeout(function () {
156 | that.$element.trigger(slidEvent)
157 | }, 0)
158 | })
159 | .emulateTransitionEnd(Carousel.TRANSITION_DURATION)
160 | } else {
161 | $active.removeClass('active')
162 | $next.addClass('active')
163 | this.sliding = false
164 | this.$element.trigger(slidEvent)
165 | }
166 |
167 | isCycling && this.cycle()
168 |
169 | return this
170 | }
171 |
172 |
173 | // CAROUSEL PLUGIN DEFINITION
174 | // ==========================
175 |
176 | function Plugin(option) {
177 | return this.each(function () {
178 | var $this = $(this)
179 | var data = $this.data('bs.carousel')
180 | var options = $.extend({}, Carousel.DEFAULTS, $this.data(), typeof option == 'object' && option)
181 | var action = typeof option == 'string' ? option : options.slide
182 |
183 | if (!data) $this.data('bs.carousel', (data = new Carousel(this, options)))
184 | if (typeof option == 'number') data.to(option)
185 | else if (action) data[action]()
186 | else if (options.interval) data.pause().cycle()
187 | })
188 | }
189 |
190 | var old = $.fn.carousel
191 |
192 | $.fn.carousel = Plugin
193 | $.fn.carousel.Constructor = Carousel
194 |
195 |
196 | // CAROUSEL NO CONFLICT
197 | // ====================
198 |
199 | $.fn.carousel.noConflict = function () {
200 | $.fn.carousel = old
201 | return this
202 | }
203 |
204 |
205 | // CAROUSEL DATA-API
206 | // =================
207 |
208 | var clickHandler = function (e) {
209 | var href
210 | var $this = $(this)
211 | var $target = $($this.attr('data-target') || (href = $this.attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '')) // strip for ie7
212 | if (!$target.hasClass('carousel')) return
213 | var options = $.extend({}, $target.data(), $this.data())
214 | var slideIndex = $this.attr('data-slide-to')
215 | if (slideIndex) options.interval = false
216 |
217 | Plugin.call($target, options)
218 |
219 | if (slideIndex) {
220 | $target.data('bs.carousel').to(slideIndex)
221 | }
222 |
223 | e.preventDefault()
224 | }
225 |
226 | $(document)
227 | .on('click.bs.carousel.data-api', '[data-slide]', clickHandler)
228 | .on('click.bs.carousel.data-api', '[data-slide-to]', clickHandler)
229 |
230 | $(window).on('load', function () {
231 | $('[data-ride="carousel"]').each(function () {
232 | var $carousel = $(this)
233 | Plugin.call($carousel, $carousel.data())
234 | })
235 | })
236 |
237 | }(jQuery);
238 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/tests/unit/popover.js:
--------------------------------------------------------------------------------
1 | $(function () {
2 | 'use strict';
3 |
4 | module('popover plugin')
5 |
6 | test('should be defined on jquery object', function () {
7 | ok($(document.body).popover, 'popover method is defined')
8 | })
9 |
10 | module('popover', {
11 | setup: function () {
12 | // Run all tests in noConflict mode -- it's the only way to ensure that the plugin works in noConflict mode
13 | $.fn.bootstrapPopover = $.fn.popover.noConflict()
14 | },
15 | teardown: function () {
16 | $.fn.popover = $.fn.bootstrapPopover
17 | delete $.fn.bootstrapPopover
18 | }
19 | })
20 |
21 | test('should provide no conflict', function () {
22 | strictEqual($.fn.popover, undefined, 'popover was set back to undefined (org value)')
23 | })
24 |
25 | test('should return jquery collection containing the element', function () {
26 | var $el = $('
')
27 | var $popover = $el.bootstrapPopover()
28 | ok($popover instanceof $, 'returns jquery collection')
29 | strictEqual($popover[0], $el[0], 'collection contains element')
30 | })
31 |
32 | test('should render popover element', function () {
33 | var $popover = $('@mdo ')
34 | .appendTo('#qunit-fixture')
35 | .bootstrapPopover('show')
36 |
37 | notEqual($('.popover').length, 0, 'popover was inserted')
38 | $popover.bootstrapPopover('hide')
39 | equal($('.popover').length, 0, 'popover removed')
40 | })
41 |
42 | test('should store popover instance in popover data object', function () {
43 | var $popover = $('@mdo ').bootstrapPopover()
44 |
45 | ok($popover.data('bs.popover'), 'popover instance exists')
46 | })
47 |
48 | test('should store popover trigger in popover instance data object', function () {
49 | var $popover = $('@ResentedHook ')
50 | .appendTo('#qunit-fixture')
51 | .bootstrapPopover()
52 |
53 | $popover.bootstrapPopover('show')
54 |
55 | ok($('.popover').data('bs.popover'), 'popover trigger stored in instance data')
56 | })
57 |
58 | test('should get title and content from options', function () {
59 | var $popover = $('@fat ')
60 | .appendTo('#qunit-fixture')
61 | .bootstrapPopover({
62 | title: function () {
63 | return '@fat'
64 | },
65 | content: function () {
66 | return 'loves writing tests (╯°□°)╯︵ ┻━┻'
67 | }
68 | })
69 |
70 | $popover.bootstrapPopover('show')
71 |
72 | notEqual($('.popover').length, 0, 'popover was inserted')
73 | equal($('.popover .popover-title').text(), '@fat', 'title correctly inserted')
74 | equal($('.popover .popover-content').text(), 'loves writing tests (╯°□°)╯︵ ┻━┻', 'content correctly inserted')
75 |
76 | $popover.bootstrapPopover('hide')
77 | equal($('.popover').length, 0, 'popover was removed')
78 | })
79 |
80 | test('should not duplicate HTML object', function () {
81 | var $div = $('
').html('loves writing tests (╯°□°)╯︵ ┻━┻')
82 |
83 | var $popover = $('@fat ')
84 | .appendTo('#qunit-fixture')
85 | .bootstrapPopover({
86 | content: function () {
87 | return $div
88 | }
89 | })
90 |
91 | $popover.bootstrapPopover('show')
92 | notEqual($('.popover').length, 0, 'popover was inserted')
93 | equal($('.popover .popover-content').html(), $div, 'content correctly inserted')
94 |
95 | $popover.bootstrapPopover('hide')
96 | equal($('.popover').length, 0, 'popover was removed')
97 |
98 | $popover.bootstrapPopover('show')
99 | notEqual($('.popover').length, 0, 'popover was inserted')
100 | equal($('.popover .popover-content').html(), $div, 'content correctly inserted')
101 |
102 | $popover.bootstrapPopover('hide')
103 | equal($('.popover').length, 0, 'popover was removed')
104 | })
105 |
106 | test('should get title and content from attributes', function () {
107 | var $popover = $('@mdo ')
108 | .appendTo('#qunit-fixture')
109 | .bootstrapPopover()
110 | .bootstrapPopover('show')
111 |
112 | notEqual($('.popover').length, 0, 'popover was inserted')
113 | equal($('.popover .popover-title').text(), '@mdo', 'title correctly inserted')
114 | equal($('.popover .popover-content').text(), 'loves data attributes (づ。◕‿‿◕。)づ ︵ ┻━┻', 'content correctly inserted')
115 |
116 | $popover.bootstrapPopover('hide')
117 | equal($('.popover').length, 0, 'popover was removed')
118 | })
119 |
120 |
121 | test('should get title and content from attributes ignoring options passed via js', function () {
122 | var $popover = $('@mdo ')
123 | .appendTo('#qunit-fixture')
124 | .bootstrapPopover({
125 | title: 'ignored title option',
126 | content: 'ignored content option'
127 | })
128 | .bootstrapPopover('show')
129 |
130 | notEqual($('.popover').length, 0, 'popover was inserted')
131 | equal($('.popover .popover-title').text(), '@mdo', 'title correctly inserted')
132 | equal($('.popover .popover-content').text(), 'loves data attributes (づ。◕‿‿◕。)づ ︵ ┻━┻', 'content correctly inserted')
133 |
134 | $popover.bootstrapPopover('hide')
135 | equal($('.popover').length, 0, 'popover was removed')
136 | })
137 |
138 | test('should respect custom template', function () {
139 | var $popover = $('@fat ')
140 | .appendTo('#qunit-fixture')
141 | .bootstrapPopover({
142 | title: 'Test',
143 | content: 'Test',
144 | template: ''
145 | })
146 |
147 | $popover.bootstrapPopover('show')
148 |
149 | notEqual($('.popover').length, 0, 'popover was inserted')
150 | ok($('.popover').hasClass('foobar'), 'custom class is present')
151 |
152 | $popover.bootstrapPopover('hide')
153 | equal($('.popover').length, 0, 'popover was removed')
154 | })
155 |
156 | test('should destroy popover', function () {
157 | var $popover = $('
')
158 | .bootstrapPopover({
159 | trigger: 'hover'
160 | })
161 | .on('click.foo', $.noop)
162 |
163 | ok($popover.data('bs.popover'), 'popover has data')
164 | ok($._data($popover[0], 'events').mouseover && $._data($popover[0], 'events').mouseout, 'popover has hover event')
165 | equal($._data($popover[0], 'events').click[0].namespace, 'foo', 'popover has extra click.foo event')
166 |
167 | $popover.bootstrapPopover('show')
168 | $popover.bootstrapPopover('destroy')
169 |
170 | ok(!$popover.hasClass('in'), 'popover is hidden')
171 | ok(!$popover.data('popover'), 'popover does not have data')
172 | equal($._data($popover[0], 'events').click[0].namespace, 'foo', 'popover still has click.foo')
173 | ok(!$._data($popover[0], 'events').mouseover && !$._data($popover[0], 'events').mouseout, 'popover does not have any events')
174 | })
175 |
176 | test('should render popover element using delegated selector', function () {
177 | var $div = $('')
178 | .appendTo('#qunit-fixture')
179 | .bootstrapPopover({
180 | selector: 'a',
181 | trigger: 'click'
182 | })
183 |
184 | $div.find('a').click()
185 | notEqual($('.popover').length, 0, 'popover was inserted')
186 |
187 | $div.find('a').click()
188 | equal($('.popover').length, 0, 'popover was removed')
189 | })
190 |
191 | test('should detach popover content rather than removing it so that event handlers are left intact', function () {
192 | var $content = $('').appendTo('#qunit-fixture')
193 |
194 | var handlerCalled = false
195 | $('.content-with-handler .btn').click(function () {
196 | handlerCalled = true
197 | })
198 |
199 | var $div = $('')
200 | .appendTo('#qunit-fixture')
201 | .bootstrapPopover({
202 | html: true,
203 | trigger: 'manual',
204 | container: 'body',
205 | content: function () {
206 | return $content
207 | }
208 | })
209 |
210 | stop()
211 | $div
212 | .one('shown.bs.popover', function () {
213 | $div
214 | .one('hidden.bs.popover', function () {
215 | $div
216 | .one('shown.bs.popover', function () {
217 | $('.content-with-handler .btn').click()
218 | $div.bootstrapPopover('destroy')
219 | ok(handlerCalled, 'content\'s event handler still present')
220 | start()
221 | })
222 | .bootstrapPopover('show')
223 | })
224 | .bootstrapPopover('hide')
225 | })
226 | .bootstrapPopover('show')
227 | })
228 | })
229 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/tests/unit/modal.js:
--------------------------------------------------------------------------------
1 | $(function () {
2 | 'use strict';
3 |
4 | module('modal plugin')
5 |
6 | test('should be defined on jquery object', function () {
7 | ok($(document.body).modal, 'modal method is defined')
8 | })
9 |
10 | module('modal', {
11 | setup: function () {
12 | // Run all tests in noConflict mode -- it's the only way to ensure that the plugin works in noConflict mode
13 | $.fn.bootstrapModal = $.fn.modal.noConflict()
14 | },
15 | teardown: function () {
16 | $.fn.modal = $.fn.bootstrapModal
17 | delete $.fn.bootstrapModal
18 | }
19 | })
20 |
21 | test('should provide no conflict', function () {
22 | strictEqual($.fn.modal, undefined, 'modal was set back to undefined (orig value)')
23 | })
24 |
25 | test('should return jquery collection containing the element', function () {
26 | var $el = $('
')
27 | var $modal = $el.bootstrapModal()
28 | ok($modal instanceof $, 'returns jquery collection')
29 | strictEqual($modal[0], $el[0], 'collection contains element')
30 | })
31 |
32 | test('should expose defaults var for settings', function () {
33 | ok($.fn.bootstrapModal.Constructor.DEFAULTS, 'default object exposed')
34 | })
35 |
36 | test('should insert into dom when show method is called', function () {
37 | stop()
38 |
39 | $('
')
40 | .on('shown.bs.modal', function () {
41 | notEqual($('#modal-test').length, 0, 'modal inserted into dom')
42 | start()
43 | })
44 | .bootstrapModal('show')
45 | })
46 |
47 | test('should fire show event', function () {
48 | stop()
49 |
50 | $('
')
51 | .on('show.bs.modal', function () {
52 | ok(true, 'show event fired')
53 | start()
54 | })
55 | .bootstrapModal('show')
56 | })
57 |
58 | test('should not fire shown when show was prevented', function () {
59 | stop()
60 |
61 | $('
')
62 | .on('show.bs.modal', function (e) {
63 | e.preventDefault()
64 | ok(true, 'show event fired')
65 | start()
66 | })
67 | .on('shown.bs.modal', function () {
68 | ok(false, 'shown event fired')
69 | })
70 | .bootstrapModal('show')
71 | })
72 |
73 | test('should hide modal when hide is called', function () {
74 | stop()
75 |
76 | $('
')
77 | .on('shown.bs.modal', function () {
78 | ok($('#modal-test').is(':visible'), 'modal visible')
79 | notEqual($('#modal-test').length, 0, 'modal inserted into dom')
80 | $(this).bootstrapModal('hide')
81 | })
82 | .on('hidden.bs.modal', function () {
83 | ok(!$('#modal-test').is(':visible'), 'modal hidden')
84 | start()
85 | })
86 | .bootstrapModal('show')
87 | })
88 |
89 | test('should toggle when toggle is called', function () {
90 | stop()
91 |
92 | $('
')
93 | .on('shown.bs.modal', function () {
94 | ok($('#modal-test').is(':visible'), 'modal visible')
95 | notEqual($('#modal-test').length, 0, 'modal inserted into dom')
96 | $(this).bootstrapModal('toggle')
97 | })
98 | .on('hidden.bs.modal', function () {
99 | ok(!$('#modal-test').is(':visible'), 'modal hidden')
100 | start()
101 | })
102 | .bootstrapModal('toggle')
103 | })
104 |
105 | test('should remove from dom when click [data-dismiss="modal"]', function () {
106 | stop()
107 |
108 | $('
')
109 | .on('shown.bs.modal', function () {
110 | ok($('#modal-test').is(':visible'), 'modal visible')
111 | notEqual($('#modal-test').length, 0, 'modal inserted into dom')
112 | $(this).find('.close').click()
113 | })
114 | .on('hidden.bs.modal', function () {
115 | ok(!$('#modal-test').is(':visible'), 'modal hidden')
116 | start()
117 | })
118 | .bootstrapModal('toggle')
119 | })
120 |
121 | test('should allow modal close with "backdrop:false"', function () {
122 | stop()
123 |
124 | $('
')
125 | .on('shown.bs.modal', function () {
126 | ok($('#modal-test').is(':visible'), 'modal visible')
127 | $(this).bootstrapModal('hide')
128 | })
129 | .on('hidden.bs.modal', function () {
130 | ok(!$('#modal-test').is(':visible'), 'modal hidden')
131 | start()
132 | })
133 | .bootstrapModal('show')
134 | })
135 |
136 | test('should close modal when clicking outside of modal-content', function () {
137 | stop()
138 |
139 | $('')
140 | .on('shown.bs.modal', function () {
141 | notEqual($('#modal-test').length, 0, 'modal insterted into dom')
142 | $('.contents').click()
143 | ok($('#modal-test').is(':visible'), 'modal visible')
144 | $('#modal-test .modal-backdrop').click()
145 | })
146 | .on('hidden.bs.modal', function () {
147 | ok(!$('#modal-test').is(':visible'), 'modal hidden')
148 | start()
149 | })
150 | .bootstrapModal('show')
151 | })
152 |
153 | test('should close modal when escape key is pressed via keydown', function () {
154 | stop()
155 |
156 | var div = $('
')
157 | div
158 | .on('shown.bs.modal', function () {
159 | ok($('#modal-test').length, 'modal insterted into dom')
160 | ok($('#modal-test').is(':visible'), 'modal visible')
161 | div.trigger($.Event('keydown', { which: 27 }))
162 |
163 | setTimeout(function () {
164 | ok(!$('#modal-test').is(':visible'), 'modal hidden')
165 | div.remove()
166 | start()
167 | }, 0)
168 | })
169 | .bootstrapModal('show')
170 | })
171 |
172 | test('should not close modal when escape key is pressed via keyup', function () {
173 | stop()
174 |
175 | var div = $('
')
176 | div
177 | .on('shown.bs.modal', function () {
178 | ok($('#modal-test').length, 'modal insterted into dom')
179 | ok($('#modal-test').is(':visible'), 'modal visible')
180 | div.trigger($.Event('keyup', { which: 27 }))
181 |
182 | setTimeout(function () {
183 | ok($('#modal-test').is(':visible'), 'modal still visible')
184 | div.remove()
185 | start()
186 | }, 0)
187 | })
188 | .bootstrapModal('show')
189 | })
190 |
191 | test('should trigger hide event once when clicking outside of modal-content', function () {
192 | stop()
193 |
194 | var triggered
195 |
196 | $('')
197 | .on('shown.bs.modal', function () {
198 | triggered = 0
199 | $('#modal-test .modal-backdrop').click()
200 | })
201 | .on('hide.bs.modal', function () {
202 | triggered += 1
203 | strictEqual(triggered, 1, 'modal hide triggered once')
204 | start()
205 | })
206 | .bootstrapModal('show')
207 | })
208 |
209 | test('should close reopened modal with [data-dismiss="modal"] click', function () {
210 | stop()
211 |
212 | $('')
213 | .on('shown.bs.modal', function () {
214 | $('#close').click()
215 | ok(!$('#modal-test').is(':visible'), 'modal hidden')
216 | })
217 | .one('hidden.bs.modal', function () {
218 | $(this)
219 | .one('hidden.bs.modal', function () {
220 | start()
221 | })
222 | .bootstrapModal('show')
223 | })
224 | .bootstrapModal('show')
225 | })
226 |
227 | test('should restore focus to toggling element when modal is hidden after having been opened via data-api', function () {
228 | stop()
229 |
230 | var $toggleBtn = $(' ').appendTo('#qunit-fixture')
231 |
232 | $('')
233 | .on('hidden.bs.modal', function () {
234 | setTimeout(function () {
235 | ok($(document.activeElement).is($toggleBtn), 'toggling element is once again focused')
236 | start()
237 | }, 0)
238 | })
239 | .on('shown.bs.modal', function () {
240 | $('#close').click()
241 | })
242 | .appendTo('#qunit-fixture')
243 |
244 | $toggleBtn.click()
245 | })
246 |
247 | test('should not restore focus to toggling element if the associated show event gets prevented', function () {
248 | stop()
249 | var $toggleBtn = $(' ').appendTo('#qunit-fixture')
250 | var $otherBtn = $(' ').appendTo('#qunit-fixture')
251 |
252 | $('')
253 | .one('show.bs.modal', function (e) {
254 | e.preventDefault()
255 | $otherBtn.focus()
256 | setTimeout($.proxy(function () {
257 | $(this).bootstrapModal('show')
258 | }, this), 0)
259 | })
260 | .on('hidden.bs.modal', function () {
261 | setTimeout(function () {
262 | ok($(document.activeElement).is($otherBtn), 'focus returned to toggling element')
263 | start()
264 | }, 0)
265 | })
266 | .on('shown.bs.modal', function () {
267 | $('#close').click()
268 | })
269 | .appendTo('#qunit-fixture')
270 |
271 | $toggleBtn.click()
272 | })
273 | })
274 |
--------------------------------------------------------------------------------
/assets/bootstrap-3.3.2/js/tests/unit/dropdown.js:
--------------------------------------------------------------------------------
1 | $(function () {
2 | 'use strict';
3 |
4 | module('dropdowns plugin')
5 |
6 | test('should be defined on jquery object', function () {
7 | ok($(document.body).dropdown, 'dropdown method is defined')
8 | })
9 |
10 | module('dropdowns', {
11 | setup: function () {
12 | // Run all tests in noConflict mode -- it's the only way to ensure that the plugin works in noConflict mode
13 | $.fn.bootstrapDropdown = $.fn.dropdown.noConflict()
14 | },
15 | teardown: function () {
16 | $.fn.dropdown = $.fn.bootstrapDropdown
17 | delete $.fn.bootstrapDropdown
18 | }
19 | })
20 |
21 | test('should provide no conflict', function () {
22 | strictEqual($.fn.dropdown, undefined, 'dropdown was set back to undefined (org value)')
23 | })
24 |
25 | test('should return jquery collection containing the element', function () {
26 | var $el = $('
')
27 | var $dropdown = $el.bootstrapDropdown()
28 | ok($dropdown instanceof $, 'returns jquery collection')
29 | strictEqual($dropdown[0], $el[0], 'collection contains element')
30 | })
31 |
32 | test('should not open dropdown if target is disabled via attribute', function () {
33 | var dropdownHTML = '
'
34 | + ''
35 | + 'Dropdown '
36 | + ''
42 | + ' '
43 | + ' '
44 | var $dropdown = $(dropdownHTML).find('[data-toggle="dropdown"]').bootstrapDropdown().click()
45 |
46 | ok(!$dropdown.parent('.dropdown').hasClass('open'), '"open" class added on click')
47 | })
48 |
49 | test('should not open dropdown if target is disabled via class', function () {
50 | var dropdownHTML = '
'
51 | + ''
52 | + 'Dropdown '
53 | + ''
59 | + ' '
60 | + ' '
61 | var $dropdown = $(dropdownHTML).find('[data-toggle="dropdown"]').bootstrapDropdown().click()
62 |
63 | ok(!$dropdown.parent('.dropdown').hasClass('open'), '"open" class added on click')
64 | })
65 |
66 | test('should add class open to menu if clicked', function () {
67 | var dropdownHTML = '
'
68 | + ''
69 | + 'Dropdown '
70 | + ''
76 | + ' '
77 | + ' '
78 | var $dropdown = $(dropdownHTML).find('[data-toggle="dropdown"]').bootstrapDropdown().click()
79 |
80 | ok($dropdown.parent('.dropdown').hasClass('open'), '"open" class added on click')
81 | })
82 |
83 | test('should test if element has a # before assuming it\'s a selector', function () {
84 | var dropdownHTML = '
'
85 | + ''
86 | + 'Dropdown '
87 | + ''
93 | + ' '
94 | + ' '
95 | var $dropdown = $(dropdownHTML).find('[data-toggle="dropdown"]').bootstrapDropdown().click()
96 |
97 | ok($dropdown.parent('.dropdown').hasClass('open'), '"open" class added on click')
98 | })
99 |
100 |
101 | test('should remove "open" class if body is clicked', function () {
102 | var dropdownHTML = '
'
103 | + ''
104 | + 'Dropdown '
105 | + ''
111 | + ' '
112 | + ' '
113 | var $dropdown = $(dropdownHTML)
114 | .appendTo('#qunit-fixture')
115 | .find('[data-toggle="dropdown"]')
116 | .bootstrapDropdown()
117 | .click()
118 |
119 | ok($dropdown.parent('.dropdown').hasClass('open'), '"open" class added on click')
120 | $(document.body).click()
121 | ok(!$dropdown.parent('.dropdown').hasClass('open'), '"open" class removed')
122 | })
123 |
124 | test('should remove "open" class if body is clicked, with multiple dropdowns', function () {
125 | var dropdownHTML = '
'
126 | + 'Menu 1 '
127 | + ''
133 | + ' '
134 | + '
'
135 | + 'Actions '
136 | + ' '
137 | + ''
140 | + '
'
141 | var $dropdowns = $(dropdownHTML).appendTo('#qunit-fixture').find('[data-toggle="dropdown"]')
142 | var $first = $dropdowns.first()
143 | var $last = $dropdowns.last()
144 |
145 | strictEqual($dropdowns.length, 2, 'two dropdowns')
146 |
147 | $first.click()
148 | strictEqual($first.parents('.open').length, 1, '"open" class added on click')
149 | strictEqual($('#qunit-fixture .open').length, 1, 'only one dropdown is open')
150 | $(document.body).click()
151 | strictEqual($('#qunit-fixture .open').length, 0, '"open" class removed')
152 |
153 | $last.click()
154 | strictEqual($last.parent('.open').length, 1, '"open" class added on click')
155 | strictEqual($('#qunit-fixture .open').length, 1, 'only one dropdown is open')
156 | $(document.body).click()
157 | strictEqual($('#qunit-fixture .open').length, 0, '"open" class removed')
158 | })
159 |
160 | test('should fire show and hide event', function () {
161 | var dropdownHTML = '
'
162 | + ''
163 | + 'Dropdown '
164 | + ''
170 | + ' '
171 | + ' '
172 | var $dropdown = $(dropdownHTML)
173 | .appendTo('#qunit-fixture')
174 | .find('[data-toggle="dropdown"]')
175 | .bootstrapDropdown()
176 |
177 | stop()
178 |
179 | $dropdown
180 | .parent('.dropdown')
181 | .on('show.bs.dropdown', function () {
182 | ok(true, 'show was fired')
183 | })
184 | .on('hide.bs.dropdown', function () {
185 | ok(true, 'hide was fired')
186 | start()
187 | })
188 |
189 | $dropdown.click()
190 | $(document.body).click()
191 | })
192 |
193 |
194 | test('should fire shown and hidden event', function () {
195 | var dropdownHTML = '
'
196 | + ''
197 | + 'Dropdown '
198 | + ''
204 | + ' '
205 | + ' '
206 | var $dropdown = $(dropdownHTML)
207 | .appendTo('#qunit-fixture')
208 | .find('[data-toggle="dropdown"]')
209 | .bootstrapDropdown()
210 |
211 | stop()
212 |
213 | $dropdown
214 | .parent('.dropdown')
215 | .on('shown.bs.dropdown', function () {
216 | ok(true, 'shown was fired')
217 | })
218 | .on('hidden.bs.dropdown', function () {
219 | ok(true, 'hidden was fired')
220 | start()
221 | })
222 |
223 | $dropdown.click()
224 | $(document.body).click()
225 | })
226 |
227 | test('should ignore keyboard events within
s and