locomotivecms_wagon 2.2.0.beta1 → 2.2.0.rc1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +2 -1
- data/generators/blank/config/metafields_schema.yml +1 -1
- data/generators/bootstrap/config/metafields_schema.yml +1 -1
- data/generators/{foundation5 → foundation}/Gemfile.tt +1 -1
- data/generators/{foundation5 → foundation}/Guardfile +0 -0
- data/generators/foundation/app/content_types/.gitkeep +0 -0
- data/generators/foundation/app/views/pages/404.liquid +11 -0
- data/generators/{foundation5 → foundation}/app/views/pages/404.liquid.haml +4 -3
- data/generators/{foundation5 → foundation}/app/views/pages/index.liquid +54 -78
- data/generators/foundation/app/views/pages/index.liquid.haml +144 -0
- data/generators/foundation/app/views/snippets/.gitkeep +0 -0
- data/generators/{foundation5 → foundation}/config/deploy.yml +2 -1
- data/generators/{foundation5 → foundation}/config/metafields_schema.yml +1 -1
- data/generators/{foundation5/config/site.yml.tt → foundation/config/site.yml} +2 -2
- data/generators/{foundation5 → foundation}/config/translations.yml +0 -0
- data/generators/foundation/data/.gitkeep +0 -0
- data/generators/foundation/log/.gitkeep +0 -0
- data/generators/foundation/public/images/.gitkeep +0 -0
- data/generators/foundation/public/javascripts/app.js +1 -0
- data/generators/foundation/public/javascripts/vendor/foundation.js +7472 -0
- data/generators/foundation/public/javascripts/vendor/foundation.min.js +3 -0
- data/generators/foundation/public/javascripts/vendor/what-input.js +212 -0
- data/generators/foundation/public/javascripts/vendor/what-input.min.js +1 -0
- data/generators/foundation/public/stylesheets/_settings.scss +529 -0
- data/generators/foundation/public/stylesheets/app.css +3 -0
- data/generators/foundation/public/stylesheets/app.scss +43 -0
- data/generators/foundation/public/stylesheets/foundation.css +3499 -0
- data/generators/foundation/public/stylesheets/foundation6/_global.scss +197 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_accordion-menu.scss +28 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_accordion.scss +112 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_badge.scss +55 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_breadcrumbs.scss +94 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_button-group.scss +115 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_button.scss +264 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_callout.scss +115 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_close-button.scss +61 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_drilldown.scss +67 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_dropdown-menu.scss +123 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_dropdown.scss +64 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_flex-video.scss +68 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_float.scss +27 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_label.scss +56 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_media-object.scss +74 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_menu.scss +213 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_off-canvas.scss +170 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_orbit.scss +186 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_pagination.scss +161 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_progress-bar.scss +83 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_reveal.scss +155 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_slider.scss +158 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_sticky.scss +38 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_switch.scss +231 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_table.scss +212 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_tabs.scss +137 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_thumbnail.scss +54 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_title-bar.scss +44 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_tooltip.scss +110 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_top-bar.scss +57 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_visibility.scss +131 -0
- data/generators/foundation/public/stylesheets/foundation6/forms/_checkbox.scss +36 -0
- data/generators/foundation/public/stylesheets/foundation6/forms/_error.scss +81 -0
- data/generators/foundation/public/stylesheets/foundation6/forms/_fieldset.scss +53 -0
- data/generators/foundation/public/stylesheets/foundation6/forms/_forms.scss +32 -0
- data/generators/foundation/public/stylesheets/foundation6/forms/_help-text.scss +30 -0
- data/generators/foundation/public/stylesheets/foundation6/forms/_input-group.scss +70 -0
- data/generators/foundation/public/stylesheets/foundation6/forms/_label.scss +48 -0
- data/generators/foundation/public/stylesheets/foundation6/forms/_select.scss +64 -0
- data/generators/foundation/public/stylesheets/foundation6/forms/_text.scss +153 -0
- data/generators/foundation/public/stylesheets/foundation6/foundation.scss +91 -0
- data/generators/foundation/public/stylesheets/foundation6/grid/_classes.scss +132 -0
- data/generators/foundation/public/stylesheets/foundation6/grid/_column.scss +112 -0
- data/generators/foundation/public/stylesheets/foundation6/grid/_flex-grid.scss +191 -0
- data/generators/foundation/public/stylesheets/foundation6/grid/_grid.scss +33 -0
- data/generators/foundation/public/stylesheets/foundation6/grid/_gutter.scss +31 -0
- data/generators/foundation/public/stylesheets/foundation6/grid/_layout.scss +32 -0
- data/generators/foundation/public/stylesheets/foundation6/grid/_position.scss +71 -0
- data/generators/foundation/public/stylesheets/foundation6/grid/_row.scss +72 -0
- data/generators/foundation/public/stylesheets/foundation6/grid/_size.scss +24 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/_classes.scss +102 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/_settings.scss +61 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/effects/_fade.scss +29 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/effects/_hinge.scss +65 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/effects/_shake.scss +15 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/effects/_slide.scss +41 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/effects/_spin.scss +28 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/effects/_wiggle.scss +13 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/effects/_zoom.scss +15 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/motion-ui.scss +29 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/transitions/_fade.scss +28 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/transitions/_hinge.scss +43 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/transitions/_slide.scss +42 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/transitions/_spin.scss +39 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/transitions/_zoom.scss +39 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/util/_animation.scss +7 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/util/_args.scss +15 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/util/_keyframe.scss +136 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/util/_selector.scss +23 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/util/_series.scss +54 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/util/_transition.scss +45 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/util/_unit.scss +7 -0
- data/generators/foundation/public/stylesheets/foundation6/motion-ui.scss +4 -0
- data/generators/foundation/public/stylesheets/foundation6/settings/_settings.scss +531 -0
- data/generators/foundation/public/stylesheets/foundation6/typography/_alignment.scss +21 -0
- data/generators/foundation/public/stylesheets/foundation6/typography/_base.scss +436 -0
- data/generators/foundation/public/stylesheets/foundation6/typography/_helpers.scss +77 -0
- data/generators/foundation/public/stylesheets/foundation6/typography/_print.scss +73 -0
- data/generators/foundation/public/stylesheets/foundation6/typography/_typography.scss +28 -0
- data/generators/foundation/public/stylesheets/foundation6/util/_breakpoint.scss +182 -0
- data/generators/foundation/public/stylesheets/foundation6/util/_color.scss +41 -0
- data/generators/foundation/public/stylesheets/foundation6/util/_mixins.scss +190 -0
- data/generators/foundation/public/stylesheets/foundation6/util/_selector.scss +39 -0
- data/generators/foundation/public/stylesheets/foundation6/util/_unit.scss +69 -0
- data/generators/foundation/public/stylesheets/foundation6/util/_util.scss +15 -0
- data/generators/foundation/public/stylesheets/foundation6/util/_value.scss +117 -0
- data/generators/{foundation5/public/stylesheets/normalize.css.scss → foundation/public/stylesheets/foundation6/vendor/normalize.scss} +8 -11
- data/generators/site_metafields/schema.yml.tt +1 -1
- data/lib/locomotive/wagon/commands/push_command.rb +1 -0
- data/lib/locomotive/wagon/commands/serve_command.rb +1 -0
- data/lib/locomotive/wagon/decorators/concerns/persist_assets_concern.rb +3 -3
- data/lib/locomotive/wagon/decorators/content_type_decorator.rb +5 -1
- data/lib/locomotive/wagon/generators/site/{foundation5.rb → foundation.rb} +8 -12
- data/lib/locomotive/wagon/generators/site.rb +1 -1
- data/lib/locomotive/wagon/version.rb +1 -1
- data/locomotivecms_wagon.gemspec +3 -2
- data/spec/fixtures/cassettes/authenticate.yml +38 -38
- data/spec/fixtures/cassettes/delete.yml +211 -211
- data/spec/fixtures/cassettes/push.yml +1333 -1374
- data/spec/integration/cli_spec.rb +1 -1
- data/spec/unit/decorators/content_entry_decorator_spec.rb +23 -0
- metadata +133 -104
- data/generators/foundation5/app/content_types/.empty_directory +0 -1
- data/generators/foundation5/app/views/pages/404.liquid +0 -10
- data/generators/foundation5/app/views/pages/index.liquid.haml +0 -157
- data/generators/foundation5/data/.empty_directory +0 -1
- data/generators/foundation5/icon.png +0 -0
- data/generators/foundation5/public/fonts/.empty_directory +0 -1
- data/generators/foundation5/public/images/.empty_directory +0 -1
- data/generators/foundation5/public/javascripts/foundation/foundation.abide.js +0 -299
- data/generators/foundation5/public/javascripts/foundation/foundation.accordion.js +0 -59
- data/generators/foundation5/public/javascripts/foundation/foundation.alert.js +0 -43
- data/generators/foundation5/public/javascripts/foundation/foundation.clearing.js +0 -534
- data/generators/foundation5/public/javascripts/foundation/foundation.dropdown.js +0 -311
- data/generators/foundation5/public/javascripts/foundation/foundation.equalizer.js +0 -74
- data/generators/foundation5/public/javascripts/foundation/foundation.interchange.js +0 -331
- data/generators/foundation5/public/javascripts/foundation/foundation.joyride.js +0 -843
- data/generators/foundation5/public/javascripts/foundation/foundation.js +0 -611
- data/generators/foundation5/public/javascripts/foundation/foundation.magellan.js +0 -178
- data/generators/foundation5/public/javascripts/foundation/foundation.offcanvas.js +0 -108
- data/generators/foundation5/public/javascripts/foundation/foundation.orbit.js +0 -610
- data/generators/foundation5/public/javascripts/foundation/foundation.reveal.js +0 -437
- data/generators/foundation5/public/javascripts/foundation/foundation.slider.js +0 -199
- data/generators/foundation5/public/javascripts/foundation/foundation.tab.js +0 -167
- data/generators/foundation5/public/javascripts/foundation/foundation.tooltip.js +0 -298
- data/generators/foundation5/public/javascripts/foundation/foundation.topbar.js +0 -425
- data/generators/foundation5/public/javascripts/foundation.js +0 -4161
- data/generators/foundation5/public/javascripts/foundation.min.js +0 -10
- data/generators/foundation5/public/javascripts/vendor/custom.modernizr.js +0 -4
- data/generators/foundation5/public/javascripts/vendor/custom.modernizr.min.js +0 -1
- data/generators/foundation5/public/javascripts/vendor/fastclick.js +0 -9
- data/generators/foundation5/public/javascripts/vendor/fastclick.min.js +0 -11
- data/generators/foundation5/public/javascripts/vendor/jquery.autocomplete.js +0 -645
- data/generators/foundation5/public/javascripts/vendor/jquery.autocomplete.min.js +0 -1
- data/generators/foundation5/public/javascripts/vendor/jquery.cookie.js +0 -8
- data/generators/foundation5/public/javascripts/vendor/jquery.cookie.min.js +0 -8
- data/generators/foundation5/public/javascripts/vendor/jquery.js +0 -26
- data/generators/foundation5/public/javascripts/vendor/jquery.min.js +0 -27
- data/generators/foundation5/public/javascripts/vendor/modernizr.js +0 -8
- data/generators/foundation5/public/javascripts/vendor/modernizr.min.js +0 -1
- data/generators/foundation5/public/javascripts/vendor/placeholder.js +0 -2
- data/generators/foundation5/public/javascripts/vendor/placeholder.min.js +0 -1
- data/generators/foundation5/public/samples/.empty_directory +0 -1
- data/generators/foundation5/public/stylesheets/application.css +0 -2
- data/generators/foundation5/public/stylesheets/application.css.scss +0 -3
- data/generators/foundation5/public/stylesheets/foundation/_functions.scss +0 -102
- data/generators/foundation5/public/stylesheets/foundation/_settings.scss +0 -1441
- data/generators/foundation5/public/stylesheets/foundation/components/_accordion.scss +0 -157
- data/generators/foundation5/public/stylesheets/foundation/components/_alert-boxes.scss +0 -128
- data/generators/foundation5/public/stylesheets/foundation/components/_block-grid.scss +0 -132
- data/generators/foundation5/public/stylesheets/foundation/components/_breadcrumbs.scss +0 -132
- data/generators/foundation5/public/stylesheets/foundation/components/_button-groups.scss +0 -197
- data/generators/foundation5/public/stylesheets/foundation/components/_buttons.scss +0 -259
- data/generators/foundation5/public/stylesheets/foundation/components/_clearing.scss +0 -247
- data/generators/foundation5/public/stylesheets/foundation/components/_dropdown-buttons.scss +0 -130
- data/generators/foundation5/public/stylesheets/foundation/components/_dropdown.scss +0 -262
- data/generators/foundation5/public/stylesheets/foundation/components/_flex-video.scss +0 -51
- data/generators/foundation5/public/stylesheets/foundation/components/_forms.scss +0 -585
- data/generators/foundation5/public/stylesheets/foundation/components/_global.scss +0 -460
- data/generators/foundation5/public/stylesheets/foundation/components/_grid.scss +0 -275
- data/generators/foundation5/public/stylesheets/foundation/components/_icon-bar.scss +0 -293
- data/generators/foundation5/public/stylesheets/foundation/components/_inline-lists.scss +0 -57
- data/generators/foundation5/public/stylesheets/foundation/components/_joyride.scss +0 -222
- data/generators/foundation5/public/stylesheets/foundation/components/_keystrokes.scss +0 -61
- data/generators/foundation5/public/stylesheets/foundation/components/_labels.scss +0 -106
- data/generators/foundation5/public/stylesheets/foundation/components/_magellan.scss +0 -34
- data/generators/foundation5/public/stylesheets/foundation/components/_offcanvas.scss +0 -513
- data/generators/foundation5/public/stylesheets/foundation/components/_orbit.scss +0 -368
- data/generators/foundation5/public/stylesheets/foundation/components/_pagination.scss +0 -162
- data/generators/foundation5/public/stylesheets/foundation/components/_panels.scss +0 -95
- data/generators/foundation5/public/stylesheets/foundation/components/_pricing-tables.scss +0 -150
- data/generators/foundation5/public/stylesheets/foundation/components/_progress-bars.scss +0 -79
- data/generators/foundation5/public/stylesheets/foundation/components/_range-slider.scss +0 -168
- data/generators/foundation5/public/stylesheets/foundation/components/_reveal.scss +0 -222
- data/generators/foundation5/public/stylesheets/foundation/components/_side-nav.scss +0 -116
- data/generators/foundation5/public/stylesheets/foundation/components/_split-buttons.scss +0 -191
- data/generators/foundation5/public/stylesheets/foundation/components/_sub-nav.scss +0 -123
- data/generators/foundation5/public/stylesheets/foundation/components/_switches.scss +0 -230
- data/generators/foundation5/public/stylesheets/foundation/components/_tables.scss +0 -135
- data/generators/foundation5/public/stylesheets/foundation/components/_tabs.scss +0 -123
- data/generators/foundation5/public/stylesheets/foundation/components/_thumbs.scss +0 -66
- data/generators/foundation5/public/stylesheets/foundation/components/_toolbar.scss +0 -70
- data/generators/foundation5/public/stylesheets/foundation/components/_tooltips.scss +0 -142
- data/generators/foundation5/public/stylesheets/foundation/components/_top-bar.scss +0 -685
- data/generators/foundation5/public/stylesheets/foundation/components/_type.scss +0 -525
- data/generators/foundation5/public/stylesheets/foundation/components/_visibility.scss +0 -408
- data/generators/foundation5/public/stylesheets/foundation.css +0 -6138
- data/generators/foundation5/public/stylesheets/foundation.css.scss +0 -45
- data/generators/foundation5/public/stylesheets/normalize.css +0 -357
- data/lib/locomotive/wagon/generators/site/foundation4.rb +0 -34
@@ -1,311 +0,0 @@
|
|
1
|
-
;(function ($, window, document, undefined) {
|
2
|
-
'use strict';
|
3
|
-
|
4
|
-
Foundation.libs.dropdown = {
|
5
|
-
name : 'dropdown',
|
6
|
-
|
7
|
-
version : '5.2.3',
|
8
|
-
|
9
|
-
settings : {
|
10
|
-
active_class: 'open',
|
11
|
-
align: 'bottom',
|
12
|
-
is_hover: false,
|
13
|
-
opened: function(){},
|
14
|
-
closed: function(){}
|
15
|
-
},
|
16
|
-
|
17
|
-
init : function (scope, method, options) {
|
18
|
-
Foundation.inherit(this, 'throttle');
|
19
|
-
|
20
|
-
this.bindings(method, options);
|
21
|
-
},
|
22
|
-
|
23
|
-
events : function (scope) {
|
24
|
-
var self = this,
|
25
|
-
S = self.S;
|
26
|
-
|
27
|
-
S(this.scope)
|
28
|
-
.off('.dropdown')
|
29
|
-
.on('click.fndtn.dropdown', '[' + this.attr_name() + ']', function (e) {
|
30
|
-
var settings = S(this).data(self.attr_name(true) + '-init') || self.settings;
|
31
|
-
if (!settings.is_hover || Modernizr.touch) {
|
32
|
-
e.preventDefault();
|
33
|
-
self.toggle($(this));
|
34
|
-
}
|
35
|
-
})
|
36
|
-
.on('mouseenter.fndtn.dropdown', '[' + this.attr_name() + '], [' + this.attr_name() + '-content]', function (e) {
|
37
|
-
var $this = S(this),
|
38
|
-
dropdown,
|
39
|
-
target;
|
40
|
-
|
41
|
-
clearTimeout(self.timeout);
|
42
|
-
|
43
|
-
if ($this.data(self.data_attr())) {
|
44
|
-
dropdown = S('#' + $this.data(self.data_attr()));
|
45
|
-
target = $this;
|
46
|
-
} else {
|
47
|
-
dropdown = $this;
|
48
|
-
target = S("[" + self.attr_name() + "='" + dropdown.attr('id') + "']");
|
49
|
-
}
|
50
|
-
|
51
|
-
var settings = target.data(self.attr_name(true) + '-init') || self.settings;
|
52
|
-
|
53
|
-
if(S(e.target).data(self.data_attr()) && settings.is_hover) {
|
54
|
-
self.closeall.call(self);
|
55
|
-
}
|
56
|
-
|
57
|
-
if (settings.is_hover) self.open.apply(self, [dropdown, target]);
|
58
|
-
})
|
59
|
-
.on('mouseleave.fndtn.dropdown', '[' + this.attr_name() + '], [' + this.attr_name() + '-content]', function (e) {
|
60
|
-
var $this = S(this);
|
61
|
-
self.timeout = setTimeout(function () {
|
62
|
-
if ($this.data(self.data_attr())) {
|
63
|
-
var settings = $this.data(self.data_attr(true) + '-init') || self.settings;
|
64
|
-
if (settings.is_hover) self.close.call(self, S('#' + $this.data(self.data_attr())));
|
65
|
-
} else {
|
66
|
-
var target = S('[' + self.attr_name() + '="' + S(this).attr('id') + '"]'),
|
67
|
-
settings = target.data(self.attr_name(true) + '-init') || self.settings;
|
68
|
-
if (settings.is_hover) self.close.call(self, $this);
|
69
|
-
}
|
70
|
-
}.bind(this), 150);
|
71
|
-
})
|
72
|
-
.on('click.fndtn.dropdown', function (e) {
|
73
|
-
var parent = S(e.target).closest('[' + self.attr_name() + '-content]');
|
74
|
-
|
75
|
-
if (S(e.target).data(self.data_attr()) || S(e.target).parent().data(self.data_attr())) {
|
76
|
-
return;
|
77
|
-
}
|
78
|
-
if (!(S(e.target).data('revealId')) &&
|
79
|
-
(parent.length > 0 && (S(e.target).is('[' + self.attr_name() + '-content]') ||
|
80
|
-
$.contains(parent.first()[0], e.target)))) {
|
81
|
-
e.stopPropagation();
|
82
|
-
return;
|
83
|
-
}
|
84
|
-
|
85
|
-
self.close.call(self, S('[' + self.attr_name() + '-content]'));
|
86
|
-
})
|
87
|
-
.on('opened.fndtn.dropdown', '[' + self.attr_name() + '-content]', function () {
|
88
|
-
self.settings.opened.call(this);
|
89
|
-
})
|
90
|
-
.on('closed.fndtn.dropdown', '[' + self.attr_name() + '-content]', function () {
|
91
|
-
self.settings.closed.call(this);
|
92
|
-
});
|
93
|
-
|
94
|
-
S(window)
|
95
|
-
.off('.dropdown')
|
96
|
-
.on('resize.fndtn.dropdown', self.throttle(function () {
|
97
|
-
self.resize.call(self);
|
98
|
-
}, 50));
|
99
|
-
|
100
|
-
this.resize();
|
101
|
-
},
|
102
|
-
|
103
|
-
close: function (dropdown) {
|
104
|
-
var self = this;
|
105
|
-
dropdown.each(function () {
|
106
|
-
if (self.S(this).hasClass(self.settings.active_class)) {
|
107
|
-
self.S(this)
|
108
|
-
.css(Foundation.rtl ? 'right':'left', '-99999px')
|
109
|
-
.removeClass(self.settings.active_class)
|
110
|
-
.prev('[' + self.attr_name() + ']')
|
111
|
-
.removeClass(self.settings.active_class)
|
112
|
-
.removeData('target');
|
113
|
-
|
114
|
-
self.S(this).trigger('closed', [dropdown]);
|
115
|
-
}
|
116
|
-
});
|
117
|
-
},
|
118
|
-
|
119
|
-
closeall: function() {
|
120
|
-
var self = this;
|
121
|
-
$.each(self.S('[' + this.attr_name() + '-content]'), function() {
|
122
|
-
self.close.call(self, self.S(this))
|
123
|
-
});
|
124
|
-
},
|
125
|
-
|
126
|
-
open: function (dropdown, target) {
|
127
|
-
this
|
128
|
-
.css(dropdown
|
129
|
-
.addClass(this.settings.active_class), target);
|
130
|
-
dropdown.prev('[' + this.attr_name() + ']').addClass(this.settings.active_class);
|
131
|
-
dropdown.data('target', target.get(0)).trigger('opened', [dropdown, target]);
|
132
|
-
},
|
133
|
-
|
134
|
-
data_attr: function () {
|
135
|
-
if (this.namespace.length > 0) {
|
136
|
-
return this.namespace + '-' + this.name;
|
137
|
-
}
|
138
|
-
|
139
|
-
return this.name;
|
140
|
-
},
|
141
|
-
|
142
|
-
toggle : function (target) {
|
143
|
-
var dropdown = this.S('#' + target.data(this.data_attr()));
|
144
|
-
if (dropdown.length === 0) {
|
145
|
-
// No dropdown found, not continuing
|
146
|
-
return;
|
147
|
-
}
|
148
|
-
|
149
|
-
this.close.call(this, this.S('[' + this.attr_name() + '-content]').not(dropdown));
|
150
|
-
|
151
|
-
if (dropdown.hasClass(this.settings.active_class)) {
|
152
|
-
this.close.call(this, dropdown);
|
153
|
-
if (dropdown.data('target') !== target.get(0))
|
154
|
-
this.open.call(this, dropdown, target);
|
155
|
-
} else {
|
156
|
-
this.open.call(this, dropdown, target);
|
157
|
-
}
|
158
|
-
},
|
159
|
-
|
160
|
-
resize : function () {
|
161
|
-
var dropdown = this.S('[' + this.attr_name() + '-content].open'),
|
162
|
-
target = this.S("[" + this.attr_name() + "='" + dropdown.attr('id') + "']");
|
163
|
-
|
164
|
-
if (dropdown.length && target.length) {
|
165
|
-
this.css(dropdown, target);
|
166
|
-
}
|
167
|
-
},
|
168
|
-
|
169
|
-
css : function (dropdown, target) {
|
170
|
-
this.clear_idx();
|
171
|
-
|
172
|
-
if (this.small()) {
|
173
|
-
var p = this.dirs.bottom.call(dropdown, target);
|
174
|
-
|
175
|
-
dropdown.attr('style', '').removeClass('drop-left drop-right drop-top').css({
|
176
|
-
position : 'absolute',
|
177
|
-
width: '95%',
|
178
|
-
'max-width': 'none',
|
179
|
-
top: p.top
|
180
|
-
});
|
181
|
-
|
182
|
-
dropdown.css(Foundation.rtl ? 'right':'left', '2.5%');
|
183
|
-
} else {
|
184
|
-
var settings = target.data(this.attr_name(true) + '-init') || this.settings;
|
185
|
-
|
186
|
-
this.style(dropdown, target, settings);
|
187
|
-
}
|
188
|
-
|
189
|
-
return dropdown;
|
190
|
-
},
|
191
|
-
|
192
|
-
style : function (dropdown, target, settings) {
|
193
|
-
var css = $.extend({position: 'absolute'},
|
194
|
-
this.dirs[settings.align].call(dropdown, target, settings));
|
195
|
-
|
196
|
-
dropdown.attr('style', '').css(css);
|
197
|
-
},
|
198
|
-
|
199
|
-
// return CSS property object
|
200
|
-
// `this` is the dropdown
|
201
|
-
dirs : {
|
202
|
-
// Calculate target offset
|
203
|
-
_base : function (t) {
|
204
|
-
var o_p = this.offsetParent(),
|
205
|
-
o = o_p.offset(),
|
206
|
-
p = t.offset();
|
207
|
-
|
208
|
-
p.top -= o.top;
|
209
|
-
p.left -= o.left;
|
210
|
-
|
211
|
-
return p;
|
212
|
-
},
|
213
|
-
top: function (t, s) {
|
214
|
-
var self = Foundation.libs.dropdown,
|
215
|
-
p = self.dirs._base.call(this, t),
|
216
|
-
pip_offset_base = (t.outerWidth() / 2) - 8;
|
217
|
-
|
218
|
-
this.addClass('drop-top');
|
219
|
-
|
220
|
-
if (t.outerWidth() < this.outerWidth() || self.small()) {
|
221
|
-
self.adjust_pip(pip_offset_base, p);
|
222
|
-
}
|
223
|
-
|
224
|
-
if (Foundation.rtl) {
|
225
|
-
return {left: p.left - this.outerWidth() + t.outerWidth(),
|
226
|
-
top: p.top - this.outerHeight()};
|
227
|
-
}
|
228
|
-
|
229
|
-
return {left: p.left, top: p.top - this.outerHeight()};
|
230
|
-
},
|
231
|
-
bottom: function (t, s) {
|
232
|
-
var self = Foundation.libs.dropdown,
|
233
|
-
p = self.dirs._base.call(this, t),
|
234
|
-
pip_offset_base = (t.outerWidth() / 2) - 8;
|
235
|
-
|
236
|
-
if (t.outerWidth() < this.outerWidth() || self.small()) {
|
237
|
-
self.adjust_pip(pip_offset_base, p);
|
238
|
-
}
|
239
|
-
|
240
|
-
if (self.rtl) {
|
241
|
-
return {left: p.left - this.outerWidth() + t.outerWidth(), top: p.top + t.outerHeight()};
|
242
|
-
}
|
243
|
-
|
244
|
-
return {left: p.left, top: p.top + t.outerHeight()};
|
245
|
-
},
|
246
|
-
left: function (t, s) {
|
247
|
-
var p = Foundation.libs.dropdown.dirs._base.call(this, t);
|
248
|
-
|
249
|
-
this.addClass('drop-left');
|
250
|
-
|
251
|
-
return {left: p.left - this.outerWidth(), top: p.top};
|
252
|
-
},
|
253
|
-
right: function (t, s) {
|
254
|
-
var p = Foundation.libs.dropdown.dirs._base.call(this, t);
|
255
|
-
|
256
|
-
this.addClass('drop-right');
|
257
|
-
|
258
|
-
return {left: p.left + t.outerWidth(), top: p.top};
|
259
|
-
}
|
260
|
-
},
|
261
|
-
|
262
|
-
// Insert rule to style psuedo elements
|
263
|
-
adjust_pip : function (pip_offset_base, p) {
|
264
|
-
var sheet = Foundation.stylesheet;
|
265
|
-
|
266
|
-
if (this.small()) {
|
267
|
-
pip_offset_base += p.left - 8;
|
268
|
-
}
|
269
|
-
|
270
|
-
this.rule_idx = sheet.cssRules.length;
|
271
|
-
|
272
|
-
var sel_before = '.f-dropdown.open:before',
|
273
|
-
sel_after = '.f-dropdown.open:after',
|
274
|
-
css_before = 'left: ' + pip_offset_base + 'px;',
|
275
|
-
css_after = 'left: ' + (pip_offset_base - 1) + 'px;';
|
276
|
-
|
277
|
-
if (sheet.insertRule) {
|
278
|
-
sheet.insertRule([sel_before, '{', css_before, '}'].join(' '), this.rule_idx);
|
279
|
-
sheet.insertRule([sel_after, '{', css_after, '}'].join(' '), this.rule_idx + 1);
|
280
|
-
} else {
|
281
|
-
sheet.addRule(sel_before, css_before, this.rule_idx);
|
282
|
-
sheet.addRule(sel_after, css_after, this.rule_idx + 1);
|
283
|
-
}
|
284
|
-
},
|
285
|
-
|
286
|
-
// Remove old dropdown rule index
|
287
|
-
clear_idx : function () {
|
288
|
-
var sheet = Foundation.stylesheet;
|
289
|
-
|
290
|
-
if (this.rule_idx) {
|
291
|
-
sheet.deleteRule(this.rule_idx);
|
292
|
-
sheet.deleteRule(this.rule_idx);
|
293
|
-
delete this.rule_idx;
|
294
|
-
}
|
295
|
-
},
|
296
|
-
|
297
|
-
small : function () {
|
298
|
-
return matchMedia(Foundation.media_queries.small).matches &&
|
299
|
-
!matchMedia(Foundation.media_queries.medium).matches;
|
300
|
-
},
|
301
|
-
|
302
|
-
off: function () {
|
303
|
-
this.S(this.scope).off('.fndtn.dropdown');
|
304
|
-
this.S('html, body').off('.fndtn.dropdown');
|
305
|
-
this.S(window).off('.fndtn.dropdown');
|
306
|
-
this.S('[data-dropdown-content]').off('.fndtn.dropdown');
|
307
|
-
},
|
308
|
-
|
309
|
-
reflow : function () {}
|
310
|
-
};
|
311
|
-
}(jQuery, window, window.document));
|
@@ -1,74 +0,0 @@
|
|
1
|
-
;(function ($, window, document, undefined) {
|
2
|
-
'use strict';
|
3
|
-
|
4
|
-
Foundation.libs.equalizer = {
|
5
|
-
name : 'equalizer',
|
6
|
-
|
7
|
-
version : '5.2.3',
|
8
|
-
|
9
|
-
settings : {
|
10
|
-
use_tallest: true,
|
11
|
-
before_height_change: $.noop,
|
12
|
-
after_height_change: $.noop,
|
13
|
-
equalize_on_stack: false
|
14
|
-
},
|
15
|
-
|
16
|
-
init : function (scope, method, options) {
|
17
|
-
Foundation.inherit(this, 'image_loaded');
|
18
|
-
this.bindings(method, options);
|
19
|
-
this.reflow();
|
20
|
-
},
|
21
|
-
|
22
|
-
events : function () {
|
23
|
-
this.S(window).off('.equalizer').on('resize.fndtn.equalizer', function(e){
|
24
|
-
this.reflow();
|
25
|
-
}.bind(this));
|
26
|
-
},
|
27
|
-
|
28
|
-
equalize: function(equalizer) {
|
29
|
-
var isStacked = false,
|
30
|
-
vals = equalizer.find('[' + this.attr_name() + '-watch]:visible'),
|
31
|
-
settings = equalizer.data(this.attr_name(true)+'-init');
|
32
|
-
|
33
|
-
if (vals.length === 0) return;
|
34
|
-
var firstTopOffset = vals.first().offset().top;
|
35
|
-
settings.before_height_change();
|
36
|
-
equalizer.trigger('before-height-change');
|
37
|
-
vals.height('inherit');
|
38
|
-
vals.each(function(){
|
39
|
-
var el = $(this);
|
40
|
-
if (el.offset().top !== firstTopOffset) {
|
41
|
-
isStacked = true;
|
42
|
-
}
|
43
|
-
});
|
44
|
-
|
45
|
-
if (settings.equalize_on_stack === false) {
|
46
|
-
if (isStacked) return;
|
47
|
-
};
|
48
|
-
|
49
|
-
var heights = vals.map(function(){ return $(this).outerHeight(false) }).get();
|
50
|
-
|
51
|
-
if (settings.use_tallest) {
|
52
|
-
var max = Math.max.apply(null, heights);
|
53
|
-
vals.css('height', max);
|
54
|
-
} else {
|
55
|
-
var min = Math.min.apply(null, heights);
|
56
|
-
vals.css('height', min);
|
57
|
-
}
|
58
|
-
settings.after_height_change();
|
59
|
-
equalizer.trigger('after-height-change');
|
60
|
-
},
|
61
|
-
|
62
|
-
reflow : function () {
|
63
|
-
var self = this;
|
64
|
-
|
65
|
-
this.S('[' + this.attr_name() + ']', this.scope).each(function(){
|
66
|
-
var $eq_target = $(this);
|
67
|
-
self.image_loaded(self.S('img', this), function(){
|
68
|
-
self.equalize($eq_target)
|
69
|
-
});
|
70
|
-
});
|
71
|
-
}
|
72
|
-
};
|
73
|
-
})(jQuery, window, window.document);
|
74
|
-
|
@@ -1,331 +0,0 @@
|
|
1
|
-
;(function ($, window, document, undefined) {
|
2
|
-
'use strict';
|
3
|
-
|
4
|
-
Foundation.libs.interchange = {
|
5
|
-
name : 'interchange',
|
6
|
-
|
7
|
-
version : '5.2.3',
|
8
|
-
|
9
|
-
cache : {},
|
10
|
-
|
11
|
-
images_loaded : false,
|
12
|
-
nodes_loaded : false,
|
13
|
-
|
14
|
-
settings : {
|
15
|
-
load_attr : 'interchange',
|
16
|
-
|
17
|
-
named_queries : {
|
18
|
-
'default' : 'only screen',
|
19
|
-
small : Foundation.media_queries.small,
|
20
|
-
medium : Foundation.media_queries.medium,
|
21
|
-
large : Foundation.media_queries.large,
|
22
|
-
xlarge : Foundation.media_queries.xlarge,
|
23
|
-
xxlarge: Foundation.media_queries.xxlarge,
|
24
|
-
landscape : 'only screen and (orientation: landscape)',
|
25
|
-
portrait : 'only screen and (orientation: portrait)',
|
26
|
-
retina : 'only screen and (-webkit-min-device-pixel-ratio: 2),' +
|
27
|
-
'only screen and (min--moz-device-pixel-ratio: 2),' +
|
28
|
-
'only screen and (-o-min-device-pixel-ratio: 2/1),' +
|
29
|
-
'only screen and (min-device-pixel-ratio: 2),' +
|
30
|
-
'only screen and (min-resolution: 192dpi),' +
|
31
|
-
'only screen and (min-resolution: 2dppx)'
|
32
|
-
},
|
33
|
-
|
34
|
-
directives : {
|
35
|
-
replace: function (el, path, trigger) {
|
36
|
-
// The trigger argument, if called within the directive, fires
|
37
|
-
// an event named after the directive on the element, passing
|
38
|
-
// any parameters along to the event that you pass to trigger.
|
39
|
-
//
|
40
|
-
// ex. trigger(), trigger([a, b, c]), or trigger(a, b, c)
|
41
|
-
//
|
42
|
-
// This allows you to bind a callback like so:
|
43
|
-
// $('#interchangeContainer').on('replace', function (e, a, b, c) {
|
44
|
-
// console.log($(this).html(), a, b, c);
|
45
|
-
// });
|
46
|
-
|
47
|
-
if (/IMG/.test(el[0].nodeName)) {
|
48
|
-
var orig_path = el[0].src;
|
49
|
-
|
50
|
-
if (new RegExp(path, 'i').test(orig_path)) return;
|
51
|
-
|
52
|
-
el[0].src = path;
|
53
|
-
|
54
|
-
return trigger(el[0].src);
|
55
|
-
}
|
56
|
-
var last_path = el.data(this.data_attr + '-last-path');
|
57
|
-
|
58
|
-
if (last_path == path) return;
|
59
|
-
|
60
|
-
if (/\.(gif|jpg|jpeg|tiff|png)([?#].*)?/i.test(path)) {
|
61
|
-
$(el).css('background-image', 'url('+path+')');
|
62
|
-
el.data('interchange-last-path', path);
|
63
|
-
return trigger(path);
|
64
|
-
}
|
65
|
-
|
66
|
-
return $.get(path, function (response) {
|
67
|
-
el.html(response);
|
68
|
-
el.data(this.data_attr + '-last-path', path);
|
69
|
-
trigger();
|
70
|
-
});
|
71
|
-
|
72
|
-
}
|
73
|
-
}
|
74
|
-
},
|
75
|
-
|
76
|
-
init : function (scope, method, options) {
|
77
|
-
Foundation.inherit(this, 'throttle random_str');
|
78
|
-
|
79
|
-
this.data_attr = this.set_data_attr();
|
80
|
-
$.extend(true, this.settings, method, options);
|
81
|
-
this.bindings(method, options);
|
82
|
-
this.load('images');
|
83
|
-
this.load('nodes');
|
84
|
-
},
|
85
|
-
|
86
|
-
get_media_hash : function() {
|
87
|
-
var mediaHash='';
|
88
|
-
for (var queryName in this.settings.named_queries ) {
|
89
|
-
mediaHash += matchMedia(this.settings.named_queries[queryName]).matches.toString();
|
90
|
-
}
|
91
|
-
return mediaHash;
|
92
|
-
},
|
93
|
-
|
94
|
-
events : function () {
|
95
|
-
var self = this, prevMediaHash;
|
96
|
-
|
97
|
-
$(window)
|
98
|
-
.off('.interchange')
|
99
|
-
.on('resize.fndtn.interchange', self.throttle(function () {
|
100
|
-
var currMediaHash = self.get_media_hash();
|
101
|
-
if (currMediaHash !== prevMediaHash) {
|
102
|
-
self.resize();
|
103
|
-
}
|
104
|
-
prevMediaHash = currMediaHash;
|
105
|
-
}, 50));
|
106
|
-
|
107
|
-
return this;
|
108
|
-
},
|
109
|
-
|
110
|
-
resize : function () {
|
111
|
-
var cache = this.cache;
|
112
|
-
|
113
|
-
if(!this.images_loaded || !this.nodes_loaded) {
|
114
|
-
setTimeout($.proxy(this.resize, this), 50);
|
115
|
-
return;
|
116
|
-
}
|
117
|
-
|
118
|
-
for (var uuid in cache) {
|
119
|
-
if (cache.hasOwnProperty(uuid)) {
|
120
|
-
var passed = this.results(uuid, cache[uuid]);
|
121
|
-
|
122
|
-
if (passed) {
|
123
|
-
this.settings.directives[passed
|
124
|
-
.scenario[1]].call(this, passed.el, passed.scenario[0], function () {
|
125
|
-
if (arguments[0] instanceof Array) {
|
126
|
-
var args = arguments[0];
|
127
|
-
} else {
|
128
|
-
var args = Array.prototype.slice.call(arguments, 0);
|
129
|
-
}
|
130
|
-
|
131
|
-
passed.el.trigger(passed.scenario[1], args);
|
132
|
-
});
|
133
|
-
}
|
134
|
-
}
|
135
|
-
}
|
136
|
-
|
137
|
-
},
|
138
|
-
|
139
|
-
results : function (uuid, scenarios) {
|
140
|
-
var count = scenarios.length;
|
141
|
-
|
142
|
-
if (count > 0) {
|
143
|
-
var el = this.S('[' + this.add_namespace('data-uuid') + '="' + uuid + '"]');
|
144
|
-
|
145
|
-
while (count--) {
|
146
|
-
var mq, rule = scenarios[count][2];
|
147
|
-
if (this.settings.named_queries.hasOwnProperty(rule)) {
|
148
|
-
mq = matchMedia(this.settings.named_queries[rule]);
|
149
|
-
} else {
|
150
|
-
mq = matchMedia(rule);
|
151
|
-
}
|
152
|
-
if (mq.matches) {
|
153
|
-
return {el: el, scenario: scenarios[count]};
|
154
|
-
}
|
155
|
-
}
|
156
|
-
}
|
157
|
-
|
158
|
-
return false;
|
159
|
-
},
|
160
|
-
|
161
|
-
load : function (type, force_update) {
|
162
|
-
if (typeof this['cached_' + type] === 'undefined' || force_update) {
|
163
|
-
this['update_' + type]();
|
164
|
-
}
|
165
|
-
|
166
|
-
return this['cached_' + type];
|
167
|
-
},
|
168
|
-
|
169
|
-
update_images : function () {
|
170
|
-
var images = this.S('img[' + this.data_attr + ']'),
|
171
|
-
count = images.length,
|
172
|
-
i = count,
|
173
|
-
loaded_count = 0,
|
174
|
-
data_attr = this.data_attr;
|
175
|
-
|
176
|
-
this.cache = {};
|
177
|
-
this.cached_images = [];
|
178
|
-
this.images_loaded = (count === 0);
|
179
|
-
|
180
|
-
while (i--) {
|
181
|
-
loaded_count++;
|
182
|
-
if (images[i]) {
|
183
|
-
var str = images[i].getAttribute(data_attr) || '';
|
184
|
-
|
185
|
-
if (str.length > 0) {
|
186
|
-
this.cached_images.push(images[i]);
|
187
|
-
}
|
188
|
-
}
|
189
|
-
|
190
|
-
if (loaded_count === count) {
|
191
|
-
this.images_loaded = true;
|
192
|
-
this.enhance('images');
|
193
|
-
}
|
194
|
-
}
|
195
|
-
|
196
|
-
return this;
|
197
|
-
},
|
198
|
-
|
199
|
-
update_nodes : function () {
|
200
|
-
var nodes = this.S('[' + this.data_attr + ']').not('img'),
|
201
|
-
count = nodes.length,
|
202
|
-
i = count,
|
203
|
-
loaded_count = 0,
|
204
|
-
data_attr = this.data_attr;
|
205
|
-
|
206
|
-
this.cached_nodes = [];
|
207
|
-
this.nodes_loaded = (count === 0);
|
208
|
-
|
209
|
-
|
210
|
-
while (i--) {
|
211
|
-
loaded_count++;
|
212
|
-
var str = nodes[i].getAttribute(data_attr) || '';
|
213
|
-
|
214
|
-
if (str.length > 0) {
|
215
|
-
this.cached_nodes.push(nodes[i]);
|
216
|
-
}
|
217
|
-
|
218
|
-
if(loaded_count === count) {
|
219
|
-
this.nodes_loaded = true;
|
220
|
-
this.enhance('nodes');
|
221
|
-
}
|
222
|
-
}
|
223
|
-
|
224
|
-
return this;
|
225
|
-
},
|
226
|
-
|
227
|
-
enhance : function (type) {
|
228
|
-
var i = this['cached_' + type].length;
|
229
|
-
|
230
|
-
while (i--) {
|
231
|
-
this.object($(this['cached_' + type][i]));
|
232
|
-
}
|
233
|
-
|
234
|
-
return $(window).trigger('resize');
|
235
|
-
},
|
236
|
-
|
237
|
-
parse_params : function (path, directive, mq) {
|
238
|
-
return [this.trim(path), this.convert_directive(directive), this.trim(mq)];
|
239
|
-
},
|
240
|
-
|
241
|
-
convert_directive : function (directive) {
|
242
|
-
|
243
|
-
var trimmed = this.trim(directive);
|
244
|
-
|
245
|
-
if (trimmed.length > 0) {
|
246
|
-
return trimmed;
|
247
|
-
}
|
248
|
-
|
249
|
-
return 'replace';
|
250
|
-
},
|
251
|
-
|
252
|
-
object : function(el) {
|
253
|
-
var raw_arr = this.parse_data_attr(el),
|
254
|
-
scenarios = [],
|
255
|
-
i = raw_arr.length;
|
256
|
-
|
257
|
-
if (i > 0) {
|
258
|
-
while (i--) {
|
259
|
-
var split = raw_arr[i].split(/\((.*?)(\))$/);
|
260
|
-
|
261
|
-
if (split.length > 1) {
|
262
|
-
var cached_split = split[0].split(/\, /),
|
263
|
-
params = this.parse_params(cached_split[0],
|
264
|
-
cached_split[1], split[1]);
|
265
|
-
|
266
|
-
scenarios.push(params);
|
267
|
-
}
|
268
|
-
}
|
269
|
-
}
|
270
|
-
|
271
|
-
return this.store(el, scenarios);
|
272
|
-
},
|
273
|
-
|
274
|
-
store : function (el, scenarios) {
|
275
|
-
var uuid = this.random_str(),
|
276
|
-
current_uuid = el.data(this.add_namespace('uuid', true));
|
277
|
-
|
278
|
-
if (this.cache[current_uuid]) return this.cache[current_uuid];
|
279
|
-
|
280
|
-
el.attr(this.add_namespace('data-uuid'), uuid);
|
281
|
-
|
282
|
-
return this.cache[uuid] = scenarios;
|
283
|
-
},
|
284
|
-
|
285
|
-
trim : function(str) {
|
286
|
-
|
287
|
-
if (typeof str === 'string') {
|
288
|
-
return $.trim(str);
|
289
|
-
}
|
290
|
-
|
291
|
-
return str;
|
292
|
-
},
|
293
|
-
|
294
|
-
set_data_attr: function (init) {
|
295
|
-
if (init) {
|
296
|
-
if (this.namespace.length > 0) {
|
297
|
-
return this.namespace + '-' + this.settings.load_attr;
|
298
|
-
}
|
299
|
-
|
300
|
-
return this.settings.load_attr;
|
301
|
-
}
|
302
|
-
|
303
|
-
if (this.namespace.length > 0) {
|
304
|
-
return 'data-' + this.namespace + '-' + this.settings.load_attr;
|
305
|
-
}
|
306
|
-
|
307
|
-
return 'data-' + this.settings.load_attr;
|
308
|
-
},
|
309
|
-
|
310
|
-
parse_data_attr : function (el) {
|
311
|
-
var raw = el.attr(this.attr_name()).split(/\[(.*?)\]/),
|
312
|
-
i = raw.length,
|
313
|
-
output = [];
|
314
|
-
|
315
|
-
while (i--) {
|
316
|
-
if (raw[i].replace(/[\W\d]+/, '').length > 4) {
|
317
|
-
output.push(raw[i]);
|
318
|
-
}
|
319
|
-
}
|
320
|
-
|
321
|
-
return output;
|
322
|
-
},
|
323
|
-
|
324
|
-
reflow : function () {
|
325
|
-
this.load('images', true);
|
326
|
-
this.load('nodes', true);
|
327
|
-
}
|
328
|
-
|
329
|
-
};
|
330
|
-
|
331
|
-
}(jQuery, window, window.document));
|