├── .gitignore ├── .gitmodules ├── Gemfile ├── MIT-LICENSE ├── README.md ├── Rakefile ├── lib ├── zurui-sass-rails.rb └── zurui-sass-rails │ └── version.rb ├── vendor └── assets │ └── stylesheets │ └── _zurui-sass.sass └── zurui-sass-rails.gemspec /.gitignore: -------------------------------------------------------------------------------- 1 | *.gem 2 | *.rbc 3 | .bundle 4 | .config 5 | .yardoc 6 | Gemfile.lock 7 | InstalledFiles 8 | _yardoc 9 | coverage 10 | doc/ 11 | lib/bundler/man 12 | pkg 13 | rdoc 14 | spec/reports 15 | test/tmp 16 | test/version_tmp 17 | tmp 18 | -------------------------------------------------------------------------------- /.gitmodules: -------------------------------------------------------------------------------- 1 | [submodule "vendor/assets/stylesheets/zurui-sass"] 2 | path = vendor/assets/stylesheets/zurui-sass 3 | url = git@github.com:mahm/zurui-sass.git 4 | -------------------------------------------------------------------------------- /Gemfile: -------------------------------------------------------------------------------- 1 | source 'https://rubygems.org' 2 | 3 | # Specify your gem's dependencies in zurui-sass-rails.gemspec 4 | gemspec 5 | -------------------------------------------------------------------------------- /MIT-LICENSE: -------------------------------------------------------------------------------- 1 | Copyright (c) 2012 mahm 2 | 3 | MIT License 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining 6 | a copy of this software and associated documentation files (the 7 | "Software"), to deal in the Software without restriction, including 8 | without limitation the rights to use, copy, modify, merge, publish, 9 | distribute, sublicense, and/or sell copies of the Software, and to 10 | permit persons to whom the Software is furnished to do so, subject to 11 | the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be 14 | included in all copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 17 | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 18 | MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 19 | NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE 20 | LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION 21 | OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION 22 | WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # zurui-sass-rails 2 | 3 | [@ken_c_lo](https://twitter.com/ken_c_lo)さんの[ズルいデザインテクニック](https://speakerdeck.com/ken_c_lo/zurui-design)のMixinをまとめたGemです。 4 | 5 | # Important Notice 6 | 7 | 今までcompassに依存した形でスタイルを実現していましたが、compass依存をなくしました。そのため、compass-rails等の導入は必要ありません。 8 | 9 | ## Installation 10 | 11 | ### Railsユーザー向け 12 | 13 | 1) 以下のコードを`Gemfile`に追加してください: 14 | 15 | ```ruby 16 | gem 'sass-rails' # sassc-railsでもok 17 | gem 'zurui-sass-rails' 18 | ``` 19 | 20 | 2) 以下のコードを`application.css.sass`のようなファイルに追加して下さい: 21 | 22 | ```sass 23 | @import zurui-sass 24 | ``` 25 | 26 | 3) Enjoy! 27 | 28 | ### Middlemanユーザー向け 29 | 30 | https://github.com/mahm/zurui-sass-middleman をご利用下さい。 31 | 32 | ### 上記以外をお使いの方向け 33 | 34 | 1) 以下のコマンドを実行して、ローカルに`_zurui-sass.sass`をダウンロードして下さい: 35 | 36 | ``` 37 | curl https://raw.github.com/mahm/zurui-sass/_zurui-sass.scss > _zurui-sass.scss 38 | ``` 39 | 40 | 2) `_zurui-sass.sass`をインポートしてお使いください: 41 | 42 | ```sass 43 | @import zurui-sass 44 | ``` 45 | 46 | 3) Enjoy! 47 | 48 | 49 | ## 使用例 50 | 51 | ### 最新版 52 | 53 | - [Zurui Sass Sample for Rails5(Github)](http://github.com/mahm/zurui-sample-rails5) 54 | 55 | ### 過去のもの(そのうち消します) 56 | 57 | - [Zurui Sass Sample](http://zurui-sample.herokuapp.com/) 58 | - [Zurui Sass Sample(Github)](http://github.com/mahm/zurui-sample) 59 | 60 | ## Contributing 61 | 62 | 1. Fork it 63 | 2. Create your feature branch (`git checkout -b feature/my-new-feature`) 64 | 3. Commit your changes (`git commit -am 'Added some feature'`) 65 | 4. Push to the branch (`git push origin feature/my-new-feature`) 66 | 5. Create new Pull Request 67 | -------------------------------------------------------------------------------- /Rakefile: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env rake 2 | require "bundler/gem_tasks" 3 | -------------------------------------------------------------------------------- /lib/zurui-sass-rails.rb: -------------------------------------------------------------------------------- 1 | require "zurui-sass-rails/version" 2 | 3 | module ZuruiSassRails 4 | class Engine < ::Rails::Engine 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /lib/zurui-sass-rails/version.rb: -------------------------------------------------------------------------------- 1 | module ZuruiSassRails 2 | VERSION = "0.1.0" 3 | end 4 | -------------------------------------------------------------------------------- /vendor/assets/stylesheets/_zurui-sass.sass: -------------------------------------------------------------------------------- 1 | @import zurui-sass/zurui-sass 2 | -------------------------------------------------------------------------------- /zurui-sass-rails.gemspec: -------------------------------------------------------------------------------- 1 | # -*- encoding: utf-8 -*- 2 | require File.expand_path('../lib/zurui-sass-rails/version', __FILE__) 3 | 4 | Gem::Specification.new do |gem| 5 | gem.authors = ["mah_lab"] 6 | gem.email = ["rootmoon@gmail.com"] 7 | gem.description = %q{Sass mixins by zurui-design(https://speakerdeck.com/ken_c_lo/zurui-design)} 8 | gem.summary = %q{Sass mixins by zurui-design(https://speakerdeck.com/ken_c_lo/zurui-design)} 9 | gem.homepage = "https://github.com/mahm/zurui-sass-rails" 10 | 11 | gem.files = Dir["{lib,vendor}/**/*"] + ["MIT-LICENSE", "README.md"] 12 | gem.executables = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) } 13 | gem.test_files = gem.files.grep(%r{^(test|spec|features)/}) 14 | gem.name = "zurui-sass-rails" 15 | gem.require_paths = ["lib"] 16 | gem.version = ZuruiSassRails::VERSION 17 | 18 | gem.add_dependency "railties", ">= 3.1" 19 | 20 | # get an array of submodule dirs by executing 'pwd' inside each submodule 21 | `git submodule --quiet foreach pwd`.split($\).each do |submodule_path| 22 | # for each submodule, change working directory to that submodule 23 | Dir.chdir(submodule_path) do 24 | 25 | # issue git ls-files in submodule's directory 26 | submodule_files = `git ls-files`.split($\) 27 | 28 | # prepend the submodule path to create absolute file paths 29 | submodule_files_fullpaths = submodule_files.map do |filename| 30 | "#{submodule_path}/#{filename}" 31 | end 32 | 33 | # remove leading path parts to get paths relative to the gem's root dir 34 | # (this assumes, that the gemspec resides in the gem's root dir) 35 | submodule_files_paths = submodule_files_fullpaths.map do |filename| 36 | filename.gsub "#{File.dirname(__FILE__)}/", "" 37 | end 38 | 39 | # add relative paths to gem.files 40 | gem.files += submodule_files_paths 41 | end 42 | end 43 | end 44 | --------------------------------------------------------------------------------