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 getOffset( el ) { | |
var _y = 0; | |
while( el && !isNaN( el.offsetTop ) ) { | |
_y += el.offsetTop - el.scrollTop; | |
el = el.offsetParent; | |
} | |
return { top: _y }; | |
} | |
if ( getOffset( document.querySelector('.section-5') ).top <= window.scrollY && (getOffset( document.querySelector('.section-5') ).top + document.querySelector('.section-5').clientHeight) >= window.scrollY) { |
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
[alias] | |
co = checkout | |
ci = commit | |
st = status | |
br = branch | |
hist = log --pretty=format:\"%h %ad | %s%d [%an]\" --graph --date=short | |
type = cat-file -t | |
dump = cat-file -p | |
show-tree = log --oneline --graph --color --all --decorate | |
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
// ==UserScript== | |
// @name Shoutbox New Message Sound | |
// @version 0.1 | |
// @description Play a sound when someone sends a message in the shoutbox | |
// @match http://mg-s.us/mybb/* | |
// @grant none | |
// ==/UserScript== | |
(function() { | |
'use strict'; |
NewerOlder