turbolinks-animate 2.0.1 → 2.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/LICENSE +0 -0
- data/README.md +0 -0
- data/app/helpers/turbolinks_animate_helper.rb +11 -3
- data/app/views/mozaic/_turbolinks-animate.html.erb +1 -1
- data/lib/turbolinks-animate.rb +4 -4
- data/lib/turbolinks-animate/engine.rb +4 -2
- data/lib/turbolinks-animate/railtie.rb +20 -19
- data/lib/turbolinks-animate/version.rb +3 -1
- metadata +34 -22
- data/CHANGELOG.md +0 -32
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 980874783a6f58bc209f2a2043f77b82775d9a177707786471ecae18e150a65d
|
4
|
+
data.tar.gz: 5d5b3eff69127cc8bdbbb89d9eeee1ec8d8ab5531c8766ac61dd3505c0ebdc43
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 60703ceb0768e68dd31fec5c5ddf8857b519edc2e712aad1dd895448a4cdbd1db664c77c7bef301f574d6d390541e5e5d49544bfebea0e6f41e7a2df41bd941f
|
7
|
+
data.tar.gz: 436b86ce6a0afe890b37d6383e00f5b42ff3e7e55d76adfdea38f6e9acc4d7a54a0da03a2169f96cfebc8084b1d542886af573534908f8d4b25a9140e69c5d45
|
data/LICENSE
CHANGED
File without changes
|
data/README.md
CHANGED
File without changes
|
@@ -1,7 +1,15 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module TurbolinksAnimateHelper
|
4
|
+
def turbolinks_animate(animation)
|
5
|
+
@turbolinks_animate_animation = turbolinks_animate_animation(animation)
|
6
|
+
end
|
7
|
+
|
8
|
+
private
|
2
9
|
|
3
|
-
|
4
|
-
|
5
|
-
end
|
10
|
+
def turbolinks_animate_animation(animation)
|
11
|
+
return animation.to_json if animation.is_a?(Hash)
|
6
12
|
|
13
|
+
animation
|
14
|
+
end
|
7
15
|
end
|
data/lib/turbolinks-animate.rb
CHANGED
@@ -1,8 +1,8 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
require 'turbolinks-animate/version'
|
2
4
|
|
3
5
|
module TurbolinksAnimate
|
4
|
-
|
5
|
-
|
6
|
-
require 'turbolinks-animate/railtie'
|
7
|
-
|
6
|
+
require 'turbolinks-animate/engine'
|
7
|
+
require 'turbolinks-animate/railtie'
|
8
8
|
end
|
@@ -1,28 +1,29 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
require 'rails/railtie'
|
2
4
|
require 'mozaic'
|
3
5
|
|
4
6
|
module TurbolinksAnimate
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
options[:class] += ( options[:class].length > 0 ? ' turbolinks-animate' : 'turbolinks-animate' )
|
13
|
-
options[:data] ||= {}
|
14
|
-
options[:data][:turbolinks_animate_animation] = animation
|
15
|
-
end
|
16
|
-
options
|
17
|
-
end
|
18
|
-
end
|
19
|
-
end
|
7
|
+
class Railtie < Rails::Railtie
|
8
|
+
initializer 'turbolinks-animate.mozaic' do
|
9
|
+
Mozaic.configure do |config|
|
10
|
+
config.define_component('turbolinks-animate',
|
11
|
+
element: 'body') do |options|
|
12
|
+
animation = options.delete :animation
|
13
|
+
return options unless animation
|
20
14
|
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
15
|
+
options[:class] = [options[:class], 'turbolinks-animate'].compact
|
16
|
+
.join(' ')
|
17
|
+
options[:data] ||= {}
|
18
|
+
options[:data][:turbolinks_animate_animation] = animation
|
25
19
|
end
|
20
|
+
end
|
21
|
+
end
|
26
22
|
|
23
|
+
initializer 'turbolinks-animate.action_controller' do
|
24
|
+
ActiveSupport.on_load :action_controller do
|
25
|
+
include TurbolinksAnimateHelper
|
26
|
+
end
|
27
27
|
end
|
28
|
+
end
|
28
29
|
end
|
metadata
CHANGED
@@ -1,71 +1,85 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: turbolinks-animate
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jonas Hübotter
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2019-05-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
|
-
name:
|
14
|
+
name: mozaic
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- - "
|
17
|
+
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '
|
19
|
+
version: '2.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: '
|
26
|
+
version: '2.0'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
|
-
name:
|
28
|
+
name: railties
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
31
|
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: '2
|
33
|
+
version: '5.2'
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - "~>"
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: '2
|
40
|
+
version: '5.2'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: rspec
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
|
-
- - "
|
45
|
+
- - ">="
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version: '
|
47
|
+
version: '0'
|
48
48
|
type: :development
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
|
-
- - "
|
52
|
+
- - ">="
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version: '
|
54
|
+
version: '0'
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: rubocop
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
|
-
- - "
|
59
|
+
- - ">="
|
60
60
|
- !ruby/object:Gem::Version
|
61
|
-
version: '0
|
61
|
+
version: '0'
|
62
62
|
type: :development
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
|
-
- - "
|
66
|
+
- - ">="
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: rubocop-rspec
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - ">="
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '0'
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - ">="
|
67
81
|
- !ruby/object:Gem::Version
|
68
|
-
version: '0
|
82
|
+
version: '0'
|
69
83
|
description: A dead simple & powerful way of adding rich & adaptive animations to
|
70
84
|
your Rails app which is already using Turbolinks™.
|
71
85
|
email: me@jonhue.me
|
@@ -73,7 +87,6 @@ executables: []
|
|
73
87
|
extensions: []
|
74
88
|
extra_rdoc_files: []
|
75
89
|
files:
|
76
|
-
- CHANGELOG.md
|
77
90
|
- LICENSE
|
78
91
|
- README.md
|
79
92
|
- app/helpers/turbolinks_animate_helper.rb
|
@@ -82,7 +95,7 @@ files:
|
|
82
95
|
- lib/turbolinks-animate/engine.rb
|
83
96
|
- lib/turbolinks-animate/railtie.rb
|
84
97
|
- lib/turbolinks-animate/version.rb
|
85
|
-
homepage: https://github.com/jonhue/turbolinks-animate
|
98
|
+
homepage: https://github.com/jonhue/turbolinks-animate-rails
|
86
99
|
licenses:
|
87
100
|
- MIT
|
88
101
|
metadata: {}
|
@@ -101,8 +114,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
101
114
|
- !ruby/object:Gem::Version
|
102
115
|
version: '0'
|
103
116
|
requirements: []
|
104
|
-
|
105
|
-
rubygems_version: 2.7.6
|
117
|
+
rubygems_version: 3.0.3
|
106
118
|
signing_key:
|
107
119
|
specification_version: 4
|
108
120
|
summary: Rich & adaptive animations for apps using Rails w/ Turbolinks™
|
data/CHANGELOG.md
DELETED
@@ -1,32 +0,0 @@
|
|
1
|
-
# Changelog
|
2
|
-
|
3
|
-
### master
|
4
|
-
|
5
|
-
* nothing yet
|
6
|
-
|
7
|
-
### 2.0.0 - 2018/02/17
|
8
|
-
|
9
|
-
* features
|
10
|
-
* support webpack
|
11
|
-
* added `'turbolinks-animate'` mozaic component
|
12
|
-
|
13
|
-
### 1.3.0 - 2018/01/19
|
14
|
-
|
15
|
-
* enhancements
|
16
|
-
* updated [turbolinks-animate.js](https://github.com/jonhue/turbolinks-animate.js) to `2.0.0`
|
17
|
-
|
18
|
-
### 1.2.0 - 2018/01/06
|
19
|
-
|
20
|
-
* enhancements
|
21
|
-
* automatically include `TurbolinksAnimateHelper` in controllers
|
22
|
-
* updated [turbolinks-animate.js](https://github.com/jonhue/turbolinks-animate.js) to `1.3.8`
|
23
|
-
|
24
|
-
### 1.1.0 - 2017/12/17
|
25
|
-
|
26
|
-
* enhancements
|
27
|
-
* add animate.css to asset pipeline
|
28
|
-
* bugfixes
|
29
|
-
|
30
|
-
### 1.0.0 - 2017/12/17
|
31
|
-
|
32
|
-
* initial release
|