docs-gaia-jekyll-theme 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/LICENSE.txt +21 -0
- data/README.md +46 -0
- data/_layouts/default.html +100 -0
- data/assets/css/asciidoctor.css +398 -0
- data/assets/css/coderay.css +90 -0
- data/assets/css/font-awesome.css +1801 -0
- data/assets/css/font-awesome.min.css +4 -0
- data/assets/css/foundation.css +8545 -0
- data/assets/css/foundation.min.css +8331 -0
- data/assets/css/normalize.css +427 -0
- data/assets/images/cambio-logo.png +0 -0
- data/assets/images/header-page.png +0 -0
- data/assets/js/foundation/foundation.abide.js +325 -0
- data/assets/js/foundation/foundation.accordion.js +71 -0
- data/assets/js/foundation/foundation.alert.js +46 -0
- data/assets/js/foundation/foundation.clearing.js +573 -0
- data/assets/js/foundation/foundation.dropdown.js +444 -0
- data/assets/js/foundation/foundation.equalizer.js +77 -0
- data/assets/js/foundation/foundation.interchange.js +349 -0
- data/assets/js/foundation/foundation.joyride.js +939 -0
- data/assets/js/foundation/foundation.js +691 -0
- data/assets/js/foundation/foundation.magellan.js +199 -0
- data/assets/js/foundation/foundation.offcanvas.js +154 -0
- data/assets/js/foundation/foundation.orbit.js +512 -0
- data/assets/js/foundation/foundation.reveal.js +455 -0
- data/assets/js/foundation/foundation.slider.js +268 -0
- data/assets/js/foundation/foundation.tab.js +221 -0
- data/assets/js/foundation/foundation.tooltip.js +301 -0
- data/assets/js/foundation/foundation.topbar.js +444 -0
- data/assets/js/foundation.min.js +6069 -0
- data/assets/js/toc.js +82 -0
- data/assets/js/vendor/fastclick.js +169 -0
- data/assets/js/vendor/jquery.cookie.js +57 -0
- data/assets/js/vendor/jquery.js +2339 -0
- data/assets/js/vendor/modernizr.js +304 -0
- data/assets/js/vendor/placeholder.js +75 -0
- metadata +122 -0
@@ -0,0 +1,199 @@
|
|
1
|
+
;
|
2
|
+
(function ($, window, document, undefined) {
|
3
|
+
'use strict';
|
4
|
+
|
5
|
+
Foundation.libs['magellan-expedition'] = {
|
6
|
+
name: 'magellan-expedition',
|
7
|
+
|
8
|
+
version: '5.5.0',
|
9
|
+
|
10
|
+
settings: {
|
11
|
+
active_class: 'active',
|
12
|
+
threshold: 0, // pixels from the top of the expedition for it to become fixes
|
13
|
+
destination_threshold: 20, // pixels from the top of destination for it to be considered active
|
14
|
+
throttle_delay: 30, // calculation throttling to increase framerate
|
15
|
+
fixed_top: 0, // top distance in pixels assigend to the fixed element on scroll
|
16
|
+
offset_by_height: true, // whether to offset the destination by the expedition height. Usually you want this to be true, unless your expedition is on the side.
|
17
|
+
duration: 700, // animation duration time
|
18
|
+
easing: 'swing' // animation easing
|
19
|
+
},
|
20
|
+
|
21
|
+
init: function (scope, method, options) {
|
22
|
+
Foundation.inherit(this, 'throttle');
|
23
|
+
this.bindings(method, options);
|
24
|
+
},
|
25
|
+
|
26
|
+
events: function () {
|
27
|
+
var self = this,
|
28
|
+
S = self.S,
|
29
|
+
settings = self.settings;
|
30
|
+
|
31
|
+
// initialize expedition offset
|
32
|
+
self.set_expedition_position();
|
33
|
+
|
34
|
+
S(self.scope)
|
35
|
+
.off('.magellan')
|
36
|
+
.on('click.fndtn.magellan', '[' + self.add_namespace('data-magellan-arrival') + '] a[href^="#"]', function (e) {
|
37
|
+
e.preventDefault();
|
38
|
+
var expedition = $(this).closest('[' + self.attr_name() + ']'),
|
39
|
+
settings = expedition.data('magellan-expedition-init'),
|
40
|
+
hash = this.hash.split('#').join(''),
|
41
|
+
target = $('a[name="' + hash + '"]');
|
42
|
+
|
43
|
+
if (target.length === 0) {
|
44
|
+
target = $('#' + hash);
|
45
|
+
|
46
|
+
}
|
47
|
+
|
48
|
+
|
49
|
+
// Account for expedition height if fixed position
|
50
|
+
var scroll_top = target.offset().top - settings.destination_threshold + 1;
|
51
|
+
if (settings.offset_by_height) {
|
52
|
+
scroll_top = scroll_top - expedition.outerHeight();
|
53
|
+
}
|
54
|
+
|
55
|
+
$('html, body').stop().animate({
|
56
|
+
'scrollTop': scroll_top
|
57
|
+
}, settings.duration, settings.easing, function () {
|
58
|
+
if (history.pushState) {
|
59
|
+
history.pushState(null, null, '#' + hash);
|
60
|
+
}
|
61
|
+
else {
|
62
|
+
location.hash = '#' + hash;
|
63
|
+
}
|
64
|
+
});
|
65
|
+
})
|
66
|
+
.on('scroll.fndtn.magellan', self.throttle(this.check_for_arrivals.bind(this), settings.throttle_delay));
|
67
|
+
|
68
|
+
$(window)
|
69
|
+
.on('resize.fndtn.magellan', self.throttle(this.set_expedition_position.bind(this), settings.throttle_delay));
|
70
|
+
},
|
71
|
+
|
72
|
+
check_for_arrivals: function () {
|
73
|
+
var self = this;
|
74
|
+
self.update_arrivals();
|
75
|
+
self.update_expedition_positions();
|
76
|
+
},
|
77
|
+
|
78
|
+
set_expedition_position: function () {
|
79
|
+
var self = this;
|
80
|
+
$('[' + this.attr_name() + '=fixed]', self.scope).each(function (idx, el) {
|
81
|
+
var expedition = $(this),
|
82
|
+
settings = expedition.data('magellan-expedition-init'),
|
83
|
+
styles = expedition.attr('styles'), // save styles
|
84
|
+
top_offset, fixed_top;
|
85
|
+
|
86
|
+
expedition.attr('style', '');
|
87
|
+
top_offset = expedition.offset().top + settings.threshold;
|
88
|
+
|
89
|
+
//set fixed-top by attribute
|
90
|
+
fixed_top = parseInt(expedition.data('magellan-fixed-top'));
|
91
|
+
if (!isNaN(fixed_top))
|
92
|
+
self.settings.fixed_top = fixed_top;
|
93
|
+
|
94
|
+
expedition.data(self.data_attr('magellan-top-offset'), top_offset);
|
95
|
+
expedition.attr('style', styles);
|
96
|
+
});
|
97
|
+
},
|
98
|
+
|
99
|
+
update_expedition_positions: function () {
|
100
|
+
var self = this,
|
101
|
+
window_top_offset = $(window).scrollTop();
|
102
|
+
|
103
|
+
$('[' + this.attr_name() + '=fixed]', self.scope).each(function () {
|
104
|
+
var expedition = $(this),
|
105
|
+
settings = expedition.data('magellan-expedition-init'),
|
106
|
+
styles = expedition.attr('style'), // save styles
|
107
|
+
top_offset = expedition.data('magellan-top-offset');
|
108
|
+
|
109
|
+
//scroll to the top distance
|
110
|
+
if (window_top_offset + self.settings.fixed_top >= top_offset) {
|
111
|
+
// Placeholder allows height calculations to be consistent even when
|
112
|
+
// appearing to switch between fixed/non-fixed placement
|
113
|
+
var placeholder = expedition.prev('[' + self.add_namespace('data-magellan-expedition-clone') + ']');
|
114
|
+
if (placeholder.length === 0) {
|
115
|
+
placeholder = expedition.clone();
|
116
|
+
placeholder.removeAttr(self.attr_name());
|
117
|
+
placeholder.attr(self.add_namespace('data-magellan-expedition-clone'), '');
|
118
|
+
expedition.before(placeholder);
|
119
|
+
}
|
120
|
+
expedition.css({position: 'fixed', top: settings.fixed_top}).addClass('fixed');
|
121
|
+
} else {
|
122
|
+
expedition.prev('[' + self.add_namespace('data-magellan-expedition-clone') + ']').remove();
|
123
|
+
expedition.attr('style', styles).css('position', '').css('top', '').removeClass('fixed');
|
124
|
+
}
|
125
|
+
});
|
126
|
+
},
|
127
|
+
|
128
|
+
update_arrivals: function () {
|
129
|
+
var self = this,
|
130
|
+
window_top_offset = $(window).scrollTop();
|
131
|
+
|
132
|
+
$('[' + this.attr_name() + ']', self.scope).each(function () {
|
133
|
+
var expedition = $(this),
|
134
|
+
settings = expedition.data(self.attr_name(true) + '-init'),
|
135
|
+
offsets = self.offsets(expedition, window_top_offset),
|
136
|
+
arrivals = expedition.find('[' + self.add_namespace('data-magellan-arrival') + ']'),
|
137
|
+
active_item = false;
|
138
|
+
offsets.each(function (idx, item) {
|
139
|
+
if (item.viewport_offset >= item.top_offset) {
|
140
|
+
var arrivals = expedition.find('[' + self.add_namespace('data-magellan-arrival') + ']');
|
141
|
+
arrivals.not(item.arrival).removeClass(settings.active_class);
|
142
|
+
item.arrival.addClass(settings.active_class);
|
143
|
+
active_item = true;
|
144
|
+
return true;
|
145
|
+
}
|
146
|
+
});
|
147
|
+
|
148
|
+
if (!active_item) arrivals.removeClass(settings.active_class);
|
149
|
+
});
|
150
|
+
},
|
151
|
+
|
152
|
+
offsets: function (expedition, window_offset) {
|
153
|
+
var self = this,
|
154
|
+
settings = expedition.data(self.attr_name(true) + '-init'),
|
155
|
+
viewport_offset = window_offset;
|
156
|
+
|
157
|
+
return expedition.find('[' + self.add_namespace('data-magellan-arrival') + ']').map(function (idx, el) {
|
158
|
+
var name = $(this).data(self.data_attr('magellan-arrival')),
|
159
|
+
dest = $('[' + self.add_namespace('data-magellan-destination') + '=' + name + ']');
|
160
|
+
if (dest.length > 0) {
|
161
|
+
var top_offset = dest.offset().top - settings.destination_threshold;
|
162
|
+
if (settings.offset_by_height) {
|
163
|
+
top_offset = top_offset - expedition.outerHeight();
|
164
|
+
}
|
165
|
+
top_offset = Math.floor(top_offset);
|
166
|
+
return {
|
167
|
+
destination: dest,
|
168
|
+
arrival: $(this),
|
169
|
+
top_offset: top_offset,
|
170
|
+
viewport_offset: viewport_offset
|
171
|
+
}
|
172
|
+
}
|
173
|
+
}).sort(function (a, b) {
|
174
|
+
if (a.top_offset < b.top_offset) return -1;
|
175
|
+
if (a.top_offset > b.top_offset) return 1;
|
176
|
+
return 0;
|
177
|
+
});
|
178
|
+
},
|
179
|
+
|
180
|
+
data_attr: function (str) {
|
181
|
+
if (this.namespace.length > 0) {
|
182
|
+
return this.namespace + '-' + str;
|
183
|
+
}
|
184
|
+
|
185
|
+
return str;
|
186
|
+
},
|
187
|
+
|
188
|
+
off: function () {
|
189
|
+
this.S(this.scope).off('.magellan');
|
190
|
+
this.S(window).off('.magellan');
|
191
|
+
},
|
192
|
+
|
193
|
+
reflow: function () {
|
194
|
+
var self = this;
|
195
|
+
// remove placeholder expeditions used for height calculation purposes
|
196
|
+
$('[' + self.add_namespace('data-magellan-expedition-clone') + ']', self.scope).remove();
|
197
|
+
}
|
198
|
+
};
|
199
|
+
}(jQuery, window, window.document));
|
@@ -0,0 +1,154 @@
|
|
1
|
+
;
|
2
|
+
(function ($, window, document, undefined) {
|
3
|
+
'use strict';
|
4
|
+
|
5
|
+
Foundation.libs.offcanvas = {
|
6
|
+
name: 'offcanvas',
|
7
|
+
|
8
|
+
version: '5.5.0',
|
9
|
+
|
10
|
+
settings: {
|
11
|
+
open_method: 'move',
|
12
|
+
close_on_click: false
|
13
|
+
},
|
14
|
+
|
15
|
+
init: function (scope, method, options) {
|
16
|
+
this.bindings(method, options);
|
17
|
+
},
|
18
|
+
|
19
|
+
events: function () {
|
20
|
+
var self = this,
|
21
|
+
S = self.S,
|
22
|
+
move_class = '',
|
23
|
+
right_postfix = '',
|
24
|
+
left_postfix = '';
|
25
|
+
|
26
|
+
if (this.settings.open_method === 'move') {
|
27
|
+
move_class = 'move-';
|
28
|
+
right_postfix = 'right';
|
29
|
+
left_postfix = 'left';
|
30
|
+
} else if (this.settings.open_method === 'overlap_single') {
|
31
|
+
move_class = 'offcanvas-overlap-';
|
32
|
+
right_postfix = 'right';
|
33
|
+
left_postfix = 'left';
|
34
|
+
} else if (this.settings.open_method === 'overlap') {
|
35
|
+
move_class = 'offcanvas-overlap';
|
36
|
+
}
|
37
|
+
|
38
|
+
S(this.scope).off('.offcanvas')
|
39
|
+
.on('click.fndtn.offcanvas', '.left-off-canvas-toggle', function (e) {
|
40
|
+
self.click_toggle_class(e, move_class + right_postfix);
|
41
|
+
if (self.settings.open_method !== 'overlap') {
|
42
|
+
S('.left-submenu').removeClass(move_class + right_postfix);
|
43
|
+
}
|
44
|
+
$('.left-off-canvas-toggle').attr('aria-expanded', 'true');
|
45
|
+
})
|
46
|
+
.on('click.fndtn.offcanvas', '.left-off-canvas-menu a', function (e) {
|
47
|
+
var settings = self.get_settings(e);
|
48
|
+
var parent = S(this).parent();
|
49
|
+
|
50
|
+
if (settings.close_on_click && !parent.hasClass('has-submenu') && !parent.hasClass('back')) {
|
51
|
+
self.hide.call(self, move_class + right_postfix, self.get_wrapper(e));
|
52
|
+
parent.parent().removeClass(move_class + right_postfix);
|
53
|
+
} else if (S(this).parent().hasClass('has-submenu')) {
|
54
|
+
e.preventDefault();
|
55
|
+
S(this).siblings('.left-submenu').toggleClass(move_class + right_postfix);
|
56
|
+
} else if (parent.hasClass('back')) {
|
57
|
+
e.preventDefault();
|
58
|
+
parent.parent().removeClass(move_class + right_postfix);
|
59
|
+
}
|
60
|
+
$('.left-off-canvas-toggle').attr('aria-expanded', 'true');
|
61
|
+
})
|
62
|
+
.on('click.fndtn.offcanvas', '.right-off-canvas-toggle', function (e) {
|
63
|
+
self.click_toggle_class(e, move_class + left_postfix);
|
64
|
+
if (self.settings.open_method !== 'overlap') {
|
65
|
+
S('.right-submenu').removeClass(move_class + left_postfix);
|
66
|
+
}
|
67
|
+
$('.right-off-canvas-toggle').attr('aria-expanded', 'true');
|
68
|
+
})
|
69
|
+
.on('click.fndtn.offcanvas', '.right-off-canvas-menu a', function (e) {
|
70
|
+
var settings = self.get_settings(e);
|
71
|
+
var parent = S(this).parent();
|
72
|
+
|
73
|
+
if (settings.close_on_click && !parent.hasClass('has-submenu') && !parent.hasClass('back')) {
|
74
|
+
self.hide.call(self, move_class + left_postfix, self.get_wrapper(e));
|
75
|
+
parent.parent().removeClass(move_class + left_postfix);
|
76
|
+
} else if (S(this).parent().hasClass('has-submenu')) {
|
77
|
+
e.preventDefault();
|
78
|
+
S(this).siblings('.right-submenu').toggleClass(move_class + left_postfix);
|
79
|
+
} else if (parent.hasClass('back')) {
|
80
|
+
e.preventDefault();
|
81
|
+
parent.parent().removeClass(move_class + left_postfix);
|
82
|
+
}
|
83
|
+
$('.right-off-canvas-toggle').attr('aria-expanded', 'true');
|
84
|
+
})
|
85
|
+
.on('click.fndtn.offcanvas', '.exit-off-canvas', function (e) {
|
86
|
+
self.click_remove_class(e, move_class + left_postfix);
|
87
|
+
S('.right-submenu').removeClass(move_class + left_postfix);
|
88
|
+
if (right_postfix) {
|
89
|
+
self.click_remove_class(e, move_class + right_postfix);
|
90
|
+
S('.left-submenu').removeClass(move_class + left_postfix);
|
91
|
+
}
|
92
|
+
$('.right-off-canvas-toggle').attr('aria-expanded', 'true');
|
93
|
+
})
|
94
|
+
.on('click.fndtn.offcanvas', '.exit-off-canvas', function (e) {
|
95
|
+
self.click_remove_class(e, move_class + left_postfix);
|
96
|
+
$('.left-off-canvas-toggle').attr('aria-expanded', 'false');
|
97
|
+
if (right_postfix) {
|
98
|
+
self.click_remove_class(e, move_class + right_postfix);
|
99
|
+
$('.right-off-canvas-toggle').attr('aria-expanded', 'false');
|
100
|
+
}
|
101
|
+
});
|
102
|
+
},
|
103
|
+
|
104
|
+
toggle: function (class_name, $off_canvas) {
|
105
|
+
$off_canvas = $off_canvas || this.get_wrapper();
|
106
|
+
if ($off_canvas.is('.' + class_name)) {
|
107
|
+
this.hide(class_name, $off_canvas);
|
108
|
+
} else {
|
109
|
+
this.show(class_name, $off_canvas);
|
110
|
+
}
|
111
|
+
},
|
112
|
+
|
113
|
+
show: function (class_name, $off_canvas) {
|
114
|
+
$off_canvas = $off_canvas || this.get_wrapper();
|
115
|
+
$off_canvas.trigger('open').trigger('open.fndtn.offcanvas');
|
116
|
+
$off_canvas.addClass(class_name);
|
117
|
+
},
|
118
|
+
|
119
|
+
hide: function (class_name, $off_canvas) {
|
120
|
+
$off_canvas = $off_canvas || this.get_wrapper();
|
121
|
+
$off_canvas.trigger('close').trigger('close.fndtn.offcanvas');
|
122
|
+
$off_canvas.removeClass(class_name);
|
123
|
+
},
|
124
|
+
|
125
|
+
click_toggle_class: function (e, class_name) {
|
126
|
+
e.preventDefault();
|
127
|
+
var $off_canvas = this.get_wrapper(e);
|
128
|
+
this.toggle(class_name, $off_canvas);
|
129
|
+
},
|
130
|
+
|
131
|
+
click_remove_class: function (e, class_name) {
|
132
|
+
e.preventDefault();
|
133
|
+
var $off_canvas = this.get_wrapper(e);
|
134
|
+
this.hide(class_name, $off_canvas);
|
135
|
+
},
|
136
|
+
|
137
|
+
get_settings: function (e) {
|
138
|
+
var offcanvas = this.S(e.target).closest('[' + this.attr_name() + ']');
|
139
|
+
return offcanvas.data(this.attr_name(true) + '-init') || this.settings;
|
140
|
+
},
|
141
|
+
|
142
|
+
get_wrapper: function (e) {
|
143
|
+
var $off_canvas = this.S(e ? e.target : this.scope).closest('.off-canvas-wrap');
|
144
|
+
|
145
|
+
if ($off_canvas.length === 0) {
|
146
|
+
$off_canvas = this.S('.off-canvas-wrap');
|
147
|
+
}
|
148
|
+
return $off_canvas;
|
149
|
+
},
|
150
|
+
|
151
|
+
reflow: function () {
|
152
|
+
}
|
153
|
+
};
|
154
|
+
}(jQuery, window, window.document));
|