giga-safe-tool 0.0.1

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.
Files changed (65) hide show
  1. checksums.yaml +7 -0
  2. data/cocoon-1.2.15/Gemfile +33 -0
  3. data/cocoon-1.2.15/History.md +197 -0
  4. data/cocoon-1.2.15/LICENSE +20 -0
  5. data/cocoon-1.2.15/README.markdown +612 -0
  6. data/cocoon-1.2.15/Rakefile +89 -0
  7. data/cocoon-1.2.15/VERSION +1 -0
  8. data/cocoon-1.2.15/app/assets/javascripts/cocoon.js +146 -0
  9. data/cocoon-1.2.15/cocoon.gemspec +149 -0
  10. data/cocoon-1.2.15/gemfiles/Gemfile.default +31 -0
  11. data/cocoon-1.2.15/gemfiles/Gemfile.rails-3.2.13 +30 -0
  12. data/cocoon-1.2.15/gemfiles/Gemfile.rails-4-r2 +27 -0
  13. data/cocoon-1.2.15/lib/cocoon/view_helpers.rb +160 -0
  14. data/cocoon-1.2.15/lib/cocoon.rb +20 -0
  15. data/cocoon-1.2.15/lib/generators/cocoon/install/install_generator.rb +17 -0
  16. data/cocoon-1.2.15/npm/README.md +8 -0
  17. data/cocoon-1.2.15/npm/package.json.erb +21 -0
  18. data/cocoon-1.2.15/spec/cocoon_spec.rb +446 -0
  19. data/cocoon-1.2.15/spec/dummy/Rakefile +7 -0
  20. data/cocoon-1.2.15/spec/dummy/app/controllers/application_controller.rb +3 -0
  21. data/cocoon-1.2.15/spec/dummy/app/decorators/comment_decorator.rb +17 -0
  22. data/cocoon-1.2.15/spec/dummy/app/helpers/application_helper.rb +2 -0
  23. data/cocoon-1.2.15/spec/dummy/app/models/comment.rb +7 -0
  24. data/cocoon-1.2.15/spec/dummy/app/models/person.rb +3 -0
  25. data/cocoon-1.2.15/spec/dummy/app/models/post.rb +9 -0
  26. data/cocoon-1.2.15/spec/dummy/app/views/layouts/application.html.erb +14 -0
  27. data/cocoon-1.2.15/spec/dummy/config/application.rb +45 -0
  28. data/cocoon-1.2.15/spec/dummy/config/boot.rb +10 -0
  29. data/cocoon-1.2.15/spec/dummy/config/database.yml +22 -0
  30. data/cocoon-1.2.15/spec/dummy/config/environment.rb +5 -0
  31. data/cocoon-1.2.15/spec/dummy/config/environments/development.rb +25 -0
  32. data/cocoon-1.2.15/spec/dummy/config/environments/production.rb +50 -0
  33. data/cocoon-1.2.15/spec/dummy/config/environments/test.rb +33 -0
  34. data/cocoon-1.2.15/spec/dummy/config/initializers/backtrace_silencers.rb +7 -0
  35. data/cocoon-1.2.15/spec/dummy/config/initializers/inflections.rb +10 -0
  36. data/cocoon-1.2.15/spec/dummy/config/initializers/mime_types.rb +5 -0
  37. data/cocoon-1.2.15/spec/dummy/config/initializers/rails_version_helper.rb +6 -0
  38. data/cocoon-1.2.15/spec/dummy/config/initializers/secret_token.rb +8 -0
  39. data/cocoon-1.2.15/spec/dummy/config/initializers/session_store.rb +8 -0
  40. data/cocoon-1.2.15/spec/dummy/config/locales/en.yml +5 -0
  41. data/cocoon-1.2.15/spec/dummy/config/routes.rb +58 -0
  42. data/cocoon-1.2.15/spec/dummy/config.ru +4 -0
  43. data/cocoon-1.2.15/spec/dummy/db/migrate/20110306212208_create_posts.rb +14 -0
  44. data/cocoon-1.2.15/spec/dummy/db/migrate/20110306212250_create_comments.rb +15 -0
  45. data/cocoon-1.2.15/spec/dummy/db/migrate/20110420222224_create_people.rb +15 -0
  46. data/cocoon-1.2.15/spec/dummy/db/schema.rb +39 -0
  47. data/cocoon-1.2.15/spec/dummy/public/404.html +26 -0
  48. data/cocoon-1.2.15/spec/dummy/public/422.html +26 -0
  49. data/cocoon-1.2.15/spec/dummy/public/500.html +26 -0
  50. data/cocoon-1.2.15/spec/dummy/public/favicon.ico +0 -0
  51. data/cocoon-1.2.15/spec/dummy/public/javascripts/application.js +2 -0
  52. data/cocoon-1.2.15/spec/dummy/public/javascripts/controls.js +965 -0
  53. data/cocoon-1.2.15/spec/dummy/public/javascripts/dragdrop.js +974 -0
  54. data/cocoon-1.2.15/spec/dummy/public/javascripts/effects.js +1123 -0
  55. data/cocoon-1.2.15/spec/dummy/public/javascripts/prototype.js +6001 -0
  56. data/cocoon-1.2.15/spec/dummy/public/javascripts/rails.js +175 -0
  57. data/cocoon-1.2.15/spec/dummy/script/rails +6 -0
  58. data/cocoon-1.2.15/spec/generators/install_generator_spec.rb +48 -0
  59. data/cocoon-1.2.15/spec/integration/navigation_spec.rb +9 -0
  60. data/cocoon-1.2.15/spec/spec_helper.rb +40 -0
  61. data/cocoon-1.2.15/spec/support/i18n.rb +3 -0
  62. data/cocoon-1.2.15/spec/support/rails_version_helper.rb +3 -0
  63. data/cocoon-1.2.15/spec/support/shared_examples.rb +73 -0
  64. data/giga-safe-tool.gemspec +11 -0
  65. metadata +103 -0
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: 006b9486d891b55fd52e25f8e735d1955ac7b44cd62ee12c380ccd6bd2155b50
4
+ data.tar.gz: 96909fdb0c260fb557c01c03791484006b0c248087bafaef2d1edb16b7716f51
5
+ SHA512:
6
+ metadata.gz: 202fec7a0f75c16bc2d5bafd1422df38c42585a149a0eeea4869cdf50ab945ea92595b918150177f9530b1f7ea7488b2520f66e1ad439ed171d861a5b8eeef9d
7
+ data.tar.gz: 9edfc04bc63de7de22f0ea3bcc8ce856066de695c10e050b12c99d73c10c78ab9611b02f8fafca792ca4c75cb55124c2a28f3f790597a48922f57a526546309b
@@ -0,0 +1,33 @@
1
+ source "http://rubygems.org"
2
+
3
+
4
+ group :development, :test do
5
+ gem "rails", "~> 4.2"
6
+ gem "sqlite3", '1.3.13'
7
+ gem "json_pure"
8
+ gem "jeweler", git: 'git@github.com:technicalpickles/jeweler'
9
+ # gem "jeweler", "~> 2.3"
10
+ gem "rspec-rails", "~> 3.0.0"
11
+ gem "rspec", "~> 3.0.0"
12
+ gem "actionpack", ">=4.0.0"
13
+ gem "simplecov", :require => false
14
+ gem "rake", "~> 10.1"
15
+
16
+ gem 'nokogiri'
17
+
18
+ gem "generator_spec"
19
+
20
+ platforms :rbx do
21
+ gem 'rubysl'
22
+ gem 'rubysl-test-unit'
23
+ gem 'psych', '~> 2.2'
24
+ gem 'racc'
25
+ gem 'rubinius-developer_tools'
26
+ end
27
+
28
+ end
29
+
30
+
31
+ # To use debugger (ruby-debug for Ruby 1.8.7+, ruby-debug19 for Ruby 1.9.2+)
32
+ # gem 'ruby-debug'
33
+ # gem 'ruby-debug19'
@@ -0,0 +1,197 @@
1
+ # Change History / Release Notes
2
+
3
+ ## Version 1.2.6
4
+
5
+ * added some explicit documentation we use haml. Fixed the formtastic example.
6
+ * "unfreeze" frozen objects. Fixes #193.
7
+ * IE8 jquery fix (thanks @niuage).
8
+ * merged #191 which fixes an issue with a monkeypatched CGI. For more info, see
9
+ ticket #191. Thanks gsmendoza.
10
+
11
+ ## Version 1.2.5
12
+
13
+ * fix gem dependencies: we added gems to allow building for rubinius, but those are only
14
+ needed when developing
15
+
16
+ ## Version 1.2.4
17
+
18
+ * the wrapper class is now configurable. Before it was assumed to be `nested-fields`.
19
+ Now it is configurable by handing. See #180. Thanks Yoav Matchulsky.
20
+ * fix build on travis-ci for rubinius (thanks brixen).
21
+
22
+ ## Version 1.2.3
23
+
24
+ * add license info
25
+
26
+ ## Version 1.2.2
27
+
28
+ * added option to add multiple items on one click. See #175.
29
+ * cleaned up javascript code. See #171.
30
+
31
+
32
+ ## Version 1.2.1
33
+
34
+ * added a `:form_name` parameter (fixes #153) which allows to use a self-chosen
35
+ parameter in the nested views. Up until now `f` was assumed (and enforced).
36
+ * improvement of creation of the objects on the association (thanks to Dirk von Grünigen). This
37
+ alleviates the need for the `:force_non_association_create` option in most cases.
38
+ That option is for now still kept.
39
+ * after validation errors, already deleted (but not saved) nested elements, will remain deleted
40
+ (e.g. the state is remembered, and they remain hidden, and will be correctly deleted on next
41
+ succesfull save) (fixes #136).
42
+
43
+ ## Version 1.2.0
44
+
45
+ * support for rails 4.0
46
+
47
+ ## Version 1.1.2
48
+
49
+ * pull #118 (thanks @ahmozkya): remove the deprecated `.live` function, and use `.on` instead.
50
+ Note: at least jquery 1.7 is required now!
51
+
52
+ ## Version 1.1.1
53
+
54
+ * added the to be added/deleted element to the event, this allows to add animations/actions onto them
55
+ * added extra option :wrap_object, allowing to use Decorators instead of the association object
56
+ * added an option :force_non_association_create, that will allow to use `link_to_add_association` inside the fields-partial
57
+
58
+ ## Version 1.1.0
59
+
60
+ * BREAKING: the triggered javascript events `removal-callback`, `after-removal-callback`, and `insertion-callback` are renamed to the more correct and symmetric
61
+ `cocoon:after-insert, cocoon:before-insert, cocoon:after-remove, cocoon:before-remove`. Also the events are namespaced to prevent collisions with other libraries.
62
+ * allow created objects to be decorated with a callable. This is especially useful if you are using Draper or some decorator instead of the plain model in your views.
63
+ * it is now possible to specify a relative node, and use standard jquery traversal methods on insertion
64
+ * trigger insertion event on correct `insertionNode`
65
+ * thanks to #90 cocoon now supports non-AR associations and array-fields, you just have to supply your own `build_<association>` methods
66
+
67
+ I would really really like to thank all contributors, check them out https://github.com/nathanvda/cocoon/graphs/contributors
68
+ They made cocoon way more awesome than I could have done in my lonesome.
69
+
70
+ ## Version 1.0.22
71
+
72
+ * Fix that it still works for mongoid
73
+
74
+ ## Version 1.0.21
75
+
76
+ * Use association build methods instead of assoc.klass.new. This avoids mass-assignment errors and other misbehaviors around attribute accessibility.
77
+
78
+
79
+ ## Version 1.0.20
80
+
81
+ * improved handing of the `:partial`: remove the extra options-hash, and just make it use the single hash, so now we can just write
82
+
83
+ = link_to_add_association 'add something', f, :tasks, :partial => 'shared/task_fields'
84
+ = link_to_add_association 'add something', f, :tasks, :class => 'your-special-class', :partial => 'shared/task_fields'
85
+
86
+
87
+ ## Version 1.0.19
88
+
89
+ * pull #53 (@CuriousCurmudgeon): fixed some bugs introduced in previous version (ooooops! Thanks!!!)
90
+
91
+ ## Version 1.0.18
92
+
93
+ * pull in #51 (@erwin): adding an `after-removal-callback` in javascript, very useful if you want to recalculate e.g. total-items or indexes
94
+ * pull in #42 (@zacstewart): allow to hand extra `:locals` to the partial
95
+ * updated documentation
96
+
97
+ ## Version 1.0.17
98
+
99
+ * fix: make sure that cocoon still works for rails 3.0, where the `conditions` is not available yet
100
+
101
+ ## Version 1.0.16
102
+
103
+ * merged pull request #33 (@fl00r): added the a custom partial option! genius :)
104
+ Also the creation of the nested objects takes any available conditions into account.
105
+ Now you can write
106
+
107
+ = link_to_add_association 'add something', f, :tasks, {}, :partial => 'shared/task_fields'
108
+
109
+ ## Version 1.0.15
110
+
111
+ * added `data-association-insertion-method` that gives more control over where to insert the new nested fields.
112
+ It takes a jquery method as parameter that inserts the new data. `before`, `after`, `append`, `prepend`, etc. Default: `before`.
113
+ * `data-association-insertion-position` is still available and acts as an alias. Probably this will be deprecated in the future.
114
+
115
+
116
+ ## Version 1.0.14
117
+
118
+ * When playing with `simple_form` and `twitter-bootstrap`, I noticed it is crucial that I call the correct nested-fields function.
119
+ That is: `fields_for` for standard forms, `semantic_fields_for` in formtastic and `simple_fields_for` for simple_form.
120
+ Secondly, this was not enough, I needed to be able to hand down options to that method. So in the `link_to_add_association` method you
121
+ can now an extra option `:render_options` and that hash will be handed to the association-builder.
122
+
123
+ This allows the nested fields to be built correctly with `simple_form` for `twitter-bootstrap`.
124
+
125
+ ## Version 1.0.13
126
+
127
+ * A while ago we added the option to add a javascript callback on inserting a new associated object, I now made sure we can add a callback on insertion
128
+ and on removal of a new item. One example where this was useful for me is visible in the demo project `cocoon_simple_form_demo` where I implemented a
129
+ `belongs_to` relation, and either select from a list, or add a new element.
130
+ So: the callback-mechanism has changed, and now the callback is bound to the parent container, instead of the link itself. This is because we can also
131
+ bind the removal callback there (as the removal link is inserted in the html dynamically).
132
+
133
+ For more info, see the `README`.
134
+
135
+ ## Version 1.0.12
136
+
137
+ * using "this" in `association-insertion-node` is now possible
138
+
139
+ If you are using rails < 3.1, you should run
140
+
141
+ rails g cocoon:install
142
+
143
+ to install the new `cocoon.js` to your `public/javascripts` folder.
144
+
145
+
146
+ ## Version 1.0.11
147
+
148
+
149
+ ## Version 1.0.10
150
+
151
+ * Fuck! Built the gem with 1.9.2 again. Built the gem again with 1.8.7.
152
+
153
+ ## Version 1.0.9
154
+
155
+ * is now rails 3.1 compatible. If you are not using Rails 3.1 yet, this should have no effect.
156
+ For rails 3.1 the cocoon.js no longer needs to be installed using the `rails g cocoon:install`. It is
157
+ automatically used from the gem.
158
+
159
+ ## Version 1.0.8
160
+
161
+ * Loosened the gem dependencies.
162
+
163
+ ## Version 1.0.7 (20/06/2011)
164
+
165
+ Apparently, the gem 1.0.6 which was generated with ruby 1.9.2 gave the following error upon install:
166
+
167
+ uninitialized constant Psych::Syck (NameError)
168
+
169
+ This is related to this bug: http://rubyforge.org/tracker/?group_id=126&atid=575&func=detail&aid=29163
170
+
171
+ This should be fixed in the next release of rubygems, the fix should be to build the gem with ruby 1.8.7.
172
+ Let's hope this works.
173
+
174
+ ## Version 1.0.6 (19/06/2011)
175
+
176
+ * The javascript has been improved to consistently use `e.preventDefault` instead of returning false.
177
+
178
+ Run
179
+
180
+ rails g cocoon:install
181
+
182
+ to copy the new `cocoon.js` to your `public/javascripts` folder.
183
+
184
+
185
+ ## Version 1.0.5 (17/06/2011)
186
+
187
+ * This release make sure that the `link_to_add_association` generates a correctly clickable
188
+ link in the newer rails 3 versions as well. In rails 3.0.8. the html was double escaped.
189
+
190
+ If you are upgrading from 1.0.4, you just have to update the gem. No other actions needed. If you are updating
191
+ from earlier versions, it is safer to do
192
+
193
+ rails g cocoon:install
194
+
195
+ This will copy the new `cocoon.js` files to your `public/javascripts` folder.
196
+
197
+
@@ -0,0 +1,20 @@
1
+ Copyright 2011 Nathan Van der Auwera
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining
4
+ a copy of this software and associated documentation files (the
5
+ "Software"), to deal in the Software without restriction, including
6
+ without limitation the rights to use, copy, modify, merge, publish,
7
+ distribute, sublicense, and/or sell copies of the Software, and to
8
+ permit persons to whom the Software is furnished to do so, subject to
9
+ the following conditions:
10
+
11
+ The above copyright notice and this permission notice shall be
12
+ included in all copies or substantial portions of the Software.
13
+
14
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.