1
0
mirror of https://github.com/Hutchy68/pivot.git synced 2025-12-19 15:27:03 +01:00

Making Font Awesome 'preload' a feature as this does not effect everyone. Absolute latest Foundation 5 js from their repo to fix all JQMigrate warnings.

This commit is contained in:
Tom Hutchison
2018-02-15 12:42:07 -05:00
parent 52aecafbc9
commit 65964dc883
18 changed files with 147 additions and 85 deletions

View File

@@ -6,7 +6,7 @@
Foundation.libs.reveal = {
name : 'reveal',
version : '5.5.3',
version : '{{VERSION}}',
locked : false,
@@ -19,6 +19,7 @@
multiple_opened : false,
bg_class : 'reveal-modal-bg',
root_element : 'body',
no_scroll: false,
open : function(){},
opened : function(){},
close : function(){},
@@ -49,7 +50,7 @@
S = self.S;
S(this.scope)
.off('.reveal')
.off('.fndtn.reveal')
.on('click.fndtn.reveal', '[' + this.add_namespace('data-reveal-id') + ']:not([disabled])', function (e) {
e.preventDefault();
@@ -171,6 +172,14 @@
modal.attr('tabindex','0').attr('aria-hidden','false');
if(settings.no_scroll){//added 10/9/15, prevents annoying scroll positioning bug with position: absolute; reveals
var $body = $('body');
$body.on('open.fndtn.reveal', function(){
$body.css('overflow', 'hidden')
.off('open.fndtn.reveal');
});
}
this.key_up_on(modal); // PATCH #3: turning on key up capture only when a reveal window is open
// Prevent namespace event from triggering twice
@@ -178,7 +187,8 @@
if (e.namespace !== 'fndtn.reveal') return;
});
modal.on('open.fndtn.reveal').trigger('open.fndtn.reveal');
modal.trigger('open.fndtn.reveal');
if (open_modal.length < 1) {
this.toggle_bg(modal, true);
@@ -256,6 +266,14 @@
modal.removeAttr('tabindex','0').attr('aria-hidden','true');
if(settings.no_scroll){//added 10/9/15, prevents annoying scroll positioning bug with position: absolute; reveals
var $body = $('body');
$body.on('close.fndtn.reveal', function(){
$body.css('overflow', 'auto')
.off('close.fndtn.reveal');
});
}
this.locked = true;
this.key_up_off(modal); // PATCH #3: turning on key up capture only when a reveal window is open