Skip to content

Instantly share code, notes, and snippets.

View hisasann's full-sized avatar
🔖
I aspire to become a bookseller.

Yoshiyuki Hisamatsu hisasann

🔖
I aspire to become a bookseller.
View GitHub Profile
@hisasann
hisasann / ZeroClipboard-sample.coffee
Created December 2, 2014 06:37
ZeroClipboardを使った場合のサンプル
# コピーボタン
copy = document.querySelector '#copy'
clip = new ZeroClipboard(copy)
clip.on 'ready', ->
lo.l 'ready'
clip.on 'beforecopy', (e) ->
lo.l 'beforecopy'
copy.dataset.clipboardText = '上書きしちゃったー'
var NewComponent = React.createClass({
render: function() {
return (
<div>
{/* Hello world */}
<div className="awesome" style={{border: '1px solid red'}}>
<label htmlFor="name">Enter your name: </label>
<input type="text" id="name" />
</div>
<p>Enter your HTML here</p>
javascript:var ret=window.prompt('このページへのリンク','[document.title](location.href)');
var synthes = new SpeechSynthesisUtterance(
'うんこうんこうんこっこ'
);
synthes.lang = "ja-JP"
speechSynthesis.speak( synthes );
open "/Applications/Google Chrome.app" --args --kiosk --disable-background-mode "http://hisasann.com/" --user-data-dir=/Users/[UserName]/Library/Application\ Support/Google/Chrome/kioskmode
(function($){
$.fn.getRelativeOffset = function(name){
var elem = this[0],
top = 0,
left = 0;
// require relative
if($(name).css("position") != "relative")
$(name).css("position", "relative")
import java.io.IOException;
import twitter4j.Status;
import twitter4j.Twitter;
import twitter4j.TwitterException;
import wiiremotej.WiiRemote;
import wiiremotej.WiiRemoteJ;
import wiiremotej.event.WRButtonEvent;
import wiiremotej.event.WRIREvent;
import wiiremotej.event.WiiRemoteAdapter;
import java.io.IOException;
import javax.sound.sampled.AudioInputStream;
import javax.sound.sampled.AudioSystem;
import javax.sound.sampled.UnsupportedAudioFileException;
import wiiremotej.PrebufferedSound;
import wiiremotej.WiiRemote;
import wiiremotej.WiiRemoteJ;
import wiiremotej.event.WRButtonEvent;
(function($){
/*
* jMerrygoround jQuery Plugin version 1.0
* http://lab.hisasann.com/jmerrygoround/
*
* Copyright (c) 2009 hisasann http://hisasann.com/
* Dual licensed under the MIT and GPL licenses.
*/
var