<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:dc="http://purl.org/dc/elements/1.1/" version="2.0"><channel><atom:link rel="hub" href="http://tumblr.superfeedr.com/" xmlns:atom="http://www.w3.org/2005/Atom"/><description></description><title>便當盒</title><generator>Tumblr (3.0; @nahoya)</generator><link>http://blog.nahoya.com/</link><item><title>Things It Might Be Fun/Useful to Try the Universal (*) Selector On | CSS-Tricks</title><description>&lt;a href="http://css-tricks.com/things-it-might-be-funuseful-to-try-the-universal-selector-on/"&gt;Things It Might Be Fun/Useful to Try the Universal (*) Selector On | CSS-Tricks&lt;/a&gt;: &lt;blockquote&gt;&lt;p&gt;&lt;a href="http://css-tricks.com/things-it-might-be-funuseful-to-try-the-universal-selector-on/" target="_blank"&gt;css-tricks.com&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Paul Irish recent­ly wrote a post on using the uni­ver­sal selec­tor to set border-box box-sizing on every­thing:&lt;/p&gt;&lt;p&gt;I’ve been want­i­ng to try that for a while and I’m happy to say I’ve used it on a few projects already and it’s awe­some. It also …&lt;/p&gt;
&lt;/blockquote&gt;</description><link>http://blog.nahoya.com/post/17712930044</link><guid>http://blog.nahoya.com/post/17712930044</guid><pubDate>Thu, 16 Feb 2012 23:34:35 +0800</pubDate></item><item><title>jQuery datetimepicker range select example</title><description>&lt;p&gt;使用 jQuery datetimepicker 官網的範圍選擇範例遇到時間會自動消失的問題。&lt;/p&gt;

&lt;p&gt;就是如果另外一個日期時間欄位(B)有預設值，在 B 的 datetimepicker 尚未顯示前就已經在 A 選好的值的話，會造成 B 的時間消失，且 A 跟 B 的 minDate/maxDate 效果會出不來。&lt;/p&gt;

&lt;p&gt;以下是防止這個問題出現的範例，另外根據個人喜好加上限制時間的 minDateTime/maxDateTime 選項：&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;var dates = $('#from, #to').
  each(function(){
    if ( this.value ) {
      var option = this.id === 'from' ? 'minDate' : 'maxDate';

      $('#from, #to').not(this).
        attr('time:'+option, 'new Date("'+this.value+'")').
        attr('time:'+option+'Time', 'new Date("'+this.value+'")');
    }
  }).
  datetimepicker({
    dateFormat: 'yy-mm-dd',
    timeFormat: 'hh:mm:ss',
    changeMonth: true,
    alwaysSetTime: true,
    changeYear: true,
    hourGrid: 4,
    minuteGrid: 10,
    onSelect: function(selectedDatetime, inst) {
      var $_ = $(this),
          option = this.id === 'from' ? 'minDate' : 'maxDate',
          date = $_.datetimepicker('getDate'),
          other = dates.not(this);

      if ( other.val()) {
        var otherDate = other.datetimepicker('getDate');

        // limit current input
        if (
          ( this.id === 'from' &amp;&amp; date.getTime() &gt; otherDate.getTime()) ||
          ( this.id === 'to' &amp;&amp; date.getTime() &lt; otherDate.getTime())
        ) {
          date = new Date(otherDate.getTime());
          $_.datetimepicker('setDate', date);
        }

        // set other date
        other.
          datetimepicker('setDate', otherDate);
      }
      other.
        datetimepicker('option', option, date ).
        datetimepicker('option', option+'Time', date );
    }
  });
&lt;/code&gt;&lt;/pre&gt;</description><link>http://blog.nahoya.com/post/17313018121</link><guid>http://blog.nahoya.com/post/17313018121</guid><pubDate>Thu, 09 Feb 2012 17:33:00 +0800</pubDate><category>jquery</category><category>datetimepicker</category><category>javascript</category></item><item><title>「iCook 愛料理」如何善用雲端服務，加速網站產品開發 - Inside 網路趨勢觀察</title><description>&lt;a href="http://www.inside.com.tw/2012/01/30/icook-cloud-service"&gt;「iCook 愛料理」如何善用雲端服務，加速網站產品開發 - Inside 網路趨勢觀察&lt;/a&gt;: &lt;p&gt;很多工具可以參考&lt;/p&gt;</description><link>http://blog.nahoya.com/post/16754533636</link><guid>http://blog.nahoya.com/post/16754533636</guid><pubDate>Mon, 30 Jan 2012 17:45:02 +0800</pubDate></item><item><title>Better Google Web Fonts</title><description>&lt;a href="http://somadesign.ca/demos/better-google-fonts/"&gt;Better Google Web Fonts&lt;/a&gt;: &lt;blockquote&gt;&lt;p&gt;&lt;a href="http://somadesign.ca/demos/better-google-fonts/" target="_blank"&gt;somadesign.ca&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;</description><link>http://blog.nahoya.com/post/16214423360</link><guid>http://blog.nahoya.com/post/16214423360</guid><pubDate>Sat, 21 Jan 2012 14:02:11 +0800</pubDate></item><item><title>This new typeface was made just for interface designers</title><description>&lt;a href="http://thenextweb.com/dd/2012/01/21/this-new-typeface-was-made-just-for-interface-designers/"&gt;This new typeface was made just for interface designers&lt;/a&gt;: &lt;blockquote&gt;&lt;p&gt;Harrison Weber, &lt;a href="http://thenextweb.com/dd/2012/01/21/this-new-typeface-was-made-just-for-interface-designers/" target="_blank"&gt;thenextweb.com&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Mod­ern Pic­tograms is new type­face cre­at­ed for inter­face design­ers and pro­gram­mers. It was designed to work on-screen at sizes down to 18 pix­els, and is remark­ably pixel-perfect and use­ful as a pic­to­graph­ic font.&lt;/p&gt;&lt;p&gt;Why a font file?…&lt;/p&gt;
&lt;/blockquote&gt;</description><link>http://blog.nahoya.com/post/16213325525</link><guid>http://blog.nahoya.com/post/16213325525</guid><pubDate>Sat, 21 Jan 2012 13:36:37 +0800</pubDate></item><item><title>Deprecated Linux networking commands and their replacements « Doug Vitale Tech Blog</title><description>&lt;a href="http://dougvitale.wordpress.com/2011/12/21/deprecated-linux-networking-commands-and-their-replacements/"&gt;Deprecated Linux networking commands and their replacements « Doug Vitale Tech Blog&lt;/a&gt;</description><link>http://blog.nahoya.com/post/16116562039</link><guid>http://blog.nahoya.com/post/16116562039</guid><pubDate>Thu, 19 Jan 2012 23:14:31 +0800</pubDate><category>linux</category></item><item><title>An Intro to Backbone.js: Part 1 – Models and Collections - Liquid Media</title><description>&lt;a href="http://liquidmedia.ca/blog/2011/01/backbone-js-part-1/"&gt;An Intro to Backbone.js: Part 1 – Models and Collections - Liquid Media&lt;/a&gt;</description><link>http://blog.nahoya.com/post/16056883479</link><guid>http://blog.nahoya.com/post/16056883479</guid><pubDate>Wed, 18 Jan 2012 18:18:11 +0800</pubDate><category>backbone.js</category></item><item><title>Icons for Apps and Stuff</title><description>&lt;a href="http://uicons.co/"&gt;Icons for Apps and Stuff&lt;/a&gt;: &lt;blockquote&gt;&lt;p&gt;&lt;a href="http://uicons.co/" target="_blank"&gt;uicons.co&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;</description><link>http://blog.nahoya.com/post/16049082775</link><guid>http://blog.nahoya.com/post/16049082775</guid><pubDate>Wed, 18 Jan 2012 12:54:00 +0800</pubDate><category>icon</category></item><item><title>Holiday Reading #1: Backbone.js</title><description>&lt;p&gt;&lt;a href="http://vincicat.tumblr.com/post/14621350964/holiday-reading-1-backbone-js" class="tumblr_blog" target="_blank"&gt;vincicat&lt;/a&gt;:&lt;/p&gt;

&lt;blockquote&gt;&lt;p&gt;&lt;a href="https://github.com/addyosmani/backbone-fundamentals" target="_blank"&gt;Backbone.js Fundamentals&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://github.com/addyosmani/backbone-mobile-search" target="_blank"&gt;Backbone.js x jQuery Mobile: Flickly Mobile&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="http://arturadib.com/hello-backbonejs/" target="_blank"&gt;Hello Backbone.js&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://github.com/documentcloud/backbone/wiki/Tutorials%2C-blog-posts-and-example-sites" target="_blank"&gt;Offical Tutorial List&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="http://lostechies.com/derickbailey/2011/12/16/composite-javascript-applications-with-backbone-and-backbone-marionette/" target="_blank"&gt;backbone-marionette&lt;/a&gt;&lt;/p&gt;&lt;/blockquote&gt;</description><link>http://blog.nahoya.com/post/15809273319</link><guid>http://blog.nahoya.com/post/15809273319</guid><pubDate>Sat, 14 Jan 2012 11:45:41 +0800</pubDate></item><item><title>jiwostudio:

(via Bijou — tiny, 10 pixel icons for free)</title><description>&lt;img src="http://24.media.tumblr.com/tumblr_lx5njylHui1qzi4syo1_500.png"/&gt;&lt;br/&gt;&lt;br/&gt;&lt;p&gt;&lt;a href="http://blog.jiwo.in/post/15166480224" class="tumblr_blog" target="_blank"&gt;jiwostudio&lt;/a&gt;:&lt;/p&gt;

&lt;blockquote&gt;&lt;p&gt;(via &lt;a href="http://bijou.im/" target="_blank"&gt;Bijou — tiny, 10 pixel icons for free&lt;/a&gt;)&lt;/p&gt;&lt;/blockquote&gt;</description><link>http://blog.nahoya.com/post/15809015467</link><guid>http://blog.nahoya.com/post/15809015467</guid><pubDate>Sat, 14 Jan 2012 11:40:41 +0800</pubDate></item><item><title>jiwostudio:

Indigo icons by Mihaiciuc Bogdan. Free

(via Indigo...</title><description>&lt;img src="http://26.media.tumblr.com/tumblr_lx9fpt2GrB1qzi4syo1_500.png"/&gt;&lt;br/&gt;&lt;br/&gt;&lt;p&gt;&lt;a href="http://blog.jiwo.in/post/15284184584" class="tumblr_blog" target="_blank"&gt;jiwostudio&lt;/a&gt;:&lt;/p&gt;

&lt;blockquote&gt;&lt;p&gt;Indigo icons by Mihaiciuc Bogdan. Free&lt;/p&gt;

&lt;p&gt;(via &lt;a href="http://bogo-d.deviantart.com/#/d4l7ktk" target="_blank"&gt;Indigo Icons by ~bogo-d&lt;/a&gt;)&lt;/p&gt;&lt;/blockquote&gt;</description><link>http://blog.nahoya.com/post/15808986331</link><guid>http://blog.nahoya.com/post/15808986331</guid><pubDate>Sat, 14 Jan 2012 11:40:00 +0800</pubDate><category>icon</category></item><item><title>tmux + macvim clipboard 無法共用解法</title><description>&lt;p&gt;找了很久，終於找到解決方案&lt;br/&gt;&lt;a href="https://github.com/ChrisJohnsen/tmux-MacOSX-pasteboard" target="_blank"&gt;&lt;a href="https://github.com/ChrisJohnsen/tmux-MacOSX-pasteboard" target="_blank"&gt;https://github.com/ChrisJohnsen/tmux-MacOSX-pasteboard&lt;/a&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;照著 Quick Summary 的指示操作，其中 zsh 換成慣用的 bash。重新啟動 tmux server，macvim 剪貼簿就會工作了！&lt;/p&gt;</description><link>http://blog.nahoya.com/post/15661334279</link><guid>http://blog.nahoya.com/post/15661334279</guid><pubDate>Wed, 11 Jan 2012 14:15:37 +0800</pubDate><category>tmux</category><category>macvim</category><category>clipboard</category></item><item><title>iTerm2 + tmux 光標向前/向後移動單字失效筆記</title><description>&lt;p&gt;紀錄一下 iTerm2 + tmux 光標向前/向後移動單字的 .inputrc&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;# for tmux 
"\eOD": backward-word 
"\eOC": forward-word 
# xterm/urxvf 
"\e[1;5D": backward-word 
"\e[1;5C": forward-word
&lt;/code&gt;&lt;/pre&gt;</description><link>http://blog.nahoya.com/post/15604904023</link><guid>http://blog.nahoya.com/post/15604904023</guid><pubDate>Tue, 10 Jan 2012 12:17:00 +0800</pubDate><category>iterm2</category><category>tmux</category><category>inputrc</category></item><item><title>yoshimasa niwa - TerminalColoreopard, Change Terminal.app ANSI Color on Leopard</title><description>&lt;a href="http://niw.at/articles/2007/11/02/TerminalColoreopard/en"&gt;yoshimasa niwa - TerminalColoreopard, Change Terminal.app ANSI Color on Leopard&lt;/a&gt;: &lt;p&gt;覺得mac terminal的藍色太暗嗎？Snow Leopard 用這個可以調整ANSI色彩&lt;/p&gt;</description><link>http://blog.nahoya.com/post/15558432175</link><guid>http://blog.nahoya.com/post/15558432175</guid><pubDate>Mon, 09 Jan 2012 15:19:51 +0800</pubDate><category>osx</category></item><item><title>jQuery Validation - fix required method not work in ie8.</title><description>&lt;p&gt;由於個人使用 required 驗證的方式是這樣的:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;&lt;input .... required="required" /&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;但在 IE8 中，&lt;code&gt;depend()&lt;/code&gt; 裡的 &lt;code&gt;typeof param&lt;/code&gt; 會是 &lt;code&gt;string&lt;/code&gt; 而非預期的 &lt;code&gt;boolean&lt;/code&gt;。必須在 &lt;code&gt;required()&lt;/code&gt; 裡面加上這段才會正常:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;if ( $.browser.msie ) {
    param = param === 'required';
}
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;加在 this.depend() 呼叫之前:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;required: function(value, element, param) {
    if ( $.browser.msie ) {
        param = param === 'required';
    }
    // check if dependency is met
    if ( !this.depend(param, element) )
        return "dependency-mismatch";
    switch( element.nodeName.toLowerCase() ) {
    case 'select':
        // could be an array for select-multiple or a string, both are fine this way
        var val = $(element).val();
        return val &amp;&amp; val.length &gt; 0;
    case 'input':
        if ( this.checkable(element) )
            return this.getLength(value, element) &gt; 0;
    default:
        return $.trim(value).length &gt; 0;
    }
},
&lt;/code&gt;&lt;/pre&gt;</description><link>http://blog.nahoya.com/post/15382418861</link><guid>http://blog.nahoya.com/post/15382418861</guid><pubDate>Fri, 06 Jan 2012 12:04:21 +0800</pubDate><category>jquery</category><category>validation</category></item><item><title>Sass and Compass CSS animation library based on Animate.css</title><description>&lt;a href="https://github.com/adamstac/animate.sass"&gt;Sass and Compass CSS animation library based on Animate.css&lt;/a&gt;: &lt;p&gt;這個世界真是太美好了，因為有你！&lt;/p&gt;</description><link>http://blog.nahoya.com/post/15158483314</link><guid>http://blog.nahoya.com/post/15158483314</guid><pubDate>Mon, 02 Jan 2012 10:40:00 +0800</pubDate><category>sass</category></item><item><title>vnc.js: how to build a JavaScript VNC Client in a 24 hour hackday | LinkedIn Engineering</title><description>&lt;a href="http://engineering.linkedin.com/javascript/vncjs-how-build-javascript-vnc-client-24-hour-hackday"&gt;vnc.js: how to build a JavaScript VNC Client in a 24 hour hackday | LinkedIn Engineering&lt;/a&gt;</description><link>http://blog.nahoya.com/post/14539414725</link><guid>http://blog.nahoya.com/post/14539414725</guid><pubDate>Wed, 21 Dec 2011 09:41:09 +0800</pubDate><category>飛天遁地JS</category></item><item><title>理解inode - 阮一峰的網絡日誌</title><description>&lt;a href="http://www.ruanyifeng.com/blog/2011/12/inode.html"&gt;理解inode - 阮一峰的網絡日誌&lt;/a&gt;</description><link>http://blog.nahoya.com/post/13726841002</link><guid>http://blog.nahoya.com/post/13726841002</guid><pubDate>Sun, 04 Dec 2011 22:07:15 +0800</pubDate></item><item><title>“Mobile first” CSS and getting Sass to help with legacy IE – Nicolas Gallagher</title><description>&lt;a href="http://nicolasgallagher.com/mobile-first-css-sass-and-ie/"&gt;“Mobile first” CSS and getting Sass to help with legacy IE – Nicolas Gallagher&lt;/a&gt;</description><link>http://blog.nahoya.com/post/13724797331</link><guid>http://blog.nahoya.com/post/13724797331</guid><pubDate>Sun, 04 Dec 2011 20:34:19 +0800</pubDate><category>sass</category><category>ie</category></item><item><title>Zocial: CSS3 Buttons, Sass framework. - Projects</title><description>&lt;a href="http://thesassway.com/projects/zocial-buttons"&gt;Zocial: CSS3 Buttons, Sass framework. - Projects&lt;/a&gt;</description><link>http://blog.nahoya.com/post/13724553683</link><guid>http://blog.nahoya.com/post/13724553683</guid><pubDate>Sun, 04 Dec 2011 20:21:12 +0800</pubDate><category>sass</category></item></channel></rss>

