Last active
August 29, 2015 13:56
-
-
Save syusui-s/9108854 to your computer and use it in GitHub Desktop.
動くかまだ試してない
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 Google Image Tab Before Style | |
// @namespace GoogleImgTabBeforeStyle | |
// @description Googleの画像タブの位置を以前の位置へ移動する | |
// @include /^https:\/\/.*google\..*\/.*&q=.*$/ | |
// ==/UserScript== | |
function imgNode(nodes) { | |
for (var i = 0; i < nodes.length; ++i) { | |
if (nodes[i].innerText == '画像') return nodes[i]; | |
} | |
return false; | |
} | |
var node = imgNode(document.getElementsByClassName('hdtb_mitem')); | |
var menu = document.getElementById('hdtb_msb'); | |
menu.removeChild(node); | |
menu.insertBefore(node, menu.childNodes[1]); | |
console.log("test"); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment