picky-generators 1.3.4 → 1.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,215 +0,0 @@
1
- /**
2
- * jQuery.ScrollTo
3
- * Copyright (c) 2007-2009 Ariel Flesler - aflesler(at)gmail(dot)com | http://flesler.blogspot.com
4
- * Dual licensed under MIT and GPL.
5
- * Date: 5/25/2009
6
- *
7
- * @projectDescription Easy element scrolling using jQuery.
8
- * http://flesler.blogspot.com/2007/10/jqueryscrollto.html
9
- * Works with jQuery +1.2.6. Tested on FF 2/3, IE 6/7/8, Opera 9.5/6, Safari 3, Chrome 1 on WinXP.
10
- *
11
- * @author Ariel Flesler
12
- * @version 1.4.2
13
- *
14
- * @id jQuery.scrollTo
15
- * @id jQuery.fn.scrollTo
16
- * @param {String, Number, DOMElement, jQuery, Object} target Where to scroll the matched elements.
17
- * The different options for target are:
18
- * - A number position (will be applied to all axes).
19
- * - A string position ('44', '100px', '+=90', etc ) will be applied to all axes
20
- * - A jQuery/DOM element ( logically, child of the element to scroll )
21
- * - A string selector, that will be relative to the element to scroll ( 'li:eq(2)', etc )
22
- * - A hash { top:x, left:y }, x and y can be any kind of number/string like above.
23
- * - A percentage of the container's dimension/s, for example: 50% to go to the middle.
24
- * - The string 'max' for go-to-end.
25
- * @param {Number} duration The OVERALL length of the animation, this argument can be the settings object instead.
26
- * @param {Object,Function} settings Optional set of settings or the onAfter callback.
27
- * @option {String} axis Which axis must be scrolled, use 'x', 'y', 'xy' or 'yx'.
28
- * @option {Number} duration The OVERALL length of the animation.
29
- * @option {String} easing The easing method for the animation.
30
- * @option {Boolean} margin If true, the margin of the target element will be deducted from the final position.
31
- * @option {Object, Number} offset Add/deduct from the end position. One number for both axes or { top:x, left:y }.
32
- * @option {Object, Number} over Add/deduct the height/width multiplied by 'over', can be { top:x, left:y } when using both axes.
33
- * @option {Boolean} queue If true, and both axis are given, the 2nd axis will only be animated after the first one ends.
34
- * @option {Function} onAfter Function to be called after the scrolling ends.
35
- * @option {Function} onAfterFirst If queuing is activated, this function will be called after the first scrolling ends.
36
- * @return {jQuery} Returns the same jQuery object, for chaining.
37
- *
38
- * @desc Scroll to a fixed position
39
- * @example $('div').scrollTo( 340 );
40
- *
41
- * @desc Scroll relatively to the actual position
42
- * @example $('div').scrollTo( '+=340px', { axis:'y' } );
43
- *
44
- * @dec Scroll using a selector (relative to the scrolled element)
45
- * @example $('div').scrollTo( 'p.paragraph:eq(2)', 500, { easing:'swing', queue:true, axis:'xy' } );
46
- *
47
- * @ Scroll to a DOM element (same for jQuery object)
48
- * @example var second_child = document.getElementById('container').firstChild.nextSibling;
49
- * $('#container').scrollTo( second_child, { duration:500, axis:'x', onAfter:function(){
50
- * alert('scrolled!!');
51
- * }});
52
- *
53
- * @desc Scroll on both axes, to different values
54
- * @example $('div').scrollTo( { top: 300, left:'+=200' }, { axis:'xy', offset:-20 } );
55
- */
56
- ;(function( $ ){
57
-
58
- var $scrollTo = $.scrollTo = function( target, duration, settings ){
59
- $(window).scrollTo( target, duration, settings );
60
- };
61
-
62
- $scrollTo.defaults = {
63
- axis:'xy',
64
- duration: parseFloat($.fn.jquery) >= 1.3 ? 0 : 1
65
- };
66
-
67
- // Returns the element that needs to be animated to scroll the window.
68
- // Kept for backwards compatibility (specially for localScroll & serialScroll)
69
- $scrollTo.window = function( scope ){
70
- return $(window)._scrollable();
71
- };
72
-
73
- // Hack, hack, hack :)
74
- // Returns the real elements to scroll (supports window/iframes, documents and regular nodes)
75
- $.fn._scrollable = function(){
76
- return this.map(function(){
77
- var elem = this,
78
- isWin = !elem.nodeName || $.inArray( elem.nodeName.toLowerCase(), ['iframe','#document','html','body'] ) != -1;
79
-
80
- if( !isWin )
81
- return elem;
82
-
83
- var doc = (elem.contentWindow || elem).document || elem.ownerDocument || elem;
84
-
85
- return $.browser.safari || doc.compatMode == 'BackCompat' ?
86
- doc.body :
87
- doc.documentElement;
88
- });
89
- };
90
-
91
- $.fn.scrollTo = function( target, duration, settings ){
92
- if( typeof duration == 'object' ){
93
- settings = duration;
94
- duration = 0;
95
- }
96
- if( typeof settings == 'function' )
97
- settings = { onAfter:settings };
98
-
99
- if( target == 'max' )
100
- target = 9e9;
101
-
102
- settings = $.extend( {}, $scrollTo.defaults, settings );
103
- // Speed is still recognized for backwards compatibility
104
- duration = duration || settings.speed || settings.duration;
105
- // Make sure the settings are given right
106
- settings.queue = settings.queue && settings.axis.length > 1;
107
-
108
- if( settings.queue )
109
- // Let's keep the overall duration
110
- duration /= 2;
111
- settings.offset = both( settings.offset );
112
- settings.over = both( settings.over );
113
-
114
- return this._scrollable().each(function(){
115
- var elem = this,
116
- $elem = $(elem),
117
- targ = target, toff, attr = {},
118
- win = $elem.is('html,body');
119
-
120
- switch( typeof targ ){
121
- // A number will pass the regex
122
- case 'number':
123
- case 'string':
124
- if( /^([+-]=)?\d+(\.\d+)?(px|%)?$/.test(targ) ){
125
- targ = both( targ );
126
- // We are done
127
- break;
128
- }
129
- // Relative selector, no break!
130
- targ = $(targ,this);
131
- case 'object':
132
- // DOMElement / jQuery
133
- if( targ.is || targ.style )
134
- // Get the real position of the target
135
- toff = (targ = $(targ)).offset();
136
- }
137
- $.each( settings.axis.split(''), function( i, axis ){
138
- var Pos = axis == 'x' ? 'Left' : 'Top',
139
- pos = Pos.toLowerCase(),
140
- key = 'scroll' + Pos,
141
- old = elem[key],
142
- max = $scrollTo.max(elem, axis);
143
-
144
- if( toff ){// jQuery / DOMElement
145
- attr[key] = toff[pos] + ( win ? 0 : old - $elem.offset()[pos] );
146
-
147
- // If it's a dom element, reduce the margin
148
- if( settings.margin ){
149
- attr[key] -= parseInt(targ.css('margin'+Pos)) || 0;
150
- attr[key] -= parseInt(targ.css('border'+Pos+'Width')) || 0;
151
- }
152
-
153
- attr[key] += settings.offset[pos] || 0;
154
-
155
- if( settings.over[pos] )
156
- // Scroll to a fraction of its width/height
157
- attr[key] += targ[axis=='x'?'width':'height']() * settings.over[pos];
158
- }else{
159
- var val = targ[pos];
160
- // Handle percentage values
161
- attr[key] = val.slice && val.slice(-1) == '%' ?
162
- parseFloat(val) / 100 * max
163
- : val;
164
- }
165
-
166
- // Number or 'number'
167
- if( /^\d+$/.test(attr[key]) )
168
- // Check the limits
169
- attr[key] = attr[key] <= 0 ? 0 : Math.min( attr[key], max );
170
-
171
- // Queueing axes
172
- if( !i && settings.queue ){
173
- // Don't waste time animating, if there's no need.
174
- if( old != attr[key] )
175
- // Intermediate animation
176
- animate( settings.onAfterFirst );
177
- // Don't animate this axis again in the next iteration.
178
- delete attr[key];
179
- }
180
- });
181
-
182
- animate( settings.onAfter );
183
-
184
- function animate( callback ){
185
- $elem.animate( attr, duration, settings.easing, callback && function(){
186
- callback.call(this, target, settings);
187
- });
188
- };
189
-
190
- }).end();
191
- };
192
-
193
- // Max scrolling position, works on quirks mode
194
- // It only fails (not too badly) on IE, quirks mode.
195
- $scrollTo.max = function( elem, axis ){
196
- var Dim = axis == 'x' ? 'Width' : 'Height',
197
- scroll = 'scroll'+Dim;
198
-
199
- if( !$(elem).is('html,body') )
200
- return elem[scroll] - $(elem)[Dim.toLowerCase()]();
201
-
202
- var size = 'client' + Dim,
203
- html = elem.ownerDocument.documentElement,
204
- body = elem.ownerDocument.body;
205
-
206
- return Math.max( html[scroll], body[scroll] )
207
- - Math.min( html[size] , body[size] );
208
-
209
- };
210
-
211
- function both( val ){
212
- return typeof val == 'object' ? val : { top:val, left:val };
213
- };
214
-
215
- })( jQuery );
@@ -1,75 +0,0 @@
1
- /*
2
- *
3
- * jQuery Timer plugin v0.1
4
- * Matt Schmidt [http://www.mattptr.net]
5
- *
6
- * Licensed under the BSD License:
7
- * http://mattptr.net/license/license.txt
8
- *
9
- */
10
-
11
- jQuery.timer = function (interval, callback)
12
- {
13
- /**
14
- *
15
- * timer() provides a cleaner way to handle intervals
16
- *
17
- * @usage
18
- * $.timer(interval, callback);
19
- *
20
- *
21
- * @example
22
- * $.timer(1000, function (timer) {
23
- * alert("hello");
24
- * timer.stop();
25
- * });
26
- * @desc Show an alert box after 1 second and stop
27
- *
28
- * @example
29
- * var second = false;
30
- * $.timer(1000, function (timer) {
31
- * if (!second) {
32
- * alert('First time!');
33
- * second = true;
34
- * timer.reset(3000);
35
- * }
36
- * else {
37
- * alert('Second time');
38
- * timer.stop();
39
- * }
40
- * });
41
- * @desc Show an alert box after 1 second and show another after 3 seconds
42
- *
43
- *
44
- */
45
-
46
- var interval = interval || 100;
47
-
48
- if (!callback)
49
- return false;
50
-
51
- _timer = function (interval, callback) {
52
- this.stop = function () {
53
- clearInterval(self.id);
54
- };
55
-
56
- this.internalCallback = function () {
57
- callback(self);
58
- };
59
-
60
- this.reset = function (val) {
61
- if (self.id)
62
- clearInterval(self.id);
63
-
64
- var val = val || interval || 100;
65
- this.id = setInterval(this.internalCallback, val);
66
- };
67
-
68
- this.interval = interval;
69
- this.id = setInterval(this.internalCallback, this.interval);
70
-
71
- var self = this;
72
- };
73
-
74
- return new _timer(interval, callback);
75
- };
@@ -1,184 +0,0 @@
1
- body {
2
- text-align: center;
3
- font-family: Lucida Grande; }
4
-
5
- img {
6
- margin: -2px 0px 0px; }
7
-
8
- p span.explanation {
9
- color: #999999; }
10
-
11
- pre {
12
- padding: 10px;
13
- background-color: #efede5; }
14
-
15
- div.content {
16
- width: 800px;
17
- margin: 0 auto;
18
- text-align: left; }
19
-
20
- #picky {
21
- text-align: left;
22
- margin: 0px auto;
23
- width: 560px;
24
- overflow: hidden; }
25
- #picky .dashboard {
26
- position: relative;
27
- overflow: hidden;
28
- background-color: lightGrey;
29
- padding: 5px 5px 7px 5px;
30
- height: 26px;
31
- margin-bottom: 3px; }
32
- #picky .status {
33
- float: left;
34
- width: 45px;
35
- height: 26px;
36
- line-height: 26px;
37
- text-align: center;
38
- padding: 0 0 0 2px;
39
- font-weight: bold;
40
- color: white;
41
- margin-right: 5px; }
42
- #picky .status.alert {
43
- background-color: lightgreen; }
44
- #picky .results {
45
- margin-top: 0px;
46
- padding: 0px; }
47
- #picky .results div.book {
48
- background-color: #ffeeee;
49
- padding: 5px 25px;
50
- margin: 3px 0px; }
51
- #picky .results em {
52
- font-style: normal;
53
- background-color: #fff196; }
54
- #picky .results .item {
55
- display: block;
56
- padding: 10px; }
57
- #picky .results .addination {
58
- position: relative;
59
- text-align: center;
60
- padding: 7px 5px 5px 5px;
61
- background-color: #eeeeee;
62
- color: #276abb;
63
- cursor: pointer; }
64
- #picky .results .addination .tothetop {
65
- position: absolute;
66
- top: 4px;
67
- right: 0px; }
68
- #picky .results .addination .tothetop a {
69
- display: block;
70
- width: 20px;
71
- height: 20px; }
72
- #picky .results .info {
73
- color: #555555;
74
- background-color: #eeeeee;
75
- padding: 6px 5px 5px 8px; }
76
- #picky .results .info .tothetop {
77
- float: right;
78
- margin-top: -4px; }
79
- #picky .feedback {
80
- width: 460px;
81
- float: left;
82
- border: 1px solid #cccccc;
83
- padding: 0;
84
- margin: 0; }
85
- #picky .feedback .reset {
86
- float: right;
87
- width: 18px;
88
- height: 18px;
89
- margin: 3px 3px 0px 0px;
90
- cursor: pointer;
91
- opacity: 0; }
92
- #picky .empty .status {
93
- background-color: #8cacda; }
94
- #picky .empty .feedback {
95
- background-color: #d0e2ff; }
96
- #picky .none .status {
97
- background-color: red; }
98
- #picky .none .feedback {
99
- background-color: #ffdddd; }
100
- #picky .support .status {
101
- background-color: #ff6600; }
102
- #picky .support .feedback {
103
- background-color: #faf3d0; }
104
- #picky .ok .status {
105
- background-color: #09be01; }
106
- #picky .ok .feedback {
107
- background-color: #bcf0b3; }
108
- #picky input.search_button {
109
- margin: 5px 15px; }
110
- #picky input.query {
111
- float: left;
112
- width: 380px;
113
- height: 100%;
114
- font-size: 1em;
115
- font-weight: bold;
116
- border-style: solid;
117
- border-width: 0px 0px 3px 0px;
118
- border-color: transparent;
119
- margin: 0;
120
- padding: 4px 0 0 0;
121
- outline: none;
122
- background: none; }
123
- #picky .allocations {
124
- clear: both;
125
- overflow: hidden;
126
- background-color: white;
127
- padding-bottom: 2px; }
128
- #picky .allocations ol.hidden {
129
- display: none; }
130
- #picky .allocations ol.more:hover {
131
- background-color: #cccccc;
132
- cursor: pointer; }
133
- #picky .allocations ol.more {
134
- background-color: #eeeeee;
135
- display: none;
136
- text-align: center;
137
- height: 32px;
138
- line-height: 32px; }
139
- #picky .allocations ol.more li {
140
- text-align: center; }
141
- #picky .allocations ol {
142
- list-style-position: outside;
143
- list-style: none;
144
- padding: 0;
145
- margin: 0px;
146
- overflow: hidden; }
147
- #picky .allocations ol li {
148
- margin: 0px;
149
- margin-bottom: 3px;
150
- padding: 10px 13px;
151
- cursor: pointer;
152
- display: block;
153
- font: menu;
154
- font-size: 1em;
155
- line-height: 16px;
156
- background-color: #f3f3f3;
157
- overflow: hidden;
158
- color: #276abb; }
159
- #picky .allocations ol li .text {
160
- max-width: 90%;
161
- float: left; }
162
- #picky .allocations ol li .count {
163
- float: right;
164
- color: #cccccc; }
165
- #picky .allocations ol li:hover {
166
- background-color: #d0e2ff; }
167
- #picky .allocations .company, #picky .allocations .person {
168
- width: 49%; }
169
- #picky .allocations .person {
170
- float: left;
171
- margin-right: 10px; }
172
- #picky .allocations .company {
173
- float: right; }
174
- #picky .no_results {
175
- display: none;
176
- clear: both;
177
- overflow: hidden; }
178
- #picky .no_results ul {
179
- list-style-type: disc;
180
- padding-left: 13px; }
181
- #picky .no_results a {
182
- display: block; }
183
- #picky > .info {
184
- display: none; }