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
body { background: #000; } | |
ul li a { text-decoration: none; color: #fff; font-size: 2rem; font-family: Avenir, sans-serif; text-transform: uppercase; } | |
ul li a:after, ul li a:before { opacity: 0; font-size: 1.5rem; position: relative; top: -.25rem; color: #f00; z-index: -2; } | |
ul li a:before { content: "<"; right: -2rem; } | |
ul li a:after { content: ">"; left: -2rem; } | |
ul li a:hover:before, ul li a:hover:after { opacity: 1; transition: .7s all linear; } | |
ul li a:hover:before { right: 0; } | |
ul li a:hover:after { left: 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 ticks(element) { | |
if (element.hasOwnProperty('list') && element.hasOwnProperty('min') && element.hasOwnProperty('max') && element.hasOwnProperty('step')) { | |
var datalist = document.createElement('datalist'), | |
minimum = parseInt(element.getAttribute('min')), | |
step = parseInt(element.getAttribute('step')), | |
maximum = parseInt(element.getAttribute('max')); | |
datalist.id = element.getAttribute('list'); | |
for (var i = minimum; i < maximum+step; i = i + step) { | |
datalist.innerHTML +="<option value="+i+"></option>"; | |
} |
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
// explanatory article: https://demosthenes.info/blog/993/1x-2x-3x-more-Batch-Processing-Retina-Images-with-PhotoShop-and-JavaScript | |
var inputFolder = Folder.selectDialog("Select a folder to process"), | |
outputFolder = Folder.selectDialog("Select a folder for the output files"), | |
imageSizes = [ | |
["250px", "250px", "1x"], | |
["125px", "125px", "icon-2x"], | |
["75px", "75px", "icon-1x"] | |
], | |
numImageSizes = imageSizes.length; |
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> | |
<title>World Map Example</title> | |
<style> | |
path {fill: lightgray; stroke: white;} | |
path:hover {fill: gray;} | |
</style> | |
</head> |