stevo / colorbox-rails Goto Github PK
View Code? Open in Web Editor NEWMake links open in lightbox a breeze
License: MIT License
Make links open in lightbox a breeze
License: MIT License
If there's already jQuery on the page, it'll be included another time.
I think it shouldn't include jquery but rely on the developer to include it in application.js.
It seems reasonable to guess that using this gem is better than just loading colorbox.js and using through javascript . . . but after a bunch of searching, I have not found any good examples of how one would use it in a Rails way especially usual things like having a partial rendered inside or a hidden div.
It took me a while, two new routes and a partial but I got it working. Still, I cannot believe that this is the way that you intended.
I am happy to build a nice example wiki page for this project and create a pull request. If needed, I will create a small example app. Please post examples here or email them to me and I will get it built.
<%= link_to "Add something", new_something_path, data: { colorbox: true, inline: true } %>
<%= link_to "link name", '#', data: { colorbox: true, href: 'id-of-some-div', inline: true } %>
Thank you!
Using colorbox-rails (0.0.9) from git://github.com/stevo/colorbox-rails.git (at master)
ArgumentError: invalid byte sequence in US-ASCII
An error occurred while installing colorbox-rails (0.0.9), and Bundler cannot continue.
Make sure that `gem install colorbox-rails -v '0.0.9'` succeeds before bundling.
installing using ruby 1.9.3 on macosx
how to testing it using cucumber or etc???
When I click on a button for a picture, the window with a picture pops up BUT I cannot close it, the close button doesnt work.
When the window pops up, the background of the website turns dark grey and in order to close the window, I have to click on the background, it turns light grey and only then I can close the popup window by clicking on the close button.
What can be the problem? Thanks in advance
jQuery team will drop live event soon.
$(document).ready(function()
{
$(document).on('click', 'a[data-colorbox="true"]', function(e) {
...
});
});
Hi, are image groups supported? I can't manage to get them working..
thanks
use data: { transition: "fade" }
to change the colorbox transition
setting
Playing around with youtube vids and haven't been able to get one to work. Is it possible to with this gem?
this commit:
allows usage of this gem w/in a rails 3.2 project.
Please release a new version to rubygems including this fix.
The colorbox opens up empty until the content loads, with no loading animation.
Would love support for the colorbox "rel" attribute for creating image groups!
hi there,
i installed colorbox-rails via 'gem install colorbox-rails' and added the lines to the application.js and application.css. The colorbox window works, but there are no pictures. The colorbox is just a ugly white spot. Rails gives me a 404 error for the images. What am i doing wrong?
Thanks
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.