effective_bootstrap 0.9.41 → 0.9.42
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5bfd09a27598da184de3a2f8208d36db4ac3021c76946dc45f7c7c81ed0d0b1f
|
4
|
+
data.tar.gz: e62446f65854520af700752157415cf606d18b43ac631726394c26895a8df705
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2ca774aa86d286554166d8780d0a8ba4ddbe187f4decb5295e83728d63b5b5eb7723abd5bf1aa74881ca36c983c94d2fc8b88fb6ed58fbdc7759287ae7886a70
|
7
|
+
data.tar.gz: 9f15e36d568891a388fd9c788887f9fadd195d5bc81d06bf04ba899161a76a55a676850311f41efbb0ec55458b523091c36ca86ddfe430e282b9d402d875fdd7
|
@@ -4,19 +4,27 @@ if <%= !!EffectiveBootstrap.use_custom_data_confirm %> && (window.Rails || $.rai
|
|
4
4
|
$(document).on 'confirm', (event) ->
|
5
5
|
$obj = $(event.target)
|
6
6
|
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
7
|
+
# Already confirmed
|
8
|
+
return true if $obj.data('confirmed')
|
9
|
+
|
10
|
+
# Otherwise unconfirmed
|
11
|
+
$obj.data('confirm-original', $obj.html())
|
12
|
+
$obj.html($obj.data('confirm'))
|
13
|
+
$obj.data('confirmed', true)
|
14
|
+
|
15
|
+
# When using the direct to s3 active storage javascript library
|
16
|
+
$activeStorageUpload = $obj.closest('form').find('input[type=file][data-direct-upload-url]')
|
17
|
+
|
18
|
+
if $activeStorageUpload.length == 0
|
13
19
|
setTimeout(
|
14
20
|
(->
|
15
21
|
$obj.data('confirmed', false)
|
16
22
|
$obj.html($obj.data('confirm-original'))
|
17
23
|
)
|
18
24
|
, 4000)
|
19
|
-
|
25
|
+
|
26
|
+
# Do not display the confirmation dialog
|
27
|
+
false
|
20
28
|
|
21
29
|
if window.Rails
|
22
30
|
window.Rails.confirm = (message) -> true
|
@@ -13,7 +13,12 @@ $(document).on 'direct-upload:error', (event) ->
|
|
13
13
|
$("[data-direct-upload-id=#{event.detail.id}]").addClass('direct-upload--error').attr('title', event.detail.error)
|
14
14
|
|
15
15
|
$(document).on 'direct-upload:end', (event) ->
|
16
|
-
$("[data-direct-upload-id=#{event.detail.id}]")
|
16
|
+
$obj = $("[data-direct-upload-id=#{event.detail.id}]")
|
17
|
+
|
18
|
+
$obj.addClass('direct-upload--complete')
|
19
|
+
|
20
|
+
# Rails UJS fix
|
21
|
+
$obj.closest('form').find('[type=submit][data-confirm]').data('confirmed', true)
|
17
22
|
|
18
23
|
$(document).on 'change', "input[type='file'][data-click-submit]", (event) ->
|
19
24
|
$(event.currentTarget).closest('form').find('button[type=submit],input[type=submit]').first().click()
|
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.9.
|
4
|
+
version: 0.9.42
|
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: 2021-09-
|
11
|
+
date: 2021-09-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|