effective_bootstrap 0.5.0 → 0.5.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.
- checksums.yaml +4 -4
- data/README.md +10 -0
- data/app/assets/javascripts/effective_bootstrap/form.js.coffee +7 -1
- data/lib/effective_bootstrap/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: 749c6eac407a8fd876e7670f4d2383a662001e78
|
4
|
+
data.tar.gz: 40d6162703c6beea2754367463a7352b69b035d5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4bcc5cc2e67a2359785ff91f662190283fd0714ed36c8f693ae672d47841c67690920108bcac9ddf9d94f78bd5c457c82097badf75fe7c4f41889dc80b54b277
|
7
|
+
data.tar.gz: 356a9b163c2465efc79df11274911ffeb65f72a2af1bb855be3761e02f4d08017d41432e06674a9cc81d13fc9e5f073b467af3fcd86b9ec53091cbab3f779d0d
|
data/README.md
CHANGED
@@ -48,6 +48,16 @@ And to your `application.scss`:
|
|
48
48
|
|
49
49
|
## View Helpers
|
50
50
|
|
51
|
+
### Collapse
|
52
|
+
|
53
|
+
https://getbootstrap.com/docs/4.0/components/collapse/
|
54
|
+
|
55
|
+
```haml
|
56
|
+
= collapse('Click to collapse') do
|
57
|
+
%p You have revealed me!
|
58
|
+
```
|
59
|
+
|
60
|
+
|
51
61
|
### Dropdown
|
52
62
|
|
53
63
|
https://getbootstrap.com/docs/4.0/components/dropdowns/
|
@@ -144,7 +144,13 @@ this.EffectiveForm ||= new class
|
|
144
144
|
# Sets EffectiveBootstrap. current_click.
|
145
145
|
# This displays the spinner here, and directs any flash messages before and after loadRemoteForm
|
146
146
|
$(document).on 'click', '.form-actions a[data-remote],.form-actions button[type=submit]', (event) ->
|
147
|
-
|
147
|
+
$submit = $(@)
|
148
|
+
$form = $submit.closest('form')
|
149
|
+
|
150
|
+
if ($form.attr('method') || '').toLowerCase() == 'get'
|
151
|
+
setTimeout((-> EffectiveForm.reset($form)), 2000)
|
152
|
+
|
153
|
+
EffectiveForm.setCurrentSubmit($submit.parent())
|
148
154
|
EffectiveForm.spin()
|
149
155
|
|
150
156
|
# This actually attached the handlers to a remote ajax form when it or an action inside it triggers a remote thing.
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: effective_bootstrap
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.5.
|
4
|
+
version: 0.5.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Code and Effect
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-04-
|
11
|
+
date: 2019-04-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|