cocoon 1.0.11 → 1.0.12

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.
data/History.md CHANGED
@@ -1,5 +1,18 @@
1
1
  # Change History / Release Notes
2
2
 
3
+ ## Version 1.0.12
4
+
5
+ * using "this" in `association-insertion-node` is now possible
6
+
7
+ If you are using rails < 3.1, you should run
8
+
9
+ rails g cocoon:install
10
+
11
+ to install the new `cocoon.js` to your `public/javascripts` folder.
12
+
13
+ ## Version 1.0.11
14
+
15
+
3
16
  ## Version 1.0.10
4
17
 
5
18
  * Fuck! Built the gem with 1.9.2 again. Built the gem again with 1.8.7.
data/README.markdown CHANGED
@@ -24,6 +24,15 @@ Inside your `Gemfile` add the following:
24
24
 
25
25
  gem "cocoon"
26
26
 
27
+ ### Rails 3.1
28
+
29
+ Add the following to `application.js` so it compiles to the
30
+ asset_pipeline
31
+
32
+ `//= require cocoon`
33
+
34
+ ### Rails 3.x
35
+
27
36
  If you are using Rails 3.0.x, you need to run the installation task (since rails 3.1 this is no longer needed):
28
37
 
29
38
  rails g cocoon:install
@@ -92,7 +101,7 @@ and inside the `_task_fields` partial we write:
92
101
 
93
102
  That is all there is to it!
94
103
 
95
- There is an example project on github implementing it called [formtastic-cocoon-demo](https://github.com/nathanvda/formtastic-cocoon-demo).
104
+ There is an example project on github implementing it called [formtastic-cocoon-demo](https://github.com/nathanvda/formtastic_cocoon_demo).
96
105
 
97
106
  ### Using simple_form
98
107
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.0.11
1
+ 1.0.12
@@ -29,7 +29,7 @@ $(document).ready(function() {
29
29
  new_content = new_content.replace(regexp_underscord, newcontent_underscord);
30
30
 
31
31
  if (insertionNode){
32
- insertionNode = $(insertionNode);
32
+ insertionNode = insertionNode == "this" ? $(this) : $(insertionNode);
33
33
  } else {
34
34
  insertionNode = $(this).parent();
35
35
  }
data/cocoon.gemspec CHANGED
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{cocoon}
8
- s.version = "1.0.11"
8
+ s.version = "1.0.12"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Nathan Van der Auwera"]
12
- s.date = %q{2011-07-28}
12
+ s.date = %q{2011-08-25}
13
13
  s.description = %q{Unobtrusive nested forms handling, using jQuery. Use this and discover cocoon-heaven.}
14
14
  s.email = %q{nathan@dixis.com}
15
15
  s.extra_rdoc_files = [
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cocoon
3
3
  version: !ruby/object:Gem::Version
4
- hash: 1
4
+ hash: 15
5
5
  prerelease:
6
6
  segments:
7
7
  - 1
8
8
  - 0
9
- - 11
10
- version: 1.0.11
9
+ - 12
10
+ version: 1.0.12
11
11
  platform: ruby
12
12
  authors:
13
13
  - Nathan Van der Auwera
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2011-07-28 00:00:00 +02:00
18
+ date: 2011-08-25 00:00:00 +02:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency