epuber 0.5.7 → 0.7.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +5 -2
- data/README.md +20 -26
- data/bin/epuber +2 -3
- data/epuber.gemspec +10 -12
- data/lib/epuber/book/contributor.rb +1 -1
- data/lib/epuber/book/file_request.rb +1 -1
- data/lib/epuber/book/target.rb +1 -2
- data/lib/epuber/book/toc_item.rb +1 -2
- data/lib/epuber/book.rb +1 -2
- data/lib/epuber/checker/text_checker.rb +1 -1
- data/lib/epuber/checker.rb +1 -2
- data/lib/epuber/checker_transformer_base.rb +1 -0
- data/lib/epuber/command/build.rb +1 -2
- data/lib/epuber/command/compile.rb +1 -1
- data/lib/epuber/command/init.rb +1 -2
- data/lib/epuber/command/server.rb +1 -2
- data/lib/epuber/command.rb +1 -1
- data/lib/epuber/compiler/compilation_context.rb +1 -1
- data/lib/epuber/compiler/file_database.rb +3 -5
- data/lib/epuber/compiler/file_finders/abstract.rb +1 -1
- data/lib/epuber/compiler/file_finders/imaginary.rb +1 -2
- data/lib/epuber/compiler/file_finders/normal.rb +1 -1
- data/lib/epuber/compiler/file_resolver.rb +1 -2
- data/lib/epuber/compiler/file_stat.rb +0 -1
- data/lib/epuber/compiler/file_types/abstract_file.rb +1 -2
- data/lib/epuber/compiler/file_types/bade_file.rb +1 -2
- data/lib/epuber/compiler/file_types/coffee_script_file.rb +1 -2
- data/lib/epuber/compiler/file_types/container_xml_file.rb +1 -2
- data/lib/epuber/compiler/file_types/generated_file.rb +1 -2
- data/lib/epuber/compiler/file_types/ibooks_display_options_file.rb +1 -7
- data/lib/epuber/compiler/file_types/image_file.rb +1 -2
- data/lib/epuber/compiler/file_types/mime_type_file.rb +1 -2
- data/lib/epuber/compiler/file_types/nav_file.rb +1 -2
- data/lib/epuber/compiler/file_types/opf_file.rb +1 -2
- data/lib/epuber/compiler/file_types/source_file.rb +1 -2
- data/lib/epuber/compiler/file_types/static_file.rb +1 -2
- data/lib/epuber/compiler/file_types/stylus_file.rb +1 -2
- data/lib/epuber/compiler/file_types/xhtml_file.rb +2 -4
- data/lib/epuber/compiler/generator.rb +1 -1
- data/lib/epuber/compiler/meta_inf_generator.rb +1 -1
- data/lib/epuber/compiler/nav_generator.rb +1 -1
- data/lib/epuber/compiler/opf_generator.rb +1 -1
- data/lib/epuber/compiler/problem.rb +1 -2
- data/lib/epuber/compiler/xhtml_processor.rb +6 -6
- data/lib/epuber/compiler.rb +7 -11
- data/lib/epuber/config.rb +3 -4
- data/lib/epuber/dsl/attribute.rb +1 -1
- data/lib/epuber/dsl/attribute_support.rb +2 -2
- data/lib/epuber/dsl/object.rb +1 -1
- data/lib/epuber/dsl/tree_object.rb +1 -1
- data/lib/epuber/helper.rb +1 -1
- data/lib/epuber/lockfile.rb +1 -1
- data/lib/epuber/plugin.rb +1 -1
- data/lib/epuber/ruby_extensions/match_data.rb +1 -0
- data/lib/epuber/ruby_extensions/thread.rb +1 -0
- data/lib/epuber/server/handlers.rb +1 -1
- data/lib/epuber/server.rb +3 -2
- data/lib/epuber/templates.rb +2 -1
- data/lib/epuber/third_party/bower/bower.json +3 -3
- data/lib/epuber/third_party/bower/bower_components/cookies-js/bower.json +1 -1
- data/lib/epuber/third_party/bower/bower_components/cookies-js/dist/cookies.js +2 -3
- data/lib/epuber/third_party/bower/bower_components/cookies-js/dist/cookies.min.js +6 -6
- data/lib/epuber/third_party/bower/bower_components/jquery/AUTHORS.txt +278 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/{MIT-LICENSE.txt → LICENSE.txt} +17 -2
- data/lib/epuber/third_party/bower/bower_components/jquery/README.md +65 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/bower.json +2 -16
- data/lib/epuber/third_party/bower/bower_components/jquery/dist/jquery.js +2566 -1962
- data/lib/epuber/third_party/bower/bower_components/jquery/dist/jquery.min.js +4 -5
- data/lib/epuber/third_party/bower/bower_components/jquery/dist/jquery.min.map +1 -1
- data/lib/epuber/third_party/bower/bower_components/jquery/external/sizzle/LICENSE.txt +36 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/{src → external}/sizzle/dist/sizzle.js +236 -160
- data/lib/epuber/third_party/bower/bower_components/jquery/external/sizzle/dist/sizzle.min.js +3 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/external/sizzle/dist/sizzle.min.map +1 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/src/ajax/jsonp.js +25 -14
- data/lib/epuber/third_party/bower/bower_components/jquery/src/ajax/load.js +20 -12
- data/lib/epuber/third_party/bower/bower_components/jquery/src/ajax/parseJSON.js +2 -2
- data/lib/epuber/third_party/bower/bower_components/jquery/src/ajax/parseXML.js +4 -5
- data/lib/epuber/third_party/bower/bower_components/jquery/src/ajax/script.js +16 -12
- data/lib/epuber/third_party/bower/bower_components/jquery/src/ajax/var/location.js +3 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/src/ajax/var/nonce.js +2 -2
- data/lib/epuber/third_party/bower/bower_components/jquery/src/ajax/var/rquery.js +3 -3
- data/lib/epuber/third_party/bower/bower_components/jquery/src/ajax/xhr.js +73 -42
- data/lib/epuber/third_party/bower/bower_components/jquery/src/ajax.js +116 -57
- data/lib/epuber/third_party/bower/bower_components/jquery/src/attributes/attr.js +49 -48
- data/lib/epuber/third_party/bower/bower_components/jquery/src/attributes/classes.js +86 -67
- data/lib/epuber/third_party/bower/bower_components/jquery/src/attributes/prop.js +63 -32
- data/lib/epuber/third_party/bower/bower_components/jquery/src/attributes/support.js +6 -5
- data/lib/epuber/third_party/bower/bower_components/jquery/src/attributes/val.js +40 -24
- data/lib/epuber/third_party/bower/bower_components/jquery/src/attributes.js +2 -2
- data/lib/epuber/third_party/bower/bower_components/jquery/src/callbacks.js +114 -87
- data/lib/epuber/third_party/bower/bower_components/jquery/src/core/access.js +11 -6
- data/lib/epuber/third_party/bower/bower_components/jquery/src/core/init.js +27 -16
- data/lib/epuber/third_party/bower/bower_components/jquery/src/core/parseHTML.js +10 -8
- data/lib/epuber/third_party/bower/bower_components/jquery/src/core/ready.js +20 -14
- data/lib/epuber/third_party/bower/bower_components/jquery/src/core/var/rsingleTag.js +4 -3
- data/lib/epuber/third_party/bower/bower_components/jquery/src/core.js +77 -85
- data/lib/epuber/third_party/bower/bower_components/jquery/src/css/addGetHookIf.js +5 -3
- data/lib/epuber/third_party/bower/bower_components/jquery/src/css/adjustCSS.js +65 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/src/css/curCSS.js +20 -17
- data/lib/epuber/third_party/bower/bower_components/jquery/src/css/defaultDisplay.js +16 -14
- data/lib/epuber/third_party/bower/bower_components/jquery/src/css/hiddenVisibleSelectors.js +9 -6
- data/lib/epuber/third_party/bower/bower_components/jquery/src/css/showHide.js +48 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/src/css/support.js +86 -61
- data/lib/epuber/third_party/bower/bower_components/jquery/src/css/var/cssExpand.js +2 -2
- data/lib/epuber/third_party/bower/bower_components/jquery/src/css/var/getStyles.js +8 -5
- data/lib/epuber/third_party/bower/bower_components/jquery/src/css/var/isHidden.js +6 -3
- data/lib/epuber/third_party/bower/bower_components/jquery/src/css/var/rmargin.js +3 -3
- data/lib/epuber/third_party/bower/bower_components/jquery/src/css/var/rnumnonpx.js +2 -2
- data/lib/epuber/third_party/bower/bower_components/jquery/src/css/{swap.js → var/swap.js} +3 -7
- data/lib/epuber/third_party/bower/bower_components/jquery/src/css.js +107 -55
- data/lib/epuber/third_party/bower/bower_components/jquery/src/data/Data.js +93 -74
- data/lib/epuber/third_party/bower/bower_components/jquery/src/data/{accepts.js → var/acceptData.js} +4 -6
- data/lib/epuber/third_party/bower/bower_components/jquery/src/data/var/{data_priv.js → dataPriv.js} +2 -2
- data/lib/epuber/third_party/bower/bower_components/jquery/src/data/var/{data_user.js → dataUser.js} +2 -2
- data/lib/epuber/third_party/bower/bower_components/jquery/src/data.js +49 -40
- data/lib/epuber/third_party/bower/bower_components/jquery/src/deferred.js +34 -25
- data/lib/epuber/third_party/bower/bower_components/jquery/src/deprecated.js +27 -8
- data/lib/epuber/third_party/bower/bower_components/jquery/src/dimensions.js +9 -5
- data/lib/epuber/third_party/bower/bower_components/jquery/src/effects/Tween.js +14 -7
- data/lib/epuber/third_party/bower/bower_components/jquery/src/effects/animatedSelector.js +4 -4
- data/lib/epuber/third_party/bower/bower_components/jquery/src/effects.js +96 -115
- data/lib/epuber/third_party/bower/bower_components/jquery/src/event/ajax.js +11 -4
- data/lib/epuber/third_party/bower/bower_components/jquery/src/event/alias.js +11 -23
- data/lib/epuber/third_party/bower/bower_components/jquery/src/event/focusin.js +53 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/src/event/support.js +3 -3
- data/lib/epuber/third_party/bower/bower_components/jquery/src/event/trigger.js +183 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/src/event.js +168 -325
- data/lib/epuber/third_party/bower/bower_components/jquery/src/exports/amd.js +3 -3
- data/lib/epuber/third_party/bower/bower_components/jquery/src/exports/global.js +2 -8
- data/lib/epuber/third_party/bower/bower_components/jquery/src/intro.js +1 -1
- data/lib/epuber/third_party/bower/bower_components/jquery/src/jquery.js +5 -5
- data/lib/epuber/third_party/bower/bower_components/jquery/src/manipulation/_evalUrl.js +6 -4
- data/lib/epuber/third_party/bower/bower_components/jquery/src/manipulation/buildFragment.js +102 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/src/manipulation/getAll.js +21 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/src/manipulation/setGlobalEval.js +20 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/src/manipulation/support.js +7 -6
- data/lib/epuber/third_party/bower/bower_components/jquery/src/manipulation/var/rcheckableType.js +3 -3
- data/lib/epuber/third_party/bower/bower_components/jquery/src/manipulation/var/rscriptType.js +3 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/src/manipulation/var/rtagName.js +3 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/src/manipulation/wrapMap.js +27 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/src/manipulation.js +206 -305
- data/lib/epuber/third_party/bower/bower_components/jquery/src/offset.js +40 -29
- data/lib/epuber/third_party/bower/bower_components/jquery/src/outro.js +1 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/src/queue/delay.js +6 -6
- data/lib/epuber/third_party/bower/bower_components/jquery/src/queue.js +23 -22
- data/lib/epuber/third_party/bower/bower_components/jquery/src/selector-native.js +107 -68
- data/lib/epuber/third_party/bower/bower_components/jquery/src/selector-sizzle.js +5 -5
- data/lib/epuber/third_party/bower/bower_components/jquery/src/selector.js +1 -1
- data/lib/epuber/third_party/bower/bower_components/jquery/src/serialize.js +28 -14
- data/lib/epuber/third_party/bower/bower_components/jquery/src/traversing/findFilter.js +13 -13
- data/lib/epuber/third_party/bower/bower_components/jquery/src/traversing/var/dir.js +20 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/src/traversing/var/rneedsContext.js +2 -2
- data/lib/epuber/third_party/bower/bower_components/jquery/src/traversing/var/siblings.js +15 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/src/traversing.js +32 -56
- data/lib/epuber/third_party/bower/bower_components/jquery/src/var/arr.js +2 -2
- data/lib/epuber/third_party/bower/bower_components/jquery/src/var/class2type.js +3 -2
- data/lib/epuber/third_party/bower/bower_components/jquery/src/var/concat.js +2 -2
- data/lib/epuber/third_party/bower/bower_components/jquery/src/var/document.js +3 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/src/var/documentElement.js +5 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/src/var/hasOwn.js +2 -2
- data/lib/epuber/third_party/bower/bower_components/jquery/src/var/indexOf.js +2 -2
- data/lib/epuber/third_party/bower/bower_components/jquery/src/var/pnum.js +3 -3
- data/lib/epuber/third_party/bower/bower_components/jquery/src/var/push.js +2 -2
- data/lib/epuber/third_party/bower/bower_components/jquery/src/var/rcssNum.js +7 -0
- data/lib/epuber/third_party/bower/bower_components/jquery/src/var/rnotwhite.js +3 -3
- data/lib/epuber/third_party/bower/bower_components/jquery/src/var/slice.js +2 -2
- data/lib/epuber/third_party/bower/bower_components/jquery/src/var/support.js +3 -2
- data/lib/epuber/third_party/bower/bower_components/jquery/src/var/toString.js +2 -2
- data/lib/epuber/third_party/bower/bower_components/jquery/src/wrap.js +19 -19
- data/lib/epuber/third_party/bower/bower_components/spin.js/{LICENSE.txt → LICENSE.md} +2 -1
- data/lib/epuber/third_party/bower/bower_components/spin.js/README.md +21 -21
- data/lib/epuber/third_party/bower/bower_components/spin.js/bower.json +0 -1
- data/lib/epuber/third_party/bower/bower_components/spin.js/jquery.spin.js +23 -24
- data/lib/epuber/third_party/bower/bower_components/spin.js/spin.js +153 -113
- data/lib/epuber/third_party/bower/bower_components/spin.js/spin.min.js +2 -0
- data/lib/epuber/third_party/bower/bower_components/uri.js/CHANGELOG.md +424 -0
- data/lib/epuber/third_party/bower/bower_components/uri.js/README.md +23 -308
- data/lib/epuber/third_party/bower/bower_components/uri.js/SECURITY.md +12 -0
- data/lib/epuber/third_party/bower/bower_components/uri.js/bower.json +2 -2
- data/lib/epuber/third_party/bower/bower_components/uri.js/contributing.md +0 -4
- data/lib/epuber/third_party/bower/bower_components/uri.js/src/IPv6.js +3 -6
- data/lib/epuber/third_party/bower/bower_components/uri.js/src/SecondLevelDomains.js +8 -4
- data/lib/epuber/third_party/bower/bower_components/uri.js/src/URI.fragmentQuery.js +21 -4
- data/lib/epuber/third_party/bower/bower_components/uri.js/src/URI.fragmentURI.js +1 -1
- data/lib/epuber/third_party/bower/bower_components/uri.js/src/URI.js +312 -69
- data/lib/epuber/third_party/bower/bower_components/uri.js/src/URI.min.js +85 -77
- data/lib/epuber/third_party/bower/bower_components/uri.js/src/URITemplate.js +28 -11
- data/lib/epuber/third_party/bower/bower_components/uri.js/src/jquery.URI.js +17 -18
- data/lib/epuber/third_party/bower/bower_components/uri.js/src/jquery.URI.min.js +6 -6
- data/lib/epuber/third_party/bower/bower_components/uri.js/src/punycode.js +63 -38
- data/lib/epuber/third_party/bower.rb +2 -0
- data/lib/epuber/transformer/text_transformer.rb +1 -2
- data/lib/epuber/transformer.rb +1 -2
- data/lib/epuber/user_interface.rb +1 -1
- data/lib/epuber/vendor/hash_binding.rb +1 -1
- data/lib/epuber/vendor/nokogiri_extensions.rb +24 -21
- data/lib/epuber/vendor/ruby_templater.rb +1 -2
- data/lib/epuber/vendor/size.rb +1 -0
- data/lib/epuber/vendor/version.rb +1 -1
- data/lib/epuber/version.rb +2 -1
- data/lib/epuber.rb +1 -1
- metadata +77 -46
- data/lib/epuber/ruby_extensions/string.rb +0 -16
- data/lib/epuber/third_party/bower/bower_components/jquery/src/sizzle/dist/sizzle.min.js +0 -3
- data/lib/epuber/third_party/bower/bower_components/jquery/src/sizzle/dist/sizzle.min.map +0 -1
- data/lib/epuber/third_party/bower/bower_components/jquery/src/var/strundefined.js +0 -3
- data/lib/epuber/vendor/globals_context.rb +0 -26
@@ -1,7 +1,8 @@
|
|
1
|
-
define([
|
1
|
+
define( [
|
2
2
|
"./core",
|
3
|
-
"./var/strundefined",
|
4
3
|
"./core/access",
|
4
|
+
"./var/document",
|
5
|
+
"./var/documentElement",
|
5
6
|
"./css/var/rnumnonpx",
|
6
7
|
"./css/curCSS",
|
7
8
|
"./css/addGetHookIf",
|
@@ -10,9 +11,7 @@ define([
|
|
10
11
|
"./core/init",
|
11
12
|
"./css",
|
12
13
|
"./selector" // contains
|
13
|
-
], function( jQuery,
|
14
|
-
|
15
|
-
var docElem = window.document.documentElement;
|
14
|
+
], function( jQuery, access, document, documentElement, rnumnonpx, curCSS, addGetHookIf, support ) {
|
16
15
|
|
17
16
|
/**
|
18
17
|
* Gets a window from an element
|
@@ -37,7 +36,7 @@ jQuery.offset = {
|
|
37
36
|
curCSSTop = jQuery.css( elem, "top" );
|
38
37
|
curCSSLeft = jQuery.css( elem, "left" );
|
39
38
|
calculatePosition = ( position === "absolute" || position === "fixed" ) &&
|
40
|
-
( curCSSTop + curCSSLeft ).indexOf("auto") > -1;
|
39
|
+
( curCSSTop + curCSSLeft ).indexOf( "auto" ) > -1;
|
41
40
|
|
42
41
|
// Need to be able to calculate position if either
|
43
42
|
// top or left is auto and position is either absolute or fixed
|
@@ -52,7 +51,9 @@ jQuery.offset = {
|
|
52
51
|
}
|
53
52
|
|
54
53
|
if ( jQuery.isFunction( options ) ) {
|
55
|
-
|
54
|
+
|
55
|
+
// Use jQuery.extend here to allow modification of coordinates argument (gh-1848)
|
56
|
+
options = options.call( elem, i, jQuery.extend( {}, curOffset ) );
|
56
57
|
}
|
57
58
|
|
58
59
|
if ( options.top != null ) {
|
@@ -71,14 +72,14 @@ jQuery.offset = {
|
|
71
72
|
}
|
72
73
|
};
|
73
74
|
|
74
|
-
jQuery.fn.extend({
|
75
|
+
jQuery.fn.extend( {
|
75
76
|
offset: function( options ) {
|
76
77
|
if ( arguments.length ) {
|
77
78
|
return options === undefined ?
|
78
79
|
this :
|
79
|
-
this.each(function( i ) {
|
80
|
+
this.each( function( i ) {
|
80
81
|
jQuery.offset.setOffset( this, options, i );
|
81
|
-
});
|
82
|
+
} );
|
82
83
|
}
|
83
84
|
|
84
85
|
var docElem, win,
|
@@ -97,11 +98,7 @@ jQuery.fn.extend({
|
|
97
98
|
return box;
|
98
99
|
}
|
99
100
|
|
100
|
-
|
101
|
-
// If we don't have gBCR, just use 0,0 rather than error
|
102
|
-
if ( typeof elem.getBoundingClientRect !== strundefined ) {
|
103
|
-
box = elem.getBoundingClientRect();
|
104
|
-
}
|
101
|
+
box = elem.getBoundingClientRect();
|
105
102
|
win = getWindow( doc );
|
106
103
|
return {
|
107
104
|
top: box.top + win.pageYOffset - docElem.clientTop,
|
@@ -118,12 +115,15 @@ jQuery.fn.extend({
|
|
118
115
|
elem = this[ 0 ],
|
119
116
|
parentOffset = { top: 0, left: 0 };
|
120
117
|
|
121
|
-
// Fixed elements are offset from window (parentOffset = {top:0, left: 0},
|
118
|
+
// Fixed elements are offset from window (parentOffset = {top:0, left: 0},
|
119
|
+
// because it is its only offset parent
|
122
120
|
if ( jQuery.css( elem, "position" ) === "fixed" ) {
|
121
|
+
|
123
122
|
// Assume getBoundingClientRect is there when computed position is fixed
|
124
123
|
offset = elem.getBoundingClientRect();
|
125
124
|
|
126
125
|
} else {
|
126
|
+
|
127
127
|
// Get *real* offsetParent
|
128
128
|
offsetParent = this.offsetParent();
|
129
129
|
|
@@ -145,18 +145,28 @@ jQuery.fn.extend({
|
|
145
145
|
};
|
146
146
|
},
|
147
147
|
|
148
|
+
// This method will return documentElement in the following cases:
|
149
|
+
// 1) For the element inside the iframe without offsetParent, this method will return
|
150
|
+
// documentElement of the parent window
|
151
|
+
// 2) For the hidden or detached element
|
152
|
+
// 3) For body or html element, i.e. in case of the html node - it will return itself
|
153
|
+
//
|
154
|
+
// but those exceptions were never presented as a real life use-cases
|
155
|
+
// and might be considered as more preferable results.
|
156
|
+
//
|
157
|
+
// This logic, however, is not guaranteed and can change at any point in the future
|
148
158
|
offsetParent: function() {
|
149
|
-
return this.map(function() {
|
150
|
-
var offsetParent = this.offsetParent
|
159
|
+
return this.map( function() {
|
160
|
+
var offsetParent = this.offsetParent;
|
151
161
|
|
152
|
-
while ( offsetParent &&
|
162
|
+
while ( offsetParent && jQuery.css( offsetParent, "position" ) === "static" ) {
|
153
163
|
offsetParent = offsetParent.offsetParent;
|
154
164
|
}
|
155
165
|
|
156
|
-
return offsetParent ||
|
157
|
-
});
|
166
|
+
return offsetParent || documentElement;
|
167
|
+
} );
|
158
168
|
}
|
159
|
-
});
|
169
|
+
} );
|
160
170
|
|
161
171
|
// Create scrollLeft and scrollTop methods
|
162
172
|
jQuery.each( { scrollLeft: "pageXOffset", scrollTop: "pageYOffset" }, function( method, prop ) {
|
@@ -172,18 +182,18 @@ jQuery.each( { scrollLeft: "pageXOffset", scrollTop: "pageYOffset" }, function(
|
|
172
182
|
|
173
183
|
if ( win ) {
|
174
184
|
win.scrollTo(
|
175
|
-
!top ? val :
|
176
|
-
top ? val :
|
185
|
+
!top ? val : win.pageXOffset,
|
186
|
+
top ? val : win.pageYOffset
|
177
187
|
);
|
178
188
|
|
179
189
|
} else {
|
180
190
|
elem[ method ] = val;
|
181
191
|
}
|
182
|
-
}, method, val, arguments.length
|
192
|
+
}, method, val, arguments.length );
|
183
193
|
};
|
184
|
-
});
|
194
|
+
} );
|
185
195
|
|
186
|
-
// Support: Safari<7+, Chrome<37+
|
196
|
+
// Support: Safari<7-8+, Chrome<37-44+
|
187
197
|
// Add the top/left cssHooks using jQuery.fn.position
|
188
198
|
// Webkit bug: https://bugs.webkit.org/show_bug.cgi?id=29084
|
189
199
|
// Blink bug: https://code.google.com/p/chromium/issues/detail?id=229280
|
@@ -194,6 +204,7 @@ jQuery.each( [ "top", "left" ], function( i, prop ) {
|
|
194
204
|
function( elem, computed ) {
|
195
205
|
if ( computed ) {
|
196
206
|
computed = curCSS( elem, prop );
|
207
|
+
|
197
208
|
// If curCSS returns percentage, fallback to offset
|
198
209
|
return rnumnonpx.test( computed ) ?
|
199
210
|
jQuery( elem ).position()[ prop ] + "px" :
|
@@ -201,7 +212,7 @@ jQuery.each( [ "top", "left" ], function( i, prop ) {
|
|
201
212
|
}
|
202
213
|
}
|
203
214
|
);
|
204
|
-
});
|
215
|
+
} );
|
205
216
|
|
206
217
|
return jQuery;
|
207
|
-
});
|
218
|
+
} );
|
@@ -1,22 +1,22 @@
|
|
1
|
-
define([
|
1
|
+
define( [
|
2
2
|
"../core",
|
3
3
|
"../queue",
|
4
4
|
"../effects" // Delay is optional because of this dependency
|
5
5
|
], function( jQuery ) {
|
6
6
|
|
7
7
|
// Based off of the plugin by Clint Helfers, with permission.
|
8
|
-
// http://blindsignals.com/index.php/2009/07/jquery-delay/
|
8
|
+
// http://web.archive.org/web/20100324014747/http://blindsignals.com/index.php/2009/07/jquery-delay/
|
9
9
|
jQuery.fn.delay = function( time, type ) {
|
10
10
|
time = jQuery.fx ? jQuery.fx.speeds[ time ] || time : time;
|
11
11
|
type = type || "fx";
|
12
12
|
|
13
13
|
return this.queue( type, function( next, hooks ) {
|
14
|
-
var timeout = setTimeout( next, time );
|
14
|
+
var timeout = window.setTimeout( next, time );
|
15
15
|
hooks.stop = function() {
|
16
|
-
clearTimeout( timeout );
|
16
|
+
window.clearTimeout( timeout );
|
17
17
|
};
|
18
|
-
});
|
18
|
+
} );
|
19
19
|
};
|
20
20
|
|
21
21
|
return jQuery.fn.delay;
|
22
|
-
});
|
22
|
+
} );
|
@@ -1,22 +1,22 @@
|
|
1
|
-
define([
|
1
|
+
define( [
|
2
2
|
"./core",
|
3
|
-
"./data/var/
|
3
|
+
"./data/var/dataPriv",
|
4
4
|
"./deferred",
|
5
5
|
"./callbacks"
|
6
|
-
], function( jQuery,
|
6
|
+
], function( jQuery, dataPriv ) {
|
7
7
|
|
8
|
-
jQuery.extend({
|
8
|
+
jQuery.extend( {
|
9
9
|
queue: function( elem, type, data ) {
|
10
10
|
var queue;
|
11
11
|
|
12
12
|
if ( elem ) {
|
13
13
|
type = ( type || "fx" ) + "queue";
|
14
|
-
queue =
|
14
|
+
queue = dataPriv.get( elem, type );
|
15
15
|
|
16
16
|
// Speed up dequeue by getting out quickly if this is just a lookup
|
17
17
|
if ( data ) {
|
18
18
|
if ( !queue || jQuery.isArray( data ) ) {
|
19
|
-
queue =
|
19
|
+
queue = dataPriv.access( elem, type, jQuery.makeArray( data ) );
|
20
20
|
} else {
|
21
21
|
queue.push( data );
|
22
22
|
}
|
@@ -63,15 +63,15 @@ jQuery.extend({
|
|
63
63
|
// Not public - generate a queueHooks object, or return the current one
|
64
64
|
_queueHooks: function( elem, type ) {
|
65
65
|
var key = type + "queueHooks";
|
66
|
-
return
|
67
|
-
empty: jQuery.Callbacks("once memory").add(function() {
|
68
|
-
|
69
|
-
})
|
70
|
-
});
|
66
|
+
return dataPriv.get( elem, key ) || dataPriv.access( elem, key, {
|
67
|
+
empty: jQuery.Callbacks( "once memory" ).add( function() {
|
68
|
+
dataPriv.remove( elem, [ type + "queue", key ] );
|
69
|
+
} )
|
70
|
+
} );
|
71
71
|
}
|
72
|
-
});
|
72
|
+
} );
|
73
73
|
|
74
|
-
jQuery.fn.extend({
|
74
|
+
jQuery.fn.extend( {
|
75
75
|
queue: function( type, data ) {
|
76
76
|
var setter = 2;
|
77
77
|
|
@@ -82,30 +82,31 @@ jQuery.fn.extend({
|
|
82
82
|
}
|
83
83
|
|
84
84
|
if ( arguments.length < setter ) {
|
85
|
-
return jQuery.queue( this[0], type );
|
85
|
+
return jQuery.queue( this[ 0 ], type );
|
86
86
|
}
|
87
87
|
|
88
88
|
return data === undefined ?
|
89
89
|
this :
|
90
|
-
this.each(function() {
|
90
|
+
this.each( function() {
|
91
91
|
var queue = jQuery.queue( this, type, data );
|
92
92
|
|
93
93
|
// Ensure a hooks for this queue
|
94
94
|
jQuery._queueHooks( this, type );
|
95
95
|
|
96
|
-
if ( type === "fx" && queue[0] !== "inprogress" ) {
|
96
|
+
if ( type === "fx" && queue[ 0 ] !== "inprogress" ) {
|
97
97
|
jQuery.dequeue( this, type );
|
98
98
|
}
|
99
|
-
});
|
99
|
+
} );
|
100
100
|
},
|
101
101
|
dequeue: function( type ) {
|
102
|
-
return this.each(function() {
|
102
|
+
return this.each( function() {
|
103
103
|
jQuery.dequeue( this, type );
|
104
|
-
});
|
104
|
+
} );
|
105
105
|
},
|
106
106
|
clearQueue: function( type ) {
|
107
107
|
return this.queue( type || "fx", [] );
|
108
108
|
},
|
109
|
+
|
109
110
|
// Get a promise resolved when queues of a certain type
|
110
111
|
// are emptied (fx is the type by default)
|
111
112
|
promise: function( type, obj ) {
|
@@ -127,7 +128,7 @@ jQuery.fn.extend({
|
|
127
128
|
type = type || "fx";
|
128
129
|
|
129
130
|
while ( i-- ) {
|
130
|
-
tmp =
|
131
|
+
tmp = dataPriv.get( elements[ i ], type + "queueHooks" );
|
131
132
|
if ( tmp && tmp.empty ) {
|
132
133
|
count++;
|
133
134
|
tmp.empty.add( resolve );
|
@@ -136,7 +137,7 @@ jQuery.fn.extend({
|
|
136
137
|
resolve();
|
137
138
|
return defer.promise( obj );
|
138
139
|
}
|
139
|
-
});
|
140
|
+
} );
|
140
141
|
|
141
142
|
return jQuery;
|
142
|
-
});
|
143
|
+
} );
|
@@ -1,6 +1,10 @@
|
|
1
|
-
define([
|
2
|
-
"./core"
|
3
|
-
|
1
|
+
define( [
|
2
|
+
"./core",
|
3
|
+
"./var/document",
|
4
|
+
"./var/documentElement",
|
5
|
+
"./var/hasOwn",
|
6
|
+
"./var/indexOf"
|
7
|
+
], function( jQuery, document, documentElement, hasOwn, indexOf ) {
|
4
8
|
|
5
9
|
/*
|
6
10
|
* Optional (non-Sizzle) selector module for custom builds.
|
@@ -27,46 +31,86 @@ define([
|
|
27
31
|
* customize this stub for the project's specific needs.
|
28
32
|
*/
|
29
33
|
|
30
|
-
var
|
31
|
-
|
32
|
-
matches =
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
34
|
+
var hasDuplicate, sortInput,
|
35
|
+
sortStable = jQuery.expando.split( "" ).sort( sortOrder ).join( "" ) === jQuery.expando,
|
36
|
+
matches = documentElement.matches ||
|
37
|
+
documentElement.webkitMatchesSelector ||
|
38
|
+
documentElement.mozMatchesSelector ||
|
39
|
+
documentElement.oMatchesSelector ||
|
40
|
+
documentElement.msMatchesSelector;
|
41
|
+
|
42
|
+
function sortOrder( a, b ) {
|
43
|
+
|
44
|
+
// Flag for duplicate removal
|
45
|
+
if ( a === b ) {
|
46
|
+
hasDuplicate = true;
|
47
|
+
return 0;
|
48
|
+
}
|
49
|
+
|
50
|
+
// Sort on method existence if only one input has compareDocumentPosition
|
51
|
+
var compare = !a.compareDocumentPosition - !b.compareDocumentPosition;
|
52
|
+
if ( compare ) {
|
53
|
+
return compare;
|
54
|
+
}
|
55
|
+
|
56
|
+
// Calculate position if both inputs belong to the same document
|
57
|
+
compare = ( a.ownerDocument || a ) === ( b.ownerDocument || b ) ?
|
58
|
+
a.compareDocumentPosition( b ) :
|
59
|
+
|
60
|
+
// Otherwise we know they are disconnected
|
61
|
+
1;
|
62
|
+
|
63
|
+
// Disconnected nodes
|
64
|
+
if ( compare & 1 ) {
|
65
|
+
|
66
|
+
// Choose the first element that is related to our preferred document
|
67
|
+
if ( a === document || a.ownerDocument === document &&
|
68
|
+
jQuery.contains( document, a ) ) {
|
69
|
+
return -1;
|
70
|
+
}
|
71
|
+
if ( b === document || b.ownerDocument === document &&
|
72
|
+
jQuery.contains( document, b ) ) {
|
73
|
+
return 1;
|
42
74
|
}
|
43
75
|
|
44
|
-
|
76
|
+
// Maintain original order
|
77
|
+
return sortInput ?
|
78
|
+
( indexOf.call( sortInput, a ) - indexOf.call( sortInput, b ) ) :
|
79
|
+
0;
|
80
|
+
}
|
45
81
|
|
46
|
-
|
47
|
-
|
48
|
-
if ( compare & 1 ) {
|
82
|
+
return compare & 4 ? -1 : 1;
|
83
|
+
}
|
49
84
|
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
return 1;
|
56
|
-
}
|
85
|
+
function uniqueSort( results ) {
|
86
|
+
var elem,
|
87
|
+
duplicates = [],
|
88
|
+
j = 0,
|
89
|
+
i = 0;
|
57
90
|
|
58
|
-
|
59
|
-
|
60
|
-
|
91
|
+
hasDuplicate = false;
|
92
|
+
sortInput = !sortStable && results.slice( 0 );
|
93
|
+
results.sort( sortOrder );
|
61
94
|
|
62
|
-
|
95
|
+
if ( hasDuplicate ) {
|
96
|
+
while ( ( elem = results[ i++ ] ) ) {
|
97
|
+
if ( elem === results[ i ] ) {
|
98
|
+
j = duplicates.push( i );
|
99
|
+
}
|
63
100
|
}
|
101
|
+
while ( j-- ) {
|
102
|
+
results.splice( duplicates[ j ], 1 );
|
103
|
+
}
|
104
|
+
}
|
64
105
|
|
65
|
-
|
66
|
-
|
67
|
-
|
106
|
+
// Clear input after sorting to release objects
|
107
|
+
// See https://github.com/jquery/sizzle/pull/225
|
108
|
+
sortInput = null;
|
68
109
|
|
69
|
-
|
110
|
+
return results;
|
111
|
+
}
|
112
|
+
|
113
|
+
jQuery.extend( {
|
70
114
|
find: function( selector, context, results, seed ) {
|
71
115
|
var elem, nodeType,
|
72
116
|
i = 0;
|
@@ -80,44 +124,24 @@ jQuery.extend({
|
|
80
124
|
}
|
81
125
|
|
82
126
|
// Early return if context is not an element or document
|
83
|
-
if ( (nodeType = context.nodeType) !== 1 && nodeType !== 9 ) {
|
127
|
+
if ( ( nodeType = context.nodeType ) !== 1 && nodeType !== 9 ) {
|
84
128
|
return [];
|
85
129
|
}
|
86
130
|
|
87
131
|
if ( seed ) {
|
88
|
-
while ( (elem = seed[i++]) ) {
|
89
|
-
if ( jQuery.find.matchesSelector(elem, selector) ) {
|
132
|
+
while ( ( elem = seed[ i++ ] ) ) {
|
133
|
+
if ( jQuery.find.matchesSelector( elem, selector ) ) {
|
90
134
|
results.push( elem );
|
91
135
|
}
|
92
136
|
}
|
93
137
|
} else {
|
94
|
-
jQuery.merge( results, context.querySelectorAll(selector) );
|
95
|
-
}
|
96
|
-
|
97
|
-
return results;
|
98
|
-
},
|
99
|
-
unique: function( results ) {
|
100
|
-
var elem,
|
101
|
-
duplicates = [],
|
102
|
-
i = 0,
|
103
|
-
j = 0;
|
104
|
-
|
105
|
-
selector_hasDuplicate = false;
|
106
|
-
results.sort( selector_sortOrder );
|
107
|
-
|
108
|
-
if ( selector_hasDuplicate ) {
|
109
|
-
while ( (elem = results[i++]) ) {
|
110
|
-
if ( elem === results[ i ] ) {
|
111
|
-
j = duplicates.push( i );
|
112
|
-
}
|
113
|
-
}
|
114
|
-
while ( j-- ) {
|
115
|
-
results.splice( duplicates[ j ], 1 );
|
116
|
-
}
|
138
|
+
jQuery.merge( results, context.querySelectorAll( selector ) );
|
117
139
|
}
|
118
140
|
|
119
141
|
return results;
|
120
142
|
},
|
143
|
+
uniqueSort: uniqueSort,
|
144
|
+
unique: uniqueSort,
|
121
145
|
text: function( elem ) {
|
122
146
|
var node,
|
123
147
|
ret = "",
|
@@ -125,17 +149,21 @@ jQuery.extend({
|
|
125
149
|
nodeType = elem.nodeType;
|
126
150
|
|
127
151
|
if ( !nodeType ) {
|
152
|
+
|
128
153
|
// If no nodeType, this is expected to be an array
|
129
|
-
while ( (node = elem[i++]) ) {
|
154
|
+
while ( ( node = elem[ i++ ] ) ) {
|
155
|
+
|
130
156
|
// Do not traverse comment nodes
|
131
157
|
ret += jQuery.text( node );
|
132
158
|
}
|
133
159
|
} else if ( nodeType === 1 || nodeType === 9 || nodeType === 11 ) {
|
160
|
+
|
134
161
|
// Use textContent for elements
|
135
162
|
return elem.textContent;
|
136
163
|
} else if ( nodeType === 3 || nodeType === 4 ) {
|
137
164
|
return elem.nodeValue;
|
138
165
|
}
|
166
|
+
|
139
167
|
// Do not include comment or processing instruction nodes
|
140
168
|
|
141
169
|
return ret;
|
@@ -143,19 +171,24 @@ jQuery.extend({
|
|
143
171
|
contains: function( a, b ) {
|
144
172
|
var adown = a.nodeType === 9 ? a.documentElement : a,
|
145
173
|
bup = b && b.parentNode;
|
146
|
-
return a === bup || !!( bup && bup.nodeType === 1 && adown.contains(bup) );
|
174
|
+
return a === bup || !!( bup && bup.nodeType === 1 && adown.contains( bup ) );
|
147
175
|
},
|
148
176
|
isXMLDoc: function( elem ) {
|
149
|
-
|
177
|
+
|
178
|
+
// documentElement is verified for cases where it doesn't yet exist
|
179
|
+
// (such as loading iframes in IE - #4833)
|
180
|
+
var documentElement = elem && ( elem.ownerDocument || elem ).documentElement;
|
181
|
+
return documentElement ? documentElement.nodeName !== "HTML" : false;
|
150
182
|
},
|
151
183
|
expr: {
|
152
184
|
attrHandle: {},
|
153
185
|
match: {
|
154
|
-
bool:
|
186
|
+
bool: new RegExp( "^(?:checked|selected|async|autofocus|autoplay|controls|defer" +
|
187
|
+
"|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped)$", "i" ),
|
155
188
|
needsContext: /^[\x20\t\r\n\f]*[>+~]/
|
156
189
|
}
|
157
190
|
}
|
158
|
-
});
|
191
|
+
} );
|
159
192
|
|
160
193
|
jQuery.extend( jQuery.find, {
|
161
194
|
matches: function( expr, elements ) {
|
@@ -165,8 +198,14 @@ jQuery.extend( jQuery.find, {
|
|
165
198
|
return matches.call( elem, expr );
|
166
199
|
},
|
167
200
|
attr: function( elem, name ) {
|
168
|
-
|
201
|
+
var fn = jQuery.expr.attrHandle[ name.toLowerCase() ],
|
202
|
+
|
203
|
+
// Don't get fooled by Object.prototype properties (jQuery #13807)
|
204
|
+
value = fn && hasOwn.call( jQuery.expr.attrHandle, name.toLowerCase() ) ?
|
205
|
+
fn( elem, name, jQuery.isXMLDoc( elem ) ) :
|
206
|
+
undefined;
|
207
|
+
return value !== undefined ? value : elem.getAttribute( name );
|
169
208
|
}
|
170
|
-
});
|
209
|
+
} );
|
171
210
|
|
172
|
-
});
|
211
|
+
} );
|
@@ -1,14 +1,14 @@
|
|
1
|
-
define([
|
1
|
+
define( [
|
2
2
|
"./core",
|
3
|
-
"sizzle"
|
3
|
+
"../external/sizzle/dist/sizzle"
|
4
4
|
], function( jQuery, Sizzle ) {
|
5
5
|
|
6
6
|
jQuery.find = Sizzle;
|
7
7
|
jQuery.expr = Sizzle.selectors;
|
8
|
-
jQuery.expr[":"] = jQuery.expr.pseudos;
|
9
|
-
jQuery.unique = Sizzle.uniqueSort;
|
8
|
+
jQuery.expr[ ":" ] = jQuery.expr.pseudos;
|
9
|
+
jQuery.uniqueSort = jQuery.unique = Sizzle.uniqueSort;
|
10
10
|
jQuery.text = Sizzle.getText;
|
11
11
|
jQuery.isXMLDoc = Sizzle.isXML;
|
12
12
|
jQuery.contains = Sizzle.contains;
|
13
13
|
|
14
|
-
});
|
14
|
+
} );
|
@@ -1 +1 @@
|
|
1
|
-
define([ "./selector-sizzle" ]);
|
1
|
+
define( [ "./selector-sizzle" ], function() {} );
|