hermitage 0.0.6 → 0.0.7

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
  SHA1:
3
- metadata.gz: ee0fbe28474a097744385af14ebff1c2fe2e08fb
4
- data.tar.gz: ff0dc0813bf7052df7f7bfba8f680cc9d7001c7d
3
+ metadata.gz: 550fb456094b98a18161af4f4231a6f1e038a5d4
4
+ data.tar.gz: 74ed88dcab85a1b29542507c1aedbefe10e1b1b7
5
5
  SHA512:
6
- metadata.gz: e1d6beda43632150831c4454ab43dda47b84d56963bad4944b83aaebbcae8f51c36f86cc614d9a12deeda1599e4a17d55b72163665dde615117f85f3d49b4a0f
7
- data.tar.gz: e7611bc731f3d576f1dd2f35e20170e32cb4204ff5fd1a0555503d92e03e9cf1f194f8cf8af374b7e52e4f2ea413cfa61cbef6acda179d76acad54160c50f2c5
6
+ metadata.gz: 02cec1f3e61626b33e53ba487715d6da91af1038180cc0142c3a612d8ed1f219a3356f7a8e65d47b93b0072d1f8cd7bf0370fad1226cda6e0298ca9f4a9424fb
7
+ data.tar.gz: 2bb0763e4f55c8b3e87366876f71e5126f8285897cea45fdcaf22efcd1b6b60428f98e4ab9ef7b40aa52d3c421b6136fdeca8b7c8b271d4d3a8832e28d2ece5b
data/.ruby-gemset ADDED
@@ -0,0 +1 @@
1
+ hermitage
data/.ruby-version ADDED
@@ -0,0 +1 @@
1
+ 2.0
data/.travis.yml CHANGED
@@ -1,4 +1,6 @@
1
1
  language: ruby
2
2
  rvm:
3
+ - 1.9.3
3
4
  - 2.0.0
4
- - 1.9.3
5
+ - 2.1.0
6
+ - ruby-head
data/CHANGELOG.md CHANGED
@@ -1,3 +1,8 @@
1
+ ### 0.0.7 ###
2
+
3
+ * Key bindings added (thanks danielpuglisi)
4
+ * Viewer z-index fixed (thanks paulslaby and lizhubertz)
5
+
1
6
  ### 0.0.6 ###
2
7
 
3
8
  * Fixed centering of image viewer in iOS Safari.
@@ -13,7 +13,7 @@ root.hermitage =
13
13
  # Image viewer properties
14
14
  default:
15
15
  styles:
16
- zIndex: 10
16
+ zIndex: 1030
17
17
  position: 'fixed'
18
18
  top: 0
19
19
  left: 0
@@ -81,6 +81,7 @@ root.hermitage =
81
81
  fontFamily: 'Tahoma,Arial,Helvetica,sans-serif'
82
82
  whiteSpace: 'nowrap'
83
83
  cursor: 'pointer'
84
+ padding: '0px 20px'
84
85
  styles: {}
85
86
  enabled: true
86
87
  text: '×'
@@ -171,6 +172,9 @@ root.hermitage =
171
172
  -> adjustImage(true),
172
173
  hermitage.resizeTimeout
173
174
 
175
+ # Initialize Key Bindings
176
+ createKeyBindings()
177
+
174
178
  #
175
179
  # Working with images array
176
180
  #
@@ -314,6 +318,13 @@ hideLoader = ->
314
318
  clearLoaderTimer()
315
319
  $('#hermitage .loader').hide()
316
320
 
321
+ createKeyBindings = ->
322
+ $(document).keyup (e) ->
323
+ switch e.keyCode
324
+ when 27 then closeGallery()
325
+ when 37 then showPreviousImage()
326
+ when 39 then showNextImage()
327
+
317
328
  # Shows original image of the chosen one
318
329
  openGallery = (image) ->
319
330
  $('#hermitage')
@@ -559,4 +570,4 @@ previousIndexBefore = (index) ->
559
570
 
560
571
  # Initialize gallery on page load
561
572
  $(document).ready(hermitage.init)
562
- $(document).on('page:change', hermitage.init)
573
+ $(document).on('page:change', hermitage.init)
data/hermitage.gemspec CHANGED
@@ -24,10 +24,10 @@ Gem::Specification.new do |spec|
24
24
 
25
25
  spec.add_development_dependency 'bundler', '~> 1.3'
26
26
  spec.add_development_dependency 'rake'
27
- spec.add_development_dependency 'rspec-rails'
28
- spec.add_development_dependency 'capybara'
27
+ spec.add_development_dependency 'rspec-rails', '~> 2.99.0'
28
+ spec.add_development_dependency 'capybara', '~> 2.4.4'
29
29
  spec.add_development_dependency 'sqlite3'
30
30
  spec.add_development_dependency 'therubyracer'
31
- spec.add_development_dependency 'poltergeist'
32
- spec.add_development_dependency 'genspec'
31
+ spec.add_development_dependency 'poltergeist', '~> 1.5.1'
32
+ spec.add_development_dependency 'genspec', '~> 0.2.8'
33
33
  end
@@ -1,3 +1,3 @@
1
1
  module Hermitage
2
- VERSION = '0.0.6'
2
+ VERSION = '0.0.7'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hermitage
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.6
4
+ version: 0.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alexander Borovykh
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-09-27 00:00:00.000000000 Z
11
+ date: 2015-03-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -84,30 +84,30 @@ dependencies:
84
84
  name: rspec-rails
85
85
  requirement: !ruby/object:Gem::Requirement
86
86
  requirements:
87
- - - '>='
87
+ - - ~>
88
88
  - !ruby/object:Gem::Version
89
- version: '0'
89
+ version: 2.99.0
90
90
  type: :development
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
- - - '>='
94
+ - - ~>
95
95
  - !ruby/object:Gem::Version
96
- version: '0'
96
+ version: 2.99.0
97
97
  - !ruby/object:Gem::Dependency
98
98
  name: capybara
99
99
  requirement: !ruby/object:Gem::Requirement
100
100
  requirements:
101
- - - '>='
101
+ - - ~>
102
102
  - !ruby/object:Gem::Version
103
- version: '0'
103
+ version: 2.4.4
104
104
  type: :development
105
105
  prerelease: false
106
106
  version_requirements: !ruby/object:Gem::Requirement
107
107
  requirements:
108
- - - '>='
108
+ - - ~>
109
109
  - !ruby/object:Gem::Version
110
- version: '0'
110
+ version: 2.4.4
111
111
  - !ruby/object:Gem::Dependency
112
112
  name: sqlite3
113
113
  requirement: !ruby/object:Gem::Requirement
@@ -140,30 +140,30 @@ dependencies:
140
140
  name: poltergeist
141
141
  requirement: !ruby/object:Gem::Requirement
142
142
  requirements:
143
- - - '>='
143
+ - - ~>
144
144
  - !ruby/object:Gem::Version
145
- version: '0'
145
+ version: 1.5.1
146
146
  type: :development
147
147
  prerelease: false
148
148
  version_requirements: !ruby/object:Gem::Requirement
149
149
  requirements:
150
- - - '>='
150
+ - - ~>
151
151
  - !ruby/object:Gem::Version
152
- version: '0'
152
+ version: 1.5.1
153
153
  - !ruby/object:Gem::Dependency
154
154
  name: genspec
155
155
  requirement: !ruby/object:Gem::Requirement
156
156
  requirements:
157
- - - '>='
157
+ - - ~>
158
158
  - !ruby/object:Gem::Version
159
- version: '0'
159
+ version: 0.2.8
160
160
  type: :development
161
161
  prerelease: false
162
162
  version_requirements: !ruby/object:Gem::Requirement
163
163
  requirements:
164
- - - '>='
164
+ - - ~>
165
165
  - !ruby/object:Gem::Version
166
- version: '0'
166
+ version: 0.2.8
167
167
  description: Ruby library for image galleries generation.
168
168
  email:
169
169
  - immaculate.pine@gmail.com
@@ -173,7 +173,8 @@ extra_rdoc_files: []
173
173
  files:
174
174
  - .gitignore
175
175
  - .rspec
176
- - .rvmrc
176
+ - .ruby-gemset
177
+ - .ruby-version
177
178
  - .travis.yml
178
179
  - CHANGELOG.md
179
180
  - Gemfile
@@ -281,7 +282,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
281
282
  version: '0'
282
283
  requirements: []
283
284
  rubyforge_project:
284
- rubygems_version: 2.0.6
285
+ rubygems_version: 2.4.5
285
286
  signing_key:
286
287
  specification_version: 4
287
288
  summary: Ruby library for image galleries generation (thumbnails and original images
data/.rvmrc DELETED
@@ -1 +0,0 @@
1
- rvm use 2.0.0@hermitage --create