wiselinks 0.4.1 → 0.4.2
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/Gemfile +2 -2
- data/Gemfile.lock +36 -40
- data/README.md +19 -1
- data/VERSION +1 -1
- data/lib/assets/javascripts/wiselinks.js.coffee +2 -2
- data/wiselinks.gemspec +5 -5
- metadata +7 -7
data/Gemfile
CHANGED
data/Gemfile.lock
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
GEM
|
|
2
2
|
remote: http://rubygems.org/
|
|
3
3
|
specs:
|
|
4
|
-
actionmailer (3.2.
|
|
5
|
-
actionpack (= 3.2.
|
|
4
|
+
actionmailer (3.2.11)
|
|
5
|
+
actionpack (= 3.2.11)
|
|
6
6
|
mail (~> 2.4.4)
|
|
7
|
-
actionpack (3.2.
|
|
8
|
-
activemodel (= 3.2.
|
|
9
|
-
activesupport (= 3.2.
|
|
7
|
+
actionpack (3.2.11)
|
|
8
|
+
activemodel (= 3.2.11)
|
|
9
|
+
activesupport (= 3.2.11)
|
|
10
10
|
builder (~> 3.0.0)
|
|
11
11
|
erubis (~> 2.7.0)
|
|
12
12
|
journey (~> 1.0.4)
|
|
@@ -14,21 +14,20 @@ GEM
|
|
|
14
14
|
rack-cache (~> 1.2)
|
|
15
15
|
rack-test (~> 0.6.1)
|
|
16
16
|
sprockets (~> 2.2.1)
|
|
17
|
-
activemodel (3.2.
|
|
18
|
-
activesupport (= 3.2.
|
|
17
|
+
activemodel (3.2.11)
|
|
18
|
+
activesupport (= 3.2.11)
|
|
19
19
|
builder (~> 3.0.0)
|
|
20
|
-
activerecord (3.2.
|
|
21
|
-
activemodel (= 3.2.
|
|
22
|
-
activesupport (= 3.2.
|
|
20
|
+
activerecord (3.2.11)
|
|
21
|
+
activemodel (= 3.2.11)
|
|
22
|
+
activesupport (= 3.2.11)
|
|
23
23
|
arel (~> 3.0.2)
|
|
24
24
|
tzinfo (~> 0.3.29)
|
|
25
|
-
activeresource (3.2.
|
|
26
|
-
activemodel (= 3.2.
|
|
27
|
-
activesupport (= 3.2.
|
|
28
|
-
activesupport (3.2.
|
|
25
|
+
activeresource (3.2.11)
|
|
26
|
+
activemodel (= 3.2.11)
|
|
27
|
+
activesupport (= 3.2.11)
|
|
28
|
+
activesupport (3.2.11)
|
|
29
29
|
i18n (~> 0.6)
|
|
30
30
|
multi_json (~> 1.0)
|
|
31
|
-
addressable (2.3.2)
|
|
32
31
|
arel (3.0.2)
|
|
33
32
|
bourne (1.1.2)
|
|
34
33
|
mocha (= 0.10.5)
|
|
@@ -40,7 +39,7 @@ GEM
|
|
|
40
39
|
rack-test (>= 0.5.4)
|
|
41
40
|
selenium-webdriver (~> 2.0)
|
|
42
41
|
xpath (~> 1.0.0)
|
|
43
|
-
childprocess (0.3.
|
|
42
|
+
childprocess (0.3.7)
|
|
44
43
|
ffi (~> 1.0, >= 1.0.6)
|
|
45
44
|
coffee-rails (3.2.2)
|
|
46
45
|
coffee-script (>= 2.2.0)
|
|
@@ -53,11 +52,11 @@ GEM
|
|
|
53
52
|
erubis (2.7.0)
|
|
54
53
|
execjs (1.4.0)
|
|
55
54
|
multi_json (~> 1.0)
|
|
56
|
-
factory_girl (4.
|
|
55
|
+
factory_girl (4.2.0)
|
|
57
56
|
activesupport (>= 3.0.0)
|
|
58
57
|
faker (1.1.2)
|
|
59
58
|
i18n (~> 0.5)
|
|
60
|
-
ffi (1.
|
|
59
|
+
ffi (1.3.1)
|
|
61
60
|
git (1.2.5)
|
|
62
61
|
hike (1.2.1)
|
|
63
62
|
i18n (0.6.1)
|
|
@@ -68,9 +67,6 @@ GEM
|
|
|
68
67
|
rdoc
|
|
69
68
|
journey (1.0.4)
|
|
70
69
|
json (1.7.6)
|
|
71
|
-
libwebsocket (0.1.7.1)
|
|
72
|
-
addressable
|
|
73
|
-
websocket
|
|
74
70
|
mail (2.4.4)
|
|
75
71
|
i18n (>= 0.4.0)
|
|
76
72
|
mime-types (~> 1.16)
|
|
@@ -82,24 +78,24 @@ GEM
|
|
|
82
78
|
multi_json (1.5.0)
|
|
83
79
|
nokogiri (1.5.6)
|
|
84
80
|
polyglot (0.3.3)
|
|
85
|
-
rack (1.4.
|
|
81
|
+
rack (1.4.4)
|
|
86
82
|
rack-cache (1.2)
|
|
87
83
|
rack (>= 0.4)
|
|
88
84
|
rack-ssl (1.3.2)
|
|
89
85
|
rack
|
|
90
86
|
rack-test (0.6.2)
|
|
91
87
|
rack (>= 1.0)
|
|
92
|
-
rails (3.2.
|
|
93
|
-
actionmailer (= 3.2.
|
|
94
|
-
actionpack (= 3.2.
|
|
95
|
-
activerecord (= 3.2.
|
|
96
|
-
activeresource (= 3.2.
|
|
97
|
-
activesupport (= 3.2.
|
|
88
|
+
rails (3.2.11)
|
|
89
|
+
actionmailer (= 3.2.11)
|
|
90
|
+
actionpack (= 3.2.11)
|
|
91
|
+
activerecord (= 3.2.11)
|
|
92
|
+
activeresource (= 3.2.11)
|
|
93
|
+
activesupport (= 3.2.11)
|
|
98
94
|
bundler (~> 1.0)
|
|
99
|
-
railties (= 3.2.
|
|
100
|
-
railties (3.2.
|
|
101
|
-
actionpack (= 3.2.
|
|
102
|
-
activesupport (= 3.2.
|
|
95
|
+
railties (= 3.2.11)
|
|
96
|
+
railties (3.2.11)
|
|
97
|
+
actionpack (= 3.2.11)
|
|
98
|
+
activesupport (= 3.2.11)
|
|
103
99
|
rack-ssl (~> 1.3.2)
|
|
104
100
|
rake (>= 0.8.7)
|
|
105
101
|
rdoc (~> 3.4)
|
|
@@ -114,8 +110,8 @@ GEM
|
|
|
114
110
|
rspec-core (2.12.2)
|
|
115
111
|
rspec-expectations (2.12.1)
|
|
116
112
|
diff-lcs (~> 1.1.3)
|
|
117
|
-
rspec-mocks (2.12.
|
|
118
|
-
rspec-rails (2.12.
|
|
113
|
+
rspec-mocks (2.12.2)
|
|
114
|
+
rspec-rails (2.12.2)
|
|
119
115
|
actionpack (>= 3.0)
|
|
120
116
|
activesupport (>= 3.0)
|
|
121
117
|
railties (>= 3.0)
|
|
@@ -123,11 +119,11 @@ GEM
|
|
|
123
119
|
rspec-expectations (~> 2.12.0)
|
|
124
120
|
rspec-mocks (~> 2.12.0)
|
|
125
121
|
rubyzip (0.9.9)
|
|
126
|
-
selenium-webdriver (2.
|
|
122
|
+
selenium-webdriver (2.29.0)
|
|
127
123
|
childprocess (>= 0.2.5)
|
|
128
|
-
libwebsocket (~> 0.1.3)
|
|
129
124
|
multi_json (~> 1.0)
|
|
130
125
|
rubyzip
|
|
126
|
+
websocket (~> 1.0.4)
|
|
131
127
|
shoulda (3.3.2)
|
|
132
128
|
shoulda-context (~> 1.0.1)
|
|
133
129
|
shoulda-matchers (~> 1.4.1)
|
|
@@ -140,14 +136,14 @@ GEM
|
|
|
140
136
|
multi_json (~> 1.0)
|
|
141
137
|
rack (~> 1.0)
|
|
142
138
|
tilt (~> 1.1, != 1.3.0)
|
|
143
|
-
sqlite3 (1.3.
|
|
144
|
-
thor (0.
|
|
139
|
+
sqlite3 (1.3.7)
|
|
140
|
+
thor (0.17.0)
|
|
145
141
|
tilt (1.3.3)
|
|
146
142
|
treetop (1.4.12)
|
|
147
143
|
polyglot
|
|
148
144
|
polyglot (>= 0.3.1)
|
|
149
145
|
tzinfo (0.3.35)
|
|
150
|
-
websocket (1.0.
|
|
146
|
+
websocket (1.0.7)
|
|
151
147
|
xpath (1.0.0)
|
|
152
148
|
nokogiri (~> 1.3)
|
|
153
149
|
|
|
@@ -162,7 +158,7 @@ DEPENDENCIES
|
|
|
162
158
|
faker
|
|
163
159
|
jeweler
|
|
164
160
|
rails (>= 3.2.0)
|
|
165
|
-
rdoc
|
|
161
|
+
rdoc
|
|
166
162
|
rspec
|
|
167
163
|
rspec-rails
|
|
168
164
|
shoulda
|
data/README.md
CHANGED
|
@@ -308,6 +308,24 @@ Wiselinks handles page titles by passing `X-Title` header with response. To do t
|
|
|
308
308
|
|
|
309
309
|
Of course you can use `wiselinks_title` helper in your own helpers too.
|
|
310
310
|
|
|
311
|
+
### Google Analytics and Yandex Metrika
|
|
312
|
+
|
|
313
|
+
If you want to handle these analytics tools, then you should add handler to `page:success` event.
|
|
314
|
+
|
|
315
|
+
Let's say, that you have two objects, first is `_gaq` – instance of Google Analytics, second is `_metrika` – instance of Yandex Metrika. Then you have to add the following code somewhere in your `application.js.coffee`.
|
|
316
|
+
|
|
317
|
+
```coffeescript
|
|
318
|
+
$(document).off('page:success').on(
|
|
319
|
+
'page:success'
|
|
320
|
+
(event, data, status) ->
|
|
321
|
+
_gaq.push(['_trackPageview', location.pathname])
|
|
322
|
+
_metrika.hit(location.pathname)
|
|
323
|
+
)
|
|
324
|
+
```
|
|
325
|
+
|
|
326
|
+
After this, you will have correct page view statistics in your analytics tools.
|
|
327
|
+
|
|
328
|
+
|
|
311
329
|
## Example
|
|
312
330
|
|
|
313
331
|
We crafted example application that uses nearly all features of Wiselinks so you can see it in action.
|
|
@@ -329,7 +347,7 @@ We crafted example application that uses nearly all features of Wiselinks so you
|
|
|
329
347
|
|
|
330
348
|
## Credits
|
|
331
349
|
|
|
332
|
-

|
|
333
351
|
|
|
334
352
|
Wiselinks is maintained by [JetRockets](http://www.jetrockets.ru/en).
|
|
335
353
|
|
data/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
0.4.
|
|
1
|
+
0.4.2
|
|
@@ -44,8 +44,8 @@ class Wiselinks
|
|
|
44
44
|
|
|
45
45
|
$(document).on(
|
|
46
46
|
"click", "a[data-push], a[data-replace]"
|
|
47
|
-
(event) ->
|
|
48
|
-
if self._cross_origin_link(event.
|
|
47
|
+
(event) ->
|
|
48
|
+
if self._cross_origin_link(event.currentTarget) || self._non_standard_click(event)
|
|
49
49
|
return true;
|
|
50
50
|
self._process_link($(this))
|
|
51
51
|
|
data/wiselinks.gemspec
CHANGED
|
@@ -5,11 +5,11 @@
|
|
|
5
5
|
|
|
6
6
|
Gem::Specification.new do |s|
|
|
7
7
|
s.name = "wiselinks"
|
|
8
|
-
s.version = "0.4.
|
|
8
|
+
s.version = "0.4.2"
|
|
9
9
|
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
|
11
11
|
s.authors = ["Igor Alexandrov", "Alexey Solilin", "Julia Egorova"]
|
|
12
|
-
s.date = "2013-
|
|
12
|
+
s.date = "2013-02-10"
|
|
13
13
|
s.email = "igor.alexandrov@gmail.com"
|
|
14
14
|
s.extra_rdoc_files = [
|
|
15
15
|
"LICENSE",
|
|
@@ -114,18 +114,18 @@ Gem::Specification.new do |s|
|
|
|
114
114
|
|
|
115
115
|
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
|
116
116
|
s.add_development_dependency(%q<shoulda>, [">= 0"])
|
|
117
|
-
s.add_development_dependency(%q<rdoc>, ["
|
|
117
|
+
s.add_development_dependency(%q<rdoc>, [">= 0"])
|
|
118
118
|
s.add_development_dependency(%q<bundler>, [">= 0"])
|
|
119
119
|
s.add_development_dependency(%q<jeweler>, [">= 0"])
|
|
120
120
|
else
|
|
121
121
|
s.add_dependency(%q<shoulda>, [">= 0"])
|
|
122
|
-
s.add_dependency(%q<rdoc>, ["
|
|
122
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
|
123
123
|
s.add_dependency(%q<bundler>, [">= 0"])
|
|
124
124
|
s.add_dependency(%q<jeweler>, [">= 0"])
|
|
125
125
|
end
|
|
126
126
|
else
|
|
127
127
|
s.add_dependency(%q<shoulda>, [">= 0"])
|
|
128
|
-
s.add_dependency(%q<rdoc>, ["
|
|
128
|
+
s.add_dependency(%q<rdoc>, [">= 0"])
|
|
129
129
|
s.add_dependency(%q<bundler>, [">= 0"])
|
|
130
130
|
s.add_dependency(%q<jeweler>, [">= 0"])
|
|
131
131
|
end
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: wiselinks
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.4.
|
|
4
|
+
version: 0.4.2
|
|
5
5
|
prerelease:
|
|
6
6
|
platform: ruby
|
|
7
7
|
authors:
|
|
@@ -11,7 +11,7 @@ authors:
|
|
|
11
11
|
autorequire:
|
|
12
12
|
bindir: bin
|
|
13
13
|
cert_chain: []
|
|
14
|
-
date: 2013-
|
|
14
|
+
date: 2013-02-10 00:00:00.000000000 Z
|
|
15
15
|
dependencies:
|
|
16
16
|
- !ruby/object:Gem::Dependency
|
|
17
17
|
name: shoulda
|
|
@@ -34,17 +34,17 @@ dependencies:
|
|
|
34
34
|
requirement: !ruby/object:Gem::Requirement
|
|
35
35
|
none: false
|
|
36
36
|
requirements:
|
|
37
|
-
- -
|
|
37
|
+
- - ! '>='
|
|
38
38
|
- !ruby/object:Gem::Version
|
|
39
|
-
version: '
|
|
39
|
+
version: '0'
|
|
40
40
|
type: :development
|
|
41
41
|
prerelease: false
|
|
42
42
|
version_requirements: !ruby/object:Gem::Requirement
|
|
43
43
|
none: false
|
|
44
44
|
requirements:
|
|
45
|
-
- -
|
|
45
|
+
- - ! '>='
|
|
46
46
|
- !ruby/object:Gem::Version
|
|
47
|
-
version: '
|
|
47
|
+
version: '0'
|
|
48
48
|
- !ruby/object:Gem::Dependency
|
|
49
49
|
name: bundler
|
|
50
50
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -186,7 +186,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
186
186
|
version: '0'
|
|
187
187
|
segments:
|
|
188
188
|
- 0
|
|
189
|
-
hash:
|
|
189
|
+
hash: -4012645802697447930
|
|
190
190
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
191
191
|
none: false
|
|
192
192
|
requirements:
|