Deleted articles cannot be recovered. Draft of this article would be also deleted. Are you sure you want to delete this article?
ã¯ããã« Railsã§twitter-bootstrapã使ãæ¹æ³ã¯ããã¤ãããã¾ããgemã使ã£ã¦å°å ¥ããå ´åã lessã§ä½¿ãããã¨ãã¯ãtwitter-bootstrap-rails sassã§ä½¿ãããã¨ãã¯ãbootstrap-sass ãé¸æããã®ãã»ã¨ãã©ã ã¨æãã¾ãã twitter-bootstrap-railsã«ã¯ã¸ã§ãã¬ã¼ã¿ã®æ©è½ãããã¾ãããbootstrap-sassã«ã¯ããã¾ããã ãªã®ã§ãsassç°å¢ã§bootstrapã®ãã³ãã¬ã¼ããçæã§ãããbootstrap-generatorsã¨ããgemã使ã£ã¦ã¿ããã¨æãã¾ãã bootstrap-generators ã®ç¹å¾´ sass ãã³ãã¬ã¼ããçæã§ããã ã¤ã³ã¹ãã¼ã« Gemfileã«æ¬¡ã®ã©ã¤ã³ã追å : gem 'bootstrap-generators' bundle installãå®è¡: bundl
LESSãã¯ããããã¨æã£ããã¨ããããBootstrapã®mixinsãå ¥ãã¦ããã¨ä¾¿å© LESSã«ã¯Mixinã¨ããè¤æ°ã®ããããã£ãã¾ã¨ããæ©è½ãããã¾ãã ä¾ãã°css3ã®ãã³ãã¼ãã¬ãã£ãã¯ã¹ãªã©è¨å®ãã¦ããã°ããã¨ã§ï¼è¡ã§å¼ã³åºããã¨ãã§ãã¾ãã ã§ãå®éä½æããã«ãããä¸ããä½ããã Twitter Bootstrap ãå©ç¨ããã°ããã使ããããªæ©è½ããããããã¾ã¨ã¾ã£ã¦ãã®ã§ãããããããªãã§ãã æ稿æ¥2012å¹´04æ17æ¥ æ´æ°æ¥2012å¹´04æ17æ¥ css3ãããã㣠æºåãã§ããã¨ããã§æ©é使ã£ã¦ã¿ã¾ãããã æåã¯CSS3ã§è¿½å ããããborder-radiusãã§è§ä¸¸ã«ãã¦ã¿ã¾ãã ãã¨ãã°ãid="box1"ãã§ãã¼ã¯ã¢ãããããdivããããã¾ãã html <div id="box1"></div> é常ã®cssã§ããã次ã®ããã«ãªãã¾ãããã css
LESS ã使ã£ã¦ Bootstrap ãã«ã¹ã¿ãã¤ãº CATEGORY: HTML/CSS | TAG: Bootstrap, LESS 2013å¹´9æ2æ¥ Bootstrap(v3.0.0) ã«ã¯ä»¥ä¸ã®ãããªãã¿ã³ãªã©ã«ãããããç¨æããããªãã·ã§ã³ï¼ã¯ã©ã¹ï¼ãããã btn-primaryï¼éè²ï¼ btn-successï¼ç·è²ï¼ btn-infoï¼æ°´è²ï¼ btn-warningï¼ãªã¬ã³ã¸è²ï¼ btn-dangerï¼èµ¤è²ï¼ ããããç¬èªã®ã¯ã©ã¹åã§ä½¿ã£ãããè²ãå¤æ´ãããªã©ã®ã«ã¹ã¿ãã¤ãºãããéã®ã¡ã¢ãLESS ã®ã³ã³ãã¤ã«ã«ã¯ãPreprosãã使ç¨ã æºå Bootstrap ã® LESS ãã¡ã¤ã«ããã¦ã³ãã¼ã Bootstrap ã®ãGetting startedããã¼ã¸ã®ãAdditional downloadsãã®ä¸ã®ãDownload latest source code
CSSãæ¡å¼µããããã®ã¡ã¿è¨èªã¨ãã¦ã代表çãªãã®ã«ãSCSS(Sass)ãã¨ãLESSããããã¾ããä»åãå°å ¥ãæ¤è¨ããã«ãããã両è ãæ¯è¼ãã¾ããã çµæçã«ã¯ããSCSS(Sass)ããå°å ¥ãããã¨ã«ãã¾ããããç¹ã«ãSCSS(Sass)ããé¸æãã決ãæã¨ãªã£ãç¹ã«éç¹ãç½®ãã¤ã¤ã両è ã®éããã¾ã¨ãã¾ã¦ã¿ã¾ããã ã¯ããã« Webãµã¤ããWebã¢ããªã±ã¼ã·ã§ã³ã大è¦æ¨¡ã«ãªãã«ã¤ãã¦ãCSSã®è¨è¨ã»ç®¡çã«ããªã½ã¼ã¹ãå²ãããããã«ãªãã¾ããCSSã®ã¢ã¸ã¥ã¼ã«åãã³ã³ãã¼ãã³ãåã«ããåå©ç¨æ§ãèããã¨ããç¾ç¶ã®CSSãåãå·»ãç¶æ³ã¯ååã¨ã¯è¨ãã¾ããã ä¸ã¤ã®é¸æè¢ã¨ãã¦ãããã®ããBlueprintããã960 Glid Systemãçã®CSSãã¬ã¼ã ã¯ã¼ã¯ã®å©ç¨ã§ããããã®åå©ç¨æ§ã¨æ§é ã»è¡¨ç¾ã®åé¢åº¦ã¯ãã¬ã¼ããªãã§ãã ããã§ãCSSã®å©ç¹ãæ´»ããã¤ã¤ãåå©ç¨æ§ãé«ããããã«
Emacsã¦ã¼ã¶ã¼ãå¿«é©ã« LESS ã使ããããã«ãªãã¾ã§ã®å°å ¥è¨äºã§ãã LESS ã¨ã¯ä½ãã LESSã¨ã¯ãCSSã¡ã¿è¨èªã¨å¼ã°ãããã®ã§ãLESS ã®ä»ã« Sass(SCSS) ã¨å¼ã°ãããã®ãããã¾ãï¼Sassã¨SCSSã¯ã¡ãã£ã¨ã ãææ³ã®éãå å¼ã¿ãããªãã®ï¼ã LESS 㨠Sass ã®éã ææ³ãããã¨éãã¾ãã詳ããã¯ã¯ããã¦ã®CSSã¡ã¿è¨èªã¯Lessãããããï¼ Â« NAVER Engineers' Blogããããåç §ã LESS ã®å°å ¥ã LESS 㯠JS ã«ããã¯ã©ã¤ã¢ã³ããµã¤ãï¼è¦ããã«ãã©ã¦ã¶ä¸ï¼ã®å¤æï¼less->cssï¼ã«å¯¾å¿ãã¦ããã®ã§ãã¦ã£ã¨ãæ©ã試ãã¦ã¿ãã®ã«åãã¦ãã¾ãã å ·ä½çã«ã¯ style.less ãã¡ã¤ã«ã¨ä¸ç·ã«ãlessãµã¤ããããã¦ã³ãã¼ãã§ãã less.js ãèªã¿è¾¼ãã ãã§ä½¿ãã¾ãã <link rel="stylesheet
ã¿ãªãã¾ããã«ã¡ãã Webãµã¤ãé«éåãSCSSã®é£è¼ãæ¸ãã¦ããéä¸ã§ãã ããããã°Google Readerãçµäºããã¨ã®ãã¨ã§ã¨ã¦ãæ®å¿µã§ããã èªè ã®ã¿ãªãã¾ã次ã®å¼ã£è¶ãå ãã¼ã«æ¢ãã§å¿ããã¨ããã ã¨æãã¾ãã ããã§ãã¯ã©ã¹ã¡ã½ããéçºããã°ã®RSSãå¿ããã«ç»é²ããé¡ããã¾ãã ã¨ã¦ãæ´æ°é »åº¦ã®é«ãããã°ã¨ãããã¨ãããããããããªåãå£ã®RSSãç¨æãã¦ãã¾ãã æ¬é¡ ããã§ã¯æ¬é¡ã§ãããã¬ã¤ã¢ã¦ãç³»ã®CSSãã¬ã¼ã ã¯ã¼ã¯ã£ã¦è²ã ããã¾ãããã å人çã«ã¯HTMLä¸ã®ã¯ã©ã¹ã«ãã¾ãæå³ã®ãªãæååã¯å ¥ããããªãã®ã§ä½¿ã£ã¦ãã¾ããã§ãããHTMLãç·¨éããªããã°ãªããªãã®ã§ã ãµã¨Sass/SCSSã§ExtendãããMixinsã§å¶å¾¡ã§ãããã®ã§ããã°ç¡é§ãªã¯ã©ã¹æå®ãæ¸ããã¦å¯å¤ã§ã¬ã¹ãã³ã·ããªã°ãªããå¶å¾¡ãã§ããããããªããæã£ã¦æ¢ãã¦ã¿ããè²ã ã¨ããã¾ããã æå
ç¥ã£ã¦ãéãã§ã¡ãã£ã¨ã¾ã¨ãã¦ããã¾ãããLESSãSass+CompassãStylusãã³ã³ãã¤ã«ã§ããå種ãã¼ã«ã§ãï¼ãããã®Mixinséãªããã¯å ¥ãã¦ãã¾ããï¼ãä¸ã«ã¯ãHTMLã®ãã³ãã¬ã¼ãã¨ã³ã¸ã³ãªããããããã¦ã³ã³ãã¤ã«ã§ããã®ãå«ã¾ãã¦ãã¾ããä½ãã®ãåèã«ãªãã°ã GUIã§ã©ãã«ããããããªã㸠1. CodeKit CodeKitã¯ãæåã®ã¢ããªã±ã¼ã·ã§ã³ã§OS Xã§ãã使ãã¾ããã対å¿ãã¦ããããªããã»ããµããã³ãã¬ã¼ãã¨ã³ã¸ã³ã®ç¨®é¡ã¯å§åçã«å¤ãã®ãç¹å¾´ã§ããã¨ãããã使ããããªãã®ããããã¨ãLESSãSass/Compassï¼ã¨ãã®mixinã§ããBourbonï¼ãStylusã¨ãã£ãCSSããªããã»ããµã®é¡ãIEã®4095åã»ã¬ã¯ã¿ã®åé¡ãåé¿ããBlessãããã¦Hamlã«Jadeã«Slimã¨ãã£ããã³ãã¬ã¼ãã¨ã³ã¸ã³ãCoffeeScriptã«Node.
CSSãå¹ççã«æ¸ãããã®æ¡å¼µã¡ã¿è¨èªãLESSãã®ä½¿ãæ¹ãç´¹ä»ãã¾ãã LESS ï¼ï¼ãLESSãã§ã§ããã㨠簡åãªä¾ã¨ãã¦ã次ã®ããã«å¤æ°ã@xxxãã使ã£ã¦å¤ãå®ç¾©ãããã¨ãã§ãã¾ãã @radius: 10px; @bg-color: #fff; @padding: 10px; .foo { background: @bg-color; padding: @padding; border-radius: @radius; -webkit-border-radius: @radius; -moz-border-radius: @radius; } .bar { background: @bg-color; padding: @padding; border-radius: @radius; -webkit-border-radius: @radius; -moz-border-ra
ãªãªã¼ã¹ãé害æ å ±ãªã©ã®ãµã¼ãã¹ã®ãç¥ãã
ææ°ã®äººæ°ã¨ã³ããªã¼ã®é ä¿¡
å¦çãå®è¡ä¸ã§ã
j次ã®ããã¯ãã¼ã¯
kåã®ããã¯ãã¼ã¯
lãã¨ã§èªã
eã³ã¡ã³ãä¸è¦§ãéã
oãã¼ã¸ãéã
{{#tags}}- {{label}}
{{/tags}}