searchWiki.js

    @@ -93,7 +93,7 @@ * @param {Number} y マウスのY座標 */ function viewButton(x, y){ - var button, image, url; + var button, image, url, s; url = getHypertextReference(); if (!url) return; // 文字列を取得できなかった場合は実行しない @@ -105,30 +105,30 @@ button = document.createElement("a"); image = document.createElement("img"); + s = button.style; x += POSITION_GAP_X; y += POSITION_GAP_Y; button.id = ID_PREFIX + "button"; - (function setButtonStyle(s){ - s.display = "block"; - s.position = "absolute"; - s.left = x + "px"; - s.top = y + "px"; - s.padding = 0; - s.border = 0; - s.outline = 0; - s.lineHeight = "0"; - s.textDecoration = "none"; - s.opacity = .3; - s.transition = "200ms opacity ease"; - })(button.style); + s.display = "block"; + s.position = "absolute"; + s.left = x + "px"; + s.top = y + "px"; + s.padding = 0; + s.border = 0; + s.outline = 0; + s.lineHeight = "0"; + s.textDecoration = "none"; + s.opacity = .3; + s.transition = "200ms opacity ease"; + button.href = url; button.onmouseover = function(){ - button.style.opacity = "1"; + s.opacity = "1"; }; button.onmouseout = function(){ - button.style.opacity = ".3"; + s.opacity = ".3"; }; button.onblur = function(){ removeButton();
  • /**
     * @title searchWiki.js
     * @description Wikiやブログ等の検索システムのあるCMSで作られたコンテンツ内で文字列を選択したときに、その文字列でサイト内を検索するボタンを作ります。
     *              別ブラウザ向けの拡張として作った物をほぼ丸コピペです。
     * @include *
     * @license MIT License
     */
    
    // thanks for 商用利用可のWEB素材が無料な素材屋
    // http://ec-sozai.net/
    
    
    (function(global){
    	var ID_PREFIX = "UserExtension_searchWiki_",
    		POSITION_GAP_X = 16,
    		POSITION_GAP_Y = 16;
    	
    	var mouseDownFlag = false,
    		mouseDragFlag = false,
    		siteName = "",
    		selectedText = "";
    	
    	/**
    	 * テキストが選択されているかどうかを確認する
    	 * @returns	{Boolean}		選択されていたらtrue
    	 */
    	var checkSelection = function(){
    		selectedText = global.getSelection ? global.getSelection().toString()
    		: document.selection ? document.selection.createRange().text
    		: "";
    		return selectedText !== "";
    	}
    	
    	
    	// ecl.js 読み込み
    	loadEclJS();
    	
    	
    	// イベント登録
    	addEvent(document, "mousedown", function(){
    		mouseDownFlag = true;
    		mouseDragFlag = false;
    	});
    	addEvent(document, "mouseup", function(event){
    		var mousePos = null;
    		
    		// ドラッグされていたらテキストが選択されているかどうかを確認
    		if (mouseDragFlag && checkSelection()) {
    			mousePos = getMousePosition(event);
    			global.setTimeout(function(){
    				viewButton(mousePos.x, mousePos.y);
    			}, 0);
    		}
    		mouseDownFlag = false;
    		mouseDragFlag = false;
    	});
    	addEvent(document, "mousemove", function(){
    		if (mouseDownFlag) {
    			mouseDragFlag = true;
    		}
    		else {
    			mouseDragFlag = false;
    		}
    	});
    	addEvent(document, "dblclick", function(event){
    		var mousePos = null;
    		
    		if (checkSelection()) {
    			mousePos = getMousePosition(event);
    			global.setTimeout(function(){
    				viewButton(mousePos.x, mousePos.y);
    			}, 0);
    		}
    		mouseDragFlag = false;
    	});
    	
    	
    	/**
    	 * マウスの座標を取得する
    	 * @param	{Object}	event	イベントオブジェクト
    	 * @returns	{Object}			マウス座標
    	 */
    	function getMousePosition(event){
    		var pos = {};
    		pos.x = event.pageX || document.body.scrollLeft + event.clientX;
    		pos.y = event.pageY || document.body.scrollTop  + event.clientY;
    		return pos;
    	}
    	
    	/**
    	 * 検索ボタンを表示する
    	 * @param	{Number}	x	マウスのX座標
    	 * @param	{Number}	y	マウスのY座標
    	 */
    	function viewButton(x, y){
    		var button, image, url, s;
    		
    		url = getHypertextReference();
    		if (!url) return; // 文字列を取得できなかった場合は実行しない
    		
    		// ゴミが残っている場合は削除してから実行する
    		if (document.getElementById(ID_PREFIX + "button")) {
    			removeButton();
    		}
    		
    		button = document.createElement("a");
    		image  = document.createElement("img");
    		s = button.style;
    		
    		x += POSITION_GAP_X;
    		y += POSITION_GAP_Y;
    		
    		button.id = ID_PREFIX + "button";
    		s.display = "block";
    		s.position = "absolute";
    		s.left = x + "px";
    		s.top  = y + "px";
    		s.padding = 0;
    		s.border = 0;
    		s.outline = 0;
    		s.lineHeight = "0";
    		s.textDecoration = "none";
    		s.opacity = .3;
    		s.transition = "200ms opacity ease";
    		
    		button.href = url;
    		button.onmouseover = function(){
    			s.opacity = "1";
    		};
    		button.onmouseout = function(){
    			s.opacity = ".3";
    		};
    		button.onblur = function(){
    			removeButton();
    		}
    		
    		image.id  = ID_PREFIX + "image";
    		image.alt = "search";
    		image.title = "検索";
    		image.src = 'data:image/png;base64,'+
    'iVBORw0KGgoAAAANSUhEUgAAABsAAAAaCAYAAABGiCfwAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz'+
    'AAALEgAACxIB0t1+/AAAABZ0RVh0Q3JlYXRpb24gVGltZQAwMy8xOS8xMQFBmhAAAAAYdEVYdFNv'+
    'ZnR3YXJlAEFkb2JlIEZpcmV3b3Jrc0+zH04AAAKhSURBVEiJvZbNThNhFIafmWJbCnGItA6dJi5q'+
    'II2sbEkEpLATgkgicSNb0ivwDrwDNi4KJm7ENGBM4QrABDCBlA2GFUaEaac/gYIlpaUzLrRFIi2l'+
    'aX1X8805b57vzJzzzQiGYTDzdqYVeAOMAA7qq2/Au8BU4LXwB/YemARwuVx1JR0cHBQvXwnB2eAd'+
    'IA6YXC7X38F6a1MEWv8DCMDRVG2m1WrFYXdQ0AskEgny+fyNadfCnB1O/AN+JEm6dD+mxVj5vEI6'+
    'na4aJlYK+rw+xp6OIUkS2WyW/f191KhKPp+nQ+5g4vkEXZ1dVcPKVuZ2u/E+9AIQ2YqwsblxsUNR'+
    'xD/gp6uzi0H/IOl0Gi2u1VaZIAj0PuoFYHVt9RIIQNd1lleW2dnZQRAEfF5fFXWVgcl3ZVpsLWia'+
    'xvbX7bLmtfU1ABRFwWKx1AYrNsNR+qii+bxwjhpVEQSB9vb22mCN0pWwYju3SW0VzU2mJhSngmEY'+
    'pFKp2mBaXCNzmkGWZbofdJc19/X2AaCqKmdnZ7XBDMNg/cs6AP19/fgf+y+bRJGhwSE8Hg8AUS16'+
    'LQgqzNnu7i7SbQmf14fH48F9300ymcQkmnA4HIjixT57vD2kkin2fuzdvLKiIlsRwkthUqkU5ltm'+
    'FKeCLMuIooiqqoSXwqXc4SfDKIpSESYEZ4P3gO/Xnfpmsxm73Y5e0Ikn4ui6DkCLrYXJl5OlvMWl'+
    'xXKnyV7VrZ/L5VBVlZgWK4EAMqcZ5j7Mldbjz8bLzlxd5ixzmiE0HyqtR0dGsTXbGgMDOD4+ZuHj'+
    'AtlsFqvVSrOt+Z+cqj+e1ejw6JDQfAiLxcLJyUljYfD73eZyuStjIhADcg3+/wBIiIGpQA4INpoE'+
    'TBcf4yvgAHjRAMhPYDowFfj0C3Y89OFebIQWAAAAAElFTkSuQmCC';
    		
    		button.appendChild(image);
    		document.body.appendChild(button);
    		button.focus();
    	}
    	/**
    	 * 検索ボタンを削除する
    	 */
    	function removeButton() {
    		var button = document.getElementById(ID_PREFIX + "button");
    		if (button) {
    			document.body.removeChild(button);
    		}
    	}
    	/**
    	 * 現在閲覧中のサイトのタイプを検出する
    	 * @param	{String}	hostname	ドメイン
    	 * @returns	{String}				サイトのID
    	 */
    	function getSiteName(hostname){
    		if (hostname) {
    			// Wikipedia
    			if (/wikipedia\.org$/.test(hostname)) {
    				return "wikipedia";
    			}
    			// @wiki
    			else if (/atwiki\.jp$/.test(hostname)) {
    				return "@wiki";
    			}
    			// FC2 WIKI
    			else if (/wiki\.fc2\.com$/.test(hostname)) {
    				return "fc2Wiki";
    			}
    			// WIKIWIKI
    			else if (hostname === "wikiwiki.jp") {
    				return "wikiwiki";
    			}
    			// Seesaa Wiki
    			else if (hostname === "w.livedoor.jp" || hostname === "wiki.livedoor.jp") {
    				return "seesaaWiki";
    			}
    			
    			// アメブロ
    			else if (hostname === "ameblo.jp") {
    				return "ameblo";
    			}
    			// Livedoor Blog
    			else if (!!global.ld_blog_vars) {
    				return "livedoorBlog";
    			}
    			// JUGEM
    			else if (/jugem\.jp$/.test(hostname)) {
    				return "jugem";
    			}
    			// FC2ブログ
    			else if (/blog\d*?\.fc2\.com$/.test(hostname)) {
    				return "fc2Blog";
    			}
    			// はてなダイアリー
    			else if (!!global.Hatena &&
    					 !!Hatena.Diary &&
    					 Hatena.Diary.BaseURL === "http://d.hatena.ne.jp/") {
    				return "hatenaDiary";
    			}
    			// はてなブログ
    			else if (!!global.Hatena &&
    					 !!Hatena.Diary &&
    					 !!Hatena.Diary.AppAPI) {
    				return "hatenaBlog";
    			}
    			
    			// はてなキーワード
    			else if (!!global.Hatena &&
    					 !!Hatena.Keyword) {
    				return "hatenaKeyword";
    			}
    			// Mozilla Developer Network
    			else if (hostname === "developer.mozilla.org") {
    				return "mdn";
    			}
    		}
    		return "";
    	}
    	/**
    	 * 検索ボタンで遷移する先のURLを返す
    	 * @returns	{String}		URL
    	 */
    	function getHypertextReference(){
    		
    		var hostname = global.location.hostname,
    			text = encode(selectedText);
    		
    		siteName = siteName || getSiteName(hostname);
    		
    		switch (siteName) {
    			case "wikipedia":
    				return "/w/index.php?search=" + text;
    			case "@wiki":
    				return "?cmd=search&keyword=" + text;
    			case "fc2Wiki":
    				return "/?cmd=search&q=" + text;
    			case "wikiwiki":
    				return "?encode_hint=%A4%D7&cmd=search&word=" + text;
    			case "seesaaWiki":
    				return "/" + global.location.pathname.split("/")[1] + "/search?keywords=" + text;
    			
    			case "ameblo":
    				return "http://search.ameba.jp/search.html?q=" + text + "&aid=" + global.location.pathname.split("/")[1];
    			case "livedoorBlog":
    				return "/" + (hostname === "blog.livedoor.jp"
    					? (global.location.pathname.split("/")[1] + "/")
    					: "") + "search?q=" + text;
    			case "jugem":
    				return "/?search=" + text;
    			case "fc2Blog":
    				return "/?q=" + text;
    			case "hatenaDiary":
    				return "/" + global.location.pathname.split("/")[1] + "/searchdiary?word=" + text;
    			case "hatenaBlog":
    				return "/search?q=" + text;
    			
    			case "hatenaKeyword":
    				return "http://search.hatena.ne.jp/search?word=" + text;
    			case "mdn":
    				return "/ja/search?q=" + text;
    			
    			// いずれにも該当しない場合はとりあえずGoogleとかBingとかで検索
    			default:
    				//return "http://www.google.co.jp/search?q=" +
    				//	encodeURIComponent(selectedText) + "+site%3A" + hostname;
    				return "http://www.bing.com/search?q=" +
    					encodeURIComponent(selectedText) + "+site%3A" + hostname;
    		}
    	}
    	
    	/**
    	 * encodeTypeを元に文字列をURLエンコードする
    	 * @param	{String}	string	変換させる文字列
    	 * @returns	{String}			変換された文字列
    	 */
    	function encode(string){
    		var charset = document.characterSet || document.charset;
    		
    		switch(charset.toLowerCase()) {
    			case "euc-jp":
    				return EscapeEUCJP(string);
    			case "shift_jis":
    				return EscapeSJIS(string);
    			case "utf-8":
    			default:
    				return encodeURIComponent(string);
    		}
    	}
    	
    	/**
    	 * DOMオブジェクトにイベントを追加する
    	 * @param	{Object}	target		イベントを適用するオブジェクト
    	 * @param	{Object}	eventType	イベントオブジェクト
    	 * @param	{Function}	func		実行する関数
    	 */
    	function addEvent(target, eventType, func){
    		if (target.addEventListener) {
    			target.addEventListener(eventType, func, false);
    		}
    		else if (target.attachEvent) {
    			target.attachEvent("on" + eventType, func);
    		}
    		else if (typeof target["on" + eventType] === "object") {
    			target["on" + eventType] = func;
    		}
    	}
    	
    	//
    	// Escape Codec Library: ecl.js (Ver.041208)
    	//
    	// Copyright (C) http://nurucom-archives.hp.infoseek.co.jp/digital/
    	//
    	function loadEclJS(){
    		var JCT11280=Function('var a="zKV33~jZ4zN=~ji36XazM93y!{~k2y!o~k0ZlW6zN?3Wz3W?{EKzK[33[`y|;-~j^YOTz$!~kNy|L1$353~jV3zKk3~k-4P4zK_2+~jY4y!xYHR~jlz$_~jk4z$e3X5He<0y!wy|X3[:~l|VU[F3VZ056Hy!nz/m1XD61+1XY1E1=1y|bzKiz!H034zKj~mEz#c5ZA3-3X$1~mBz$$3~lyz#,4YN5~mEz#{ZKZ3V%7Y}!J3X-YEX_J(3~mAz =V;kE0/y|F3y!}~m>z/U~mI~j_2+~mA~jp2;~m@~k32;~m>V}2u~mEX#2x~mBy+x2242(~mBy,;2242(~may->2&XkG2;~mIy-_2&NXd2;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%<D:0;YRXY973H5)-4FXOYf0:0;/7759774;7;:/855:543L43<?6=E,.A4:C=L)%4YV!1(YE/4YF+ F3%;S;&JC:%/?YEXJ4GXf/YS-EXEYW,9;E}X$}547EXiK=51-?71C%?57;5>463553Zg90;6447?<>4:9.7538XgN{|!}9K/E&3-:D+YE1)YE/3;37/:05}n<}:UX8Yj4Yt864@JYK..G=.(A Q3%6K>3(P3#AYE$-6H/456*C=.XHY[#S.<780191;057C)=6HXj?955B:K1 E>-B/9,;5.!L?:0>/.@//:;7833YZ56<4:YE=/:7Z_WGC%3I6>XkC*&NA16X=Yz2$X:Y^&J48<99k8}CyB-61<18K946YO4{|N}E)YIB9K0L>4=46<1K0+R;6-=1883:478;4,S+3YJX`GJXh.Yp+Xm6MXcYpX(>7Yo,/:X=Z;Xi0YTYHXjYmXiXj;*;I-8S6N#XgY}.3XfYGO3C/$XjL$*NYX,1 6;YH&<XkK9C#I74.>}Hd`A748X[T450[n75<4439:18A107>|ET}Rf<1;14876/Yb983E<5.YNXd4149>,S=/4E/<306443G/06}0&}UkYSXFYF=44=-5095=88;63844,9E6644{PL}WA8:>)7+>763>>0/B3A545CCnT}Xm|dv}Xq1L/YNXk/H8;;.R63351YY747@15YE4J8;46;.38.>4A369.=-83,;Ye3?:3@YE.4-+N353;/;@(X[YYD>@/05-I*@.:551741Yf5>6A443<3535;.58/86=D4753442$635D1>0359NQ @73:3:>><Xn?;43C14 ?Y|X611YG1&<+,4<*,YLXl<1/AIXjF*N89A4Z576K1XbJ5YF.ZOWN.YGXO/YQ01:4G38Xl1;KI0YFXB=R<7;D/,/4>;$I,YGXm94@O35Yz66695385.>:6A#5}W7n^4336:4157597434433<3|XA}m`>=D>:4A.337370?-6Q96{`E|4A}C`|Qs{Mk|J+~r>|o,wHv>Vw}!c{H!|Gb|*Ca5}J||,U{t+{CN[!M65YXOY_*B,Y[Z9XaX[QYJYLXPYuZ%XcZ8LY[SYPYKZM<LMYG9OYqSQYM~[e{UJXmQYyZM_)>YjN1~[f3{aXFY|Yk:48YdH^NZ0|T){jVFYTZNFY^YTYN~[h{nPYMYn3I]`EYUYsYIZEYJ7Yw)YnXPQYH+Z.ZAZY]^Z1Y`YSZFZyGYHXLYG 8Yd#4~[i|+)YH9D?Y^F~Y7|-eYxZ^WHYdYfZQ~[j|3>~[k|3oYmYqY^XYYO=Z*4[]Z/OYLXhZ1YLZIXgYIHYEYK,<Y`YEXIGZI[3YOYcB4SZ!YHZ*&Y{Xi3~[l|JSY`Zz?Z,~[m|O=Yi>??XnYWXmYS617YVYIHZ(Z4[~L4/=~[n|Yu{P)|];YOHHZ}~[o33|a>~[r|aE]DH~[s|e$Zz~[t|kZFY~XhYXZB[`Y}~[u|{SZ&OYkYQYuZ2Zf8D~[v}% ~[w3},Q[X]+YGYeYPIS~[y}4aZ!YN^!6PZ*~[z}?E~[{3}CnZ=~[}}EdDZz/9A3(3S<,YR8.D=*XgYPYcXN3Z5 4)~[~}JW=$Yu.XX~] }KDX`PXdZ4XfYpTJLY[F5]X~[2Yp}U+DZJ::<446[m@~]#3}]1~]%}^LZwZQ5Z`/OT<Yh^ -~]&}jx[ ~m<z!%2+~ly4VY-~o>}p62yz!%2+Xf2+~ly4VY-zQ`z (=] 2z~o2",C={" ":0,"!":1},c=34,i=2,p,s="",u=String.fromCharCode,t=u(12539);while(++c<127)C[u(c)]=c^39&&c^92?i++:0;i=0;while(0<=(c=C[a.charAt(i++)]))if(16==c)if((c=C[a.charAt(i++)])<87){if(86==c)c=1879;while(c--)s+=u(++p)}else s+=s.substr(8272,360);else if(c<86)s+=u(p+=c<51?c-16:(c-55)*92+C[a.charAt(i++)]);else if((c=((c-86)*92+C[a.charAt(i++)])*92+C[a.charAt(i++)])<49152)s+=u(p=c<40960?c:c|57344);else{c&=511;while(c--)s+=t;p=12539}return s')();
    		var JCT8836=JCT11280.substring(0,8836);
    		
    		global.EscapeSJIS=function(str){
    			return str.replace(/[^*+.-9A-Z_a-z-]/g,function(s){
    				var c=s.charCodeAt(0),m;
    				return c<128?(c<16?"%0":"%")+c.toString(16).toUpperCase():65376<c&&c<65440?"%"+(c-65216).toString(16).toUpperCase():(c=JCT11280.indexOf(s))<0?"%81E":"%"+((m=((c<8272?c:(c=JCT11280.lastIndexOf(s)))-(c%=188))/188)<31?m+129:m+193).toString(16).toUpperCase()+(64<(c+=c<63?64:65)&&c<91||95==c||96<c&&c<123?String.fromCharCode(c):"%"+c.toString(16).toUpperCase())
    			})
    		};
    		global.EscapeEUCJP=function(str){
    			return str.replace(/[^*+.-9A-Z_a-z-]/g,function(s){
    				var c=s.charCodeAt(0);
    				return (c<128?(c<16?"%0":"%")+c.toString(16):65376<c&&c<65440?"%8E%"+(c-65216).toString(16):(c=JCT8836.indexOf(s))<0?"%A1%A6":"%"+((c-(c%=94))/94+161).toString(16)+"%"+(c+161).toString(16)).toUpperCase()
    			})
    		};
    	}
    })(window);
    
  • Permalink
    このページへの個別リンクです。
    RAW
    書かれたコードへの直接のリンクです。
    Packed
    文字列が圧縮された書かれたコードへのリンクです。
    Userscript
    Greasemonkey 等で利用する場合の .user.js へのリンクです。
    Loader
    @require やソースコードが長い場合に多段ロードする Loader コミのコードへのリンクです。
    Metadata
    コード中にコメントで @xxx と書かれたメタデータの JSON です。

History

  1. 2013/12/08 00:24:53 - 2013-12-08
  2. 2013/12/08 00:11:37 - 2013-12-08
  3. 2013/12/08 00:11:18 - 2013-12-08