Skip to content

Instantly share code, notes, and snippets.

@chillybin
chillybin / functions.php
Last active August 22, 2018 15:48
Emulating the Squarespace Mobile Menu Bar
<?php
add_action('genesis_after', 'cb_mobile_bar', 999);
function cb_mobile_bar() { ?>
<div class="mobile-bar">
<div class="mobile-bar-triggers">
<div class="mobile-bar-trigger" data-type="contactEmail">
<a href="mailto:[email protected]">
<span class="mobile-bar-trigger-icon"></span>
<span class="mobile-bar-trigger-label">Email</span>
</a>
@chillybin
chillybin / scripts.js
Created October 22, 2018 07:51
Ajax Load More
$("a.load-more").click(function(e){
loadArticle();
e.preventDefault();
});
function loadArticle() {
$("footer.infinite a").html("...");
var offset = $("a.load-more").data("count");
var num = parseInt(offset, 10);
var cat = $("a.load-more").data('cat');
$("footer.infinite a").click(function(e){
loadArticle();
e.preventDefault();
});
function loadArticle() {
$("footer.infinite a").html("...");
var offset = $("footer.infinite a").data("count");
var num = parseInt(offset, 10);
var cat = $("footer.infinite a").data('cat');
@chillybin
chillybin / chillybin-style.css
Last active March 29, 2019 00:07
ChillyBin Child Theme - Common Styles
body {
font-family: 'system-ui', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol';
}
/* Full Width Page
-------------------------------------------- */
.site-inner.full {
max-width: none;
padding: 0;