lighter_box 0.2.0 → 0.3.0

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: c03be2653f35a74bccc7498a9062c7b1336db780
4
- data.tar.gz: 2d67a7d6d9ff3dd4db28649711563ac7757e3872
3
+ metadata.gz: 7eeffa6b43bdfedb23fe7773b0e8b13e6ee96425
4
+ data.tar.gz: e1e54bc7e09593727970205ae98338a853e0ef9f
5
5
  SHA512:
6
- metadata.gz: 81746e803a4368fc944cb0708142c6dc59059d388bd669c6a212e51a8cb9839e7abd8a63491287ad50f6e6232afc10330e7df2cc194d06f43b2c51d7060e0856
7
- data.tar.gz: 37b281309eb47c133c02e9219779a9f22cd170f60ac0b740539dbcf3c9cf5db8fd7852470e606bdcef3d04dd569f23ea0ec1ce1dfd7aaf78fdaddb212e09832d
6
+ metadata.gz: eb25ab6d893cc0983a4059c97405edebfa300cf21ff169f8aff2fa024b9f6b614f5272d87fbaf7e73347f44a340d9528625f3ac780fd5a64c72aab51195bdd48
7
+ data.tar.gz: 26b00578beba0e36b0672f231801425757c78fa5e3515e4e5de6ff415d415b96e7f7531a74589dc5512ee53e2acf72e2cb7b16518a0d88e7da724edb30ab443f
data/CHANGELOG.md CHANGED
@@ -1,3 +1,7 @@
1
+ # v0.3.0
2
+
3
+ * New option `data-lightbox-href` for ajax lightboxes: Allows to override the URL to be loaded into the lightbox (default is the link’s `href` attribute).
4
+
1
5
  # v0.2.0
2
6
 
3
7
  * New option `data-lightbox-caption-allow-html` for image lightboxes: Allows the image caption to be interpreted as HTML.
data/README.md CHANGED
@@ -59,6 +59,7 @@ Image lightbox only:
59
59
  Ajax lightbox only:
60
60
 
61
61
  * `data-lightbox-fragment`: A jQuery selector to specify the portion of the remote document to be loaded into the lightbox (similar to the fragment feature of [`jQuery.load()`](http://api.jquery.com/load/)).
62
+ * `data-lightbox-href`: The URL that to be loaded into the lightbox. If not set, the link’s `href` attribute is used.
62
63
 
63
64
 
64
65
  ### Events
@@ -245,7 +245,7 @@ class AjaxLighterBox extends LighterBox
245
245
  @ajaxContainer = $("<div/>").appendTo(@modal)
246
246
 
247
247
  _loadContent: =>
248
- href = @srcEl.attr("href")
248
+ href = @srcEl.data("lightbox-href") || @srcEl.attr("href")
249
249
  fragment = @srcEl.data("lightbox-fragment")
250
250
  $.get href, (data) =>
251
251
  data = $("<div/>").append($.parseHTML(data)).find(fragment)
@@ -1,3 +1,3 @@
1
1
  module LighterBox
2
- VERSION = "0.2.0"
2
+ VERSION = "0.3.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lighter_box
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stefan Daschek
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-12-12 00:00:00.000000000 Z
11
+ date: 2017-01-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: coffee-script