Skip to content

Instantly share code, notes, and snippets.

Geoffrey Crofte geoffreycrofte

Block or report user

Report or block geoffreycrofte

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@geoffreycrofte
geoffreycrofte / dabblet.css
Created May 31, 2012
Only first letter in uppercase
View dabblet.css
/*
* Only first letter in uppercase
*/
/* all in lowercase */
.transform li {
text-transform: lowercase;
}
/* first-letter in uppercase */
@geoffreycrofte
geoffreycrofte / dabblet.css
Created Jun 1, 2012
Only first letter in uppercase
View dabblet.css
/*
* Only first letter in uppercase
*/
/* all in lowercase */
.transform li {
text-transform: lowercase;
}
/* first-letter in uppercase */
@geoffreycrofte
geoffreycrofte / dabblet.css
Created Jun 5, 2012
Bug fix for Chrome attribute selector
View dabblet.css
/**
Bug fix for Chrome attribute selector
A @goetter bug report
*/
a {
display: block;
margin-top: 6px;
color: #000;
text-decoration: none;
}
@geoffreycrofte
geoffreycrofte / dabblet.css
Created Sep 13, 2012
Feuilles superposées
View dabblet.css
/**
* Feuilles superposées
*/
/* Petite mise en page */
body {
width: 375px;
margin: 20px auto;
font-family: helvetica, arial, sans-serif;
color: #444;
View dabblet.css
/**
* "Isometric" shadow
*/
div {
position: relative;
width: 250px;
height: 200px;
background: #7799ff;
box-shadow: 10px 10px 0 #3355bb;
@geoffreycrofte
geoffreycrofte / dabblet.css
Created Sep 24, 2012
Rating with float right or direction rtl properties
View dabblet.css
/**
* Rating with float right or direction rtl properties
*/
h1 {
text-align: center;
font-family: Helvetica, Arial;
font-weight: normal;
color: #777;
font-size: 1.3em;
clear: both;
@geoffreycrofte
geoffreycrofte / dabblet.css
Created Sep 27, 2012
Rating with float right or direction rtl properties
View dabblet.css
/**
* Rating with float right or direction rtl properties
*/
h1 {
text-align: center;
font-family: Helvetica, Arial;
font-weight: normal;
color: #777;
font-size: 1.3em;
clear: both;
@geoffreycrofte
geoffreycrofte / functions.php
Last active Jul 6, 2016 — forked from stephanie-walter/gist:5014232
Add a Branch shortcode to WordPress
View functions.php
// Adds [branch id="" noscript="branch-url"] shortcode in WordPress
if ( ! function_exists( 'branch_embedded' ) ) {
function branch_embedded( $atts ) {
$atts = shortcode_atts( array( 'id' => '', noscript=> '' ), $atts );
$output = '<script type="text/javascript" src="http://embed-script.branch.com/assets/embed/embed.m.js?body=0" data-branch-embedid="' . esc_attr( $atts['id'] ) . '" ></script>';
@geoffreycrofte
geoffreycrofte / child-functions.php
Created May 30, 2014
Translation for a WordPress Child Theme
View child-functions.php
<?php
/*
CHILD THEME functions.php file
*/
if ( !function_exists('child_localization')) {
function child_localization() {
load_child_theme_textdomain('child_text_domain', get_stylesheet_directory() . '/lang');
}
add_action('after_setup_theme', 'child_localization');
}
@geoffreycrofte
geoffreycrofte / counting-in-css.css
Last active Aug 8, 2018
A way to apply styles depending on number of elements
View counting-in-css.css
li:only-of-type {
width: 100%;
}
/* if 2 <ul> childs */
li:nth-last-child(2):first-child,
li:nth-last-child(2):first-child ~ li {
width: 50%;
}
You can’t perform that action at this time.