rails_dialog 0.0.1 → 0.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: e1a24960740c91f82e93dca9008fc3be9da857fc
4
- data.tar.gz: 9bab592ee9b0c34422dfaa305dc8f0d7fc808dd8
3
+ metadata.gz: 432668fc4c9f9af816e0ba6fb907c746e8ad6af0
4
+ data.tar.gz: 5781289d124915beef25619ebe8ab26f89e72d79
5
5
  SHA512:
6
- metadata.gz: 5438ac42b9f301134301a97a8ff23bcb3f88f833efd8edf9c078f8262ba1b952ddf02fc5965e895211481fb7891856bf496f1e553572e5006189c41b2d2ce1d6
7
- data.tar.gz: f01651e471e499ab4d6aa03919299c3721361af37e4c2a5af1616a05cd4e87654efc776d23eae4427609967dbed2370367cf8b8e44bae61d46496e5804b28f50
6
+ metadata.gz: 5894b3780d532271a527bbf5786f3e075a2d66594f0e4bc9aedf4ce005ac4b09818bdb2d454ae01e6517916561a86ae33bda909a360ff8489acb04ca6a9c65b3
7
+ data.tar.gz: 0f02428836a28b643e19abfab35e0b26a2c99411a1f7b3fdab3655e5b70624eeafea83fb3368fb2fa4af3f4b36e214a8306d05f46339455beaccac1a440de7cf
data/README.md CHANGED
@@ -1,2 +1,71 @@
1
1
  rails_dialog
2
2
  ============
3
+
4
+ ```rails_dialog``` is sass mixin for rails to implement a dialog easily. This gem is based on [sass-dialog](https://github.com/tenbrother/sass-dialog).
5
+
6
+ ## Demonstration
7
+
8
+ You can try how this works [here](http://tenbrother.github.io/sass-dialog).
9
+ (This demonstration is based on [sass-dialog](https://github.com/tenbrother/sass-dialog) version, but works in the same way.)
10
+
11
+
12
+ ## Instration
13
+
14
+ Put these lines in your Gemfile and run the bundle command to install.
15
+
16
+ ```ruby
17
+ gem 'sass-rails'
18
+ gem 'compass-rails'
19
+ gem 'rails_dialog'
20
+ ```
21
+
22
+ Import ```rails_dialog```. (This is example of ```application.css.scss```)
23
+
24
+ ```sass
25
+ @import 'compass';
26
+ @import 'rails_dialog';
27
+ ```
28
+
29
+ ## Usage
30
+
31
+ ####HTML
32
+
33
+ Write nested div tags to express a dialog. Outer one needs a id attribute and a class attribute.
34
+ In addition, link or button to show dialog is necessary.
35
+
36
+ ```html
37
+ <div id="dialog" class="dialog">
38
+ <div>
39
+ <!-- Content in dialog -->
40
+ <h2>Dialog</h2>
41
+ <div>
42
+ <a href="javascript:void(0);" id="hide-link">Hide Dialog</a>
43
+ </div>
44
+ </div>
45
+ </div>
46
+
47
+ <a href="javascript:void(0);" id="show-link">Show Dialog</a>
48
+ ```
49
+
50
+ #### Sass
51
+
52
+ Include ```dialog``` mixin. You have to specify width and height of dialog as parameters.
53
+
54
+ ```scss
55
+ .dialog {
56
+ @include dialog(700px, 400px);
57
+ }
58
+ ```
59
+
60
+ #### Coffeescript
61
+
62
+ Javascript shows and hides the dialog.
63
+
64
+ ```coffeescript
65
+ $ ->
66
+ $('#show-link').click ->
67
+ $('#dialog').show()
68
+
69
+ $('#hide-link').click ->
70
+ $('#dialog').hide()
71
+ ```
@@ -1,3 +1,3 @@
1
1
  module RailsDialog
2
- VERSION = "0.0.1"
2
+ VERSION = "0.0.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rails_dialog
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Genki Sato
@@ -11,20 +11,21 @@ cert_chain: []
11
11
  date: 2014-10-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
- name: railties
14
+ name: rails
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
17
  - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: '3.1'
19
+ version: '3.0'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - ">="
25
25
  - !ruby/object:Gem::Version
26
- version: '3.1'
27
- description: sass mixin to implement a dialog easily
26
+ version: '3.0'
27
+ description: This is a rails plugin that provides a sass mixin to implement a dialog
28
+ easily
28
29
  email:
29
30
  - satogenki1115@gmail.com
30
31
  executables: []
@@ -33,7 +34,6 @@ extra_rdoc_files: []
33
34
  files:
34
35
  - LICENSE
35
36
  - README.md
36
- - Rakefile
37
37
  - lib/rails_dialog.rb
38
38
  - lib/rails_dialog/version.rb
39
39
  - vendor/assets/stylesheets/_rails_dialog.scss
data/Rakefile DELETED
@@ -1,7 +0,0 @@
1
- begin
2
- require 'bundler/setup'
3
- rescue LoadError
4
- puts 'You must `gem install bundler` and `bundle install` to run rake tasks'
5
- end
6
-
7
- Bundler::GemHelper.install_tasks