netguru_theme 0.1.0 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ea4e9222120f9436e2aa949a751ef915e10aa2a3
4
- data.tar.gz: 0e7275706a81631d1d07e9ba3aab6e0ada677feb
3
+ metadata.gz: f31785b4816e1efe5cb2959d95a32c0c1b565917
4
+ data.tar.gz: f67567a5b06bd53f0187c6ae91573153ecbd8164
5
5
  SHA512:
6
- metadata.gz: c0de55ca10bcc13ea805ef41477ca7003b036d3c2e41f7fafd51723c68c2f04b24eb5f64906f4ff7fd1fe2bf9a9d923487600940025cf0f9ab6d615080915503
7
- data.tar.gz: 7b5306a8f29269746e11cd8e47ed835542a8b7a5802b565e71453cca0990ae8da1587d8d8845c9796368017b59c8883288fdc9dfe7abe441eb72ffd09e21daa2
6
+ metadata.gz: 5aeb6df66901062eb6dd45ba99dbe9166d27de8a3c97a5b359e2cafb217e5ac2146f5761f59578404322221c01ba98ed87a25de88435710148c88412410238ec
7
+ data.tar.gz: 92cf6e0153e9949ce00b7017d931ceaf5c018c100593180f451f0a9ff65d3e3606ea379fe1292dfe654db85f15b2c0830e829a56fd5c100b58bd9c4f4fe10e8c
data/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # netguru_theme changelog
2
2
 
3
+ #### 0.1.0
4
+ + moved **people** app components to [apps/people](https://github.com/netguru/netguru_theme/tree/master/app/assets/stylesheets/netguru-theme/apps/people) directory. To import all people components add <code>@import 'netguru-theme/apps/people'</code> to your <code>application.scss</code>
5
+ + mixin <code>quantity</code> is marked as deprecated - use mixin <code>sizing</code>
6
+ + this gem is now compatible with Sass 3.2 and uses Bourbon 3.2
7
+ + added [z-index](https://github.com/netguru/netguru_theme/blob/master/app/assets/stylesheets/netguru-theme/settings/_z-index-variables.scss) and [breakpoint](https://github.com/netguru/netguru_theme/blob/master/app/assets/stylesheets/netguru-theme/settings/_breakpoint-variables.scss) variables
8
+
3
9
  #### 0.0.6
4
10
  + import each component separately (instead of <code>@import "components/*"</code>)
5
11
 
data/bin/netguru_theme ADDED
@@ -0,0 +1,4 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require File.dirname(__FILE__) + '/../lib/netguru_theme.rb'
4
+ NetguruTheme::Generator.start
@@ -0,0 +1,45 @@
1
+ module NetguruTheme
2
+ class Generator < Thor
3
+ option :style
4
+
5
+ desc 'install', 'Install netguru_theme styles into your project'
6
+ def install
7
+ return unless valid_style?
8
+ render = Sass::Engine.new(File.read(source_path), params).render
9
+ File.write('netguru-theme.css', render)
10
+ end
11
+
12
+ desc 'version', 'Show netguru_theme version'
13
+ def version
14
+ puts "netguru_theme v#{NetguruTheme::VERSION}"
15
+ end
16
+
17
+ private
18
+
19
+ def valid_style?
20
+ return true if %w(compressed nested expanded compact).include? style
21
+ error_message = 'Invalid --style option. Allowed options: compressed '\
22
+ '(default), nested, expanded or compact.'
23
+ puts error_message
24
+ end
25
+
26
+ def source_path
27
+ top_level_directory = File.dirname(File.dirname(File.dirname(__FILE__)))
28
+ File.join(top_level_directory, 'app', 'assets', 'stylesheets',
29
+ '_netguru-theme.scss')
30
+ end
31
+
32
+ def style
33
+ options[:style].nil? ? 'compressed' : options[:style]
34
+ end
35
+
36
+ def params
37
+ {
38
+ cache: false,
39
+ syntax: :scss,
40
+ style: style.to_sym,
41
+ filename: source_path
42
+ }
43
+ end
44
+ end
45
+ end
@@ -1,3 +1,3 @@
1
1
  module NetguruTheme
2
- VERSION = '0.1.0'
2
+ VERSION = '0.2.0'
3
3
  end
data/lib/netguru_theme.rb CHANGED
@@ -1,9 +1,12 @@
1
+ require 'sass'
2
+ require 'bootstrap-sass'
3
+ require 'bourbon'
4
+
1
5
  require 'netguru_theme/version'
6
+ require 'netguru_theme/generator'
2
7
 
3
8
  module NetguruTheme
4
- class Engine < ::Rails::Engine
5
- require 'sass'
6
- require 'bootstrap-sass'
7
- require 'bourbon'
9
+ if defined?(Rails) && defined?(Rails::Engine)
10
+ class Engine < ::Rails::Engine; end
8
11
  end
9
12
  end
@@ -13,8 +13,8 @@ Gem::Specification.new do |spec|
13
13
  spec.homepage = "https://github.com/netguru/netguru_theme"
14
14
  spec.license = "MIT"
15
15
 
16
- spec.files = `git ls-files -z`.split("\x0")
17
- spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
16
+ spec.files = `git ls-files`.split("\n")
17
+ spec.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
18
18
  spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
19
19
  spec.require_paths = ["lib"]
20
20
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: netguru_theme
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mateusz Czajka
@@ -83,7 +83,8 @@ dependencies:
83
83
  description: Netguru Bootstrap Theme
84
84
  email:
85
85
  - mat.czajka@gmail.com
86
- executables: []
86
+ executables:
87
+ - netguru_theme
87
88
  extensions: []
88
89
  extra_rdoc_files: []
89
90
  files:
@@ -119,7 +120,9 @@ files:
119
120
  - app/assets/stylesheets/netguru-theme/utilities/_mixins.scss
120
121
  - app/assets/stylesheets/netguru-theme/utilities/_presentional-classes.scss
121
122
  - app/assets/stylesheets/netguru-theme/utilities/_typography.scss
123
+ - bin/netguru_theme
122
124
  - lib/netguru_theme.rb
125
+ - lib/netguru_theme/generator.rb
123
126
  - lib/netguru_theme/version.rb
124
127
  - netguru_theme.gemspec
125
128
  homepage: https://github.com/netguru/netguru_theme