purecss 0.5.0.1 → 0.5.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/HISTORY.md +1 -0
- data/README.md +2 -1
- data/lib/purecss/generators/install_generator.rb +9 -1
- data/lib/purecss/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d47d5f53812fdfdafebbbc73555660ab9d1de052
|
4
|
+
data.tar.gz: 1955efb305ec45fca466fff2d1804ef54f053467
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 55fa8140e0ae77c215518f15ab49e461890e6f222d15dbe1824f2eed5dd8c38553501165453fe24c4355d403d33e6a5424345fb4488777fd638bbf186a75d3b3
|
7
|
+
data.tar.gz: 5d1d0fcde8e966e5b8b585e40f55d00d6ba99524555f87a96d65b58d2afb4423e58d66cd9cc48adeab53c1d18aa6fa94afa6d3ec24f8bc0992fab094bc2538cc
|
data/HISTORY.md
CHANGED
@@ -8,6 +8,7 @@ I'd like to add
|
|
8
8
|
|
9
9
|
|
10
10
|
# Changelog
|
11
|
+
- 0.5.0.2 Added `add_viewport_meta` flag to the generator (default: false). See [closed issue](https://github.com/mseri/rails-purecss/issues/6)
|
11
12
|
- 0.5.0.1 Fixed generator name (thanks [sespindola](https://github.com/mseri/rails-purecss/pull/4))
|
12
13
|
- 0.5 Purecss updated to the new 0.5.0 release (thanks [ruslanpa](https://github.com/mseri/rails-purecss/pull/3))
|
13
14
|
- 0.4.2.1 Fixed bug, thanks to
|
data/README.md
CHANGED
@@ -49,6 +49,7 @@ If it is too long for you, you can avoid touching the manifest files and run the
|
|
49
49
|
|
50
50
|
$ rails generate purecss:install
|
51
51
|
|
52
|
+
To add the viewport meta in the head of your application.html.erb it is enough to append `--add_viewport_meta` when you run the generator.
|
52
53
|
|
53
54
|
## Usage
|
54
55
|
|
@@ -65,7 +66,7 @@ It provides the CSS classes
|
|
65
66
|
- ```pure-custom-caret``` for the dropdown menu (to use if you are not using FontAwsome)
|
66
67
|
- (no more needed) ```pure-menu-custom-separator-vertical``` to add a vertical separator to the horizontal menu
|
67
68
|
- ```pure-custom-close``` for nicer ```x``` to close eventual modal views (to display modals, bootstrap-modal works quite well with Pure)
|
68
|
-
- ```pure-custom-alert```, ```pure-custom-alert-error```, ```pure-
|
69
|
+
- ```pure-custom-alert```, ```pure-custom-alert-error```, ```pure-custom-alert-success```, ```pure-custom-alert-warning```
|
69
70
|
- ```pure-menu-pull-right``` to align the menu to the right (must be in the same tag of ```pure-menu```, see [this example](http://jsfiddle.net/xUwCw/)). Thanks to [msweeney](https://github.com/msweeney) for this workaround.
|
70
71
|
|
71
72
|
<!--
|
@@ -5,6 +5,7 @@ module Purecss
|
|
5
5
|
class InstallGenerator < Rails::Generators::Base
|
6
6
|
source_root File.join(File.dirname(__FILE__), 'templates')
|
7
7
|
argument :stylesheets_type, :type => :string, :default => 'responsive', :banner => '*responsive or nonresponsive'
|
8
|
+
class_option :add_viewport_meta, :type => :boolean, :default => false, :description => "Inject Viewport Meta in the Head of layout/application.html.erb (default: false)"
|
8
9
|
|
9
10
|
def add_assets
|
10
11
|
if stylesheets_type=='nonresponsive'
|
@@ -16,7 +17,14 @@ module Purecss
|
|
16
17
|
|
17
18
|
end
|
18
19
|
|
19
|
-
insert_into_file "app/assets/stylesheets/application#{detect_css_format[0]}", "#{detect_css_format[1]} require #{purecss_type}\n", :after => "require_self\n"
|
20
|
+
insert_into_file "app/assets/stylesheets/application#{detect_css_format[0]}", "#{detect_css_format[1]} require #{purecss_type}\n", :after => "require_self\n"
|
21
|
+
|
22
|
+
if options.add_viewport_meta
|
23
|
+
if not File.exist?("app/views/layouts/application.html.erb")
|
24
|
+
raise "Unable to add viewport meta tag to (see https://github.com/mseri/rails-purecss/issues/6)"
|
25
|
+
end
|
26
|
+
insert_into_file "app/views/layouts/application.html.erb", " <!-- Set the viewport width to device width for mobile -->\n <meta name=\"viewport\" content=\"width=device-width, initial-scale=1\">\n", :before => "</head>"
|
27
|
+
end
|
20
28
|
end
|
21
29
|
|
22
30
|
def detect_css_format
|
data/lib/purecss/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: purecss
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.5.0.
|
4
|
+
version: 0.5.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- mseri
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2015-01-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|