This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* STICKY FILTERS | |
*/ | |
class StickyDomScroll { | |
constructor () { | |
this.selector = null | |
this.initialPosition = null | |
this.parentDiv = null | |
this.newElement = document.createElement('div') | |
this.initialPosition = null |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function() { | |
var timer = setTimeout(function() { | |
if (window.jQuery) { | |
clearTimeout(timer); | |
// Jquery code goes here | |
} | |
}, 50) | |
})(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* { | |
box-sizing: border-box; | |
} | |
html, body { | |
margin: 0; | |
} | |
@mixin animation() { | |
transition-duration: 0.5s; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.vid-player { | |
position: relative; | |
padding-bottom: 56.25%; | |
padding-top: 35px; | |
height: 0; | |
overflow: hidden; | |
} | |
.vid-player iframe { | |
position: absolute; | |
top:0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function resizeIframe() { | |
if ( $('iframe') ) { | |
var iframe = $('iframe'); | |
iframe.each(function(){ | |
var parent = $(this).parent(); | |
var ratio = $(this).attr('width') / $(this).attr('height'); | |
$(this).attr('width', parent.width()); | |
$(this).attr('height', parent.width()/ratio); | |
}); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div id="wrapper"> | |
<div class="row"> | |
<div class="col12"></div> | |
</div> | |
<div class="row"> | |
<div class="col6"></div> | |
<div class="col6"></div> | |
</div> | |
<div class="row"> | |
<div class="col4"></div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Custom PayPal Adaptive Payments args. | |
* | |
* @param array $args | |
* @param WC_Order $order | |
* @return array | |
*/ | |
function wc_adaptive_payment_custom_args( $args, $order ) { | |
$args['receiverList'] = array( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Return a product obj depending on field and value | |
* Authorised fields : term_id, name, slug | |
* @author Franck LEBAS | |
* @param string $field | |
* @param string $value | |
* @return obj, array or string $response | |
*/ | |
function wc_get_product_category($field, $value) { |
NewerOlder