Giter VIP home page Giter VIP logo

easy-swipebox's People

Contributors

gnowland avatar leopuleo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

easy-swipebox's Issues

Close button issue

There is currently an issue with swipebox plugin where on mobile browsers when you click close button it also clicks on everything behind that button. There are few fixes suggested by the users on the GitHub issue, it would be really nice if you could add it to the plugin.

https://github.com/brutaldesign/swipebox/issues/331

Use custom icons

aviarts wrote:
Replies: 3

My goal is to use custom icons in the lightbox displa for X < and >.

A designer provided png version of icons. I placed a icons.png in the public/img directory and unchecked the Use SVG Icons box in the WordPress Easy Swipe Box plug-in settings page.

However, the lightbox display is still using the svg image.

I then set the plug-in to debug mode and did some checking in the jquery.swipebox.js file and found that plugin.settings.useSVG is true at line 172 eventhough the Use SVG icons check box. is unchecked. (The value for useSVG is 0 in easySwipeBox_lightbox option in wp database)

// jquery.swipebox.js

build: function()

โ€ฆ

alert(plugin.settings.useSVG); // returns true even though use SVG is unchecked

if ( supportSVG && plugin.settings.useSVG === true )

So there may be a bug somewhere in the javascript that is ignoring the use SVG plug-in setting.

Other than creating a replacement icons.svg is there a workaround for me to use my own icons.png?

Link: https://wordpress.org/support/topic/use-custom-icons/

Group images by post

When browsing any WordPress view with multiple posts (archives, the default frontpage, a category or tag) Easy Swipebox will put all images into a single gallery. That is; I can open an image in the first post and then swipe my way through all images in every other post too.

I think the default behavior should be that each post is treated as its own gallery by SwipeBox? Or at least have this behavior as a setting?

In WP-jQuery Lightbox I achieve this behavior by extracting post_id when filtering on 'the_content'. Someting like:

//filter for 'the_content'
function jqlb_autoexpand_rel_wlightbox($content) {
	if(get_option('jqlb_automate') == 1){
		global $post;			
		$id = isset($post->ID) ? $post->ID : -1;
		$content = jqlb_do_regexp($content, $id);
	}			
	return $content;
}

//"public" version to lightbox any user-supplied content.
function jqlb_apply_lightbox($content, $id = -1){
	if(!isset($id) || $id === -1){
		$id = time().rand(0, 32768);
	}
	return jqlb_do_regexp($content, $id);
}

Thanks!

Leonardo Giacone on "[Plugin: Easy SwipeBox] To hide the photo title or caption"

Hello,

thank you for contacting me!

Unfortunatelly no, right now the plugin works in this way:

Show the link attribute title

if it does not exist, show the image attribute title

if it does not exist, show the image attribute alt

In future release I can consider to add aa advanced setting to manage this behavior and disable the title.

My best regards,

Leonardo

Lengthen the hide bars delay

Thanks for putting this together as a plugin! I would like to lengthen the delay of the bars from 3 seconds to 10 seconds, maybe longer. I see this is a Swipebox option. Could this be added as a form to the Easy SwipeBox settings page to allow control of the delay? Control over other options (videoMaxWidth, loopAtEnd, etc) from the settings page would be a nice addition as well.

hideBarsDelay : 3000, // delay before hiding bars on desktop

Last version of wodpress 5.6

The plugin easy SwipeBox seems to not work with the last version of wordpress (5.6) it could be about the new version of jquery used by wordpress.
Could you confirm it ?

Image Init applies to anything with png/gif/jpg/etc in it

The following link on my site is getting the swipebox class auto-assigned because it has the three letters 'gif' within it:

<a href="/the-sparkling-starfish-jewellery-gifts/" class="swipebox"><span>The Sparkling Starfish Jewellery &amp; Gifts</span></a>

Notice the word gifts? Your code for image detection in jquery.init.image.js on line 6 should be like this:

return /(\.jpg|\.jpeg|\.gif|\.png)/i.test( $(this).attr('href'))

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.