If you use Sass extension, you can work with CSS variables.
First, let's create our css variable.
\:root
--MyColor: #5966D2
// WordPress hook call stack debug: | |
$debug = debug_backtrace(); | |
foreach($debug as $item){ | |
echo $item['file'] .':' .$item['line'] .' - '.$item['function'].'()' ."\n"; | |
if(!empty($item['args']) && is_array($item['args']) && isset($item['args'][1]) && is_string($item['args'][1])){ | |
echo ' --- '. $item['args'][1] ."\n"; | |
} | |
} |
<img srcset="image-320w.jpg 320w, | |
image-480w.jpg 480w, | |
image-800w.jpg 800w" | |
sizes="(max-width: 320px) 300px, | |
(max-width: 480px) 440px, | |
800px" | |
src="image-800w.jpg" alt="Image"> |
import React from "react"; | |
import ReactDOM from "react-dom"; | |
import { fromPairs, map, pick } from "ramda"; | |
/** | |
* Wraps a React component into Angular component. Returns a new Angular component. | |
* | |
* Usage: angular.module('some.module').component('newAngularComponent', react2angular(MyReactComponent)) | |
* (the usage is the same as in similar lib https://github.com/coatue-oss/react2angular) | |
*/ |
// ---- | |
// Sass (v3.4.21) | |
// Compass (v1.0.3) | |
// ---- | |
$font-name: 'GT-Walsheim'; | |
$font-path: '../fonts/'; | |
$weights: ( | |
400 'Regular', |
Minimalist skin for Video.js. Can be modified to make custom skins.
The great thing about Video.js skins is they work in both HTML5 video AND Flash!
A Pen by Juan D. Jara on CodePen.
/* | |
See: https://www.smashingmagazine.com/2016/05/fluid-typography/ | |
1. without support for anything, the font size will be the minimum font-size (14px) so nothing will break. | |
2. with support for mediaqueries and not vw or calc or both then the font will jump up a pixel size at every appropriate breakpoint (I'm using http://include-media.com for syntactic-sugar, but you could rewrite without this) | |
3. with support for mediaqueries and calc and vw it will work as the article describes, with the fixes for older Safari and IE too | |
Ain't it pretty!? Haha - works well tho :) | |
*/ |
/** | |
* Detects if two elements are colliding | |
* | |
* Credit goes to BC on Stack Overflow, cleaned up a little bit | |
* | |
* @link http://stackoverflow.com/questions/5419134/how-to-detect-if-two-divs-touch-with-jquery | |
* @param $div1 | |
* @param $div2 | |
* @returns {boolean} | |
*/ |
Simple Feature Detection Library to check JS, SVG and Touch support. Replaces no-js class on html element with js, adds no-svg if no support for SVG and touch or no-touch depending on the used device.
// ---- | |
// Sass (v3.4.12) | |
// Compass (v1.0.3) | |
// ---- | |
$baseSize: 16px; | |
$convertBase: $baseSize; | |
html { | |
font-size: percentage($baseSize / 16px); |