Skip to content

Instantly share code, notes, and snippets.

View dmcclintock's full-sized avatar

Daniel McClintock dmcclintock

View GitHub Profile
@dmcclintock
dmcclintock / Symantic-No-Skew-Single-Slant-CSS3-"Razorblade-Rectangles".markdown
Last active March 4, 2020 06:22
Single Slant CSS3 Divs - ("Responsive Razorblade Rectangles")

Single Slant CSS3 Divs - ("Responsive Razorblade Rectangles")

=============================================================== Fully responsive and cross-browser compatible rectangles with slanted edges using pseudo-elements (as supposed to the "skew" transform). In contrast with the skew alternative, the method employed does not cause the rectangles' skewed sides to affect containing elements (such as text), and has minimal impact on surrounding elements in terms of positioning. The code affords full use of other CSS3 styling techniques for additional customization, such as CSS styling, hover states, transitions, etc.

Free for all developers to use and pass along - share the <3

See it in action at TacoBarCompany.com.

To-Do:

@dmcclintock
dmcclintock / CustomSettings.json
Last active January 1, 2016 16:39
Sublime Text 3 - Custom User Settings
<dict>
<key>name</key>
<string>Text base</string>
<key>scope</key>
<string>text</string>
<key>settings</key>
<dict>
<key>background</key>
<string>#2c2f39</string>
@dmcclintock
dmcclintock / Dashboard alert for "Discourage Search Engines from indexing this site" WordPress option
Last active January 2, 2016 16:29
For the forgetful ones of you, such as myself, this little snippet will provide a constant reminder of the status of the "Discourage Search Engines from indexing this site" option in the WordPress settings.
<?php
/* ==========================================================================
A courtesy reminder that "discourage SE from indexing" is still checked
Place in your WordPress theme "functions.php" file or add as a plugin.
by Daniel McClintock (1/9/2014 @ 0100)
========================================================================== */
function seo_checker() {
$robotscheck = get_option( 'blog_public' );
@dmcclintock
dmcclintock / GravityFormsStarterStylesheet-SCSS
Last active August 29, 2015 13:56
SCSS Starter Stylesheet for Gravity Forms
/* ==========================================================================
Code: SCSS Starter Stylesheet for Gravity Forms
Gist URI: https://gist.github.com/danielsmcclintock/8997161 (on GitHub)
Version: 0.4.2
Author: Daniel McClintock
Author URI: http://about.me/McClintock
Notes:
This is coded for use in an SCSS file, using nested selectors
to limit the already-excruciating descendent selector hell,
@dmcclintock
dmcclintock / Main.sublime-menu
Last active August 29, 2015 13:56
Sublime Text custom pane layouts (commented with wireframe explaining coordinates for further customization). File should be named and placed in the following location to prevent being overwritten with future updates: "/~/Library/Application Support/Sublime Text 3/Packages/User/Main.sublime-menu".
[{
"id": "view",
"children": [{
"id": "layout",
"children": [{
"command": "set_layout",
"caption" : "3 col, bottom-right 2/3 row",
"mnemonic": "C",
"args": {
"cols": [0.0, 0.4, 0.74, 1.0],
<!-- Add to stylesheet: -->
span.amp {
font-family:Baskerville,"Goudy Old Style","Palatino","Book Antiqua",serif;
font-size:110%;
font-style:italic;
}
<!-- Wrap '&' with a span: -->
<span class="amp">&amp;</span>
@dmcclintock
dmcclintock / vertical-align-center.scss
Created October 16, 2014 11:06
CSS / SCSS Snippets
/*
* Vertical alignment center
* SRC: http://zerosixthree.se/vertical-align-anything-with-just-3-lines-of-css/
* Works in IE9
*/
// As a mixin
@mixin vertical-align {
position: relative;
top: 50%;
@dmcclintock
dmcclintock / maintenance-mode.php
Last active August 29, 2015 14:11
Quick Maintenance Mode snippet for WordPress theme
<?php
/*
* @author: Daniel McClintock
* @created: 12/2014
*
* NOTES:
* Add the following snippet directly after the opening <body> tag
* in your 'header.php' file.
*/
?>