radykal | Support Center Chooser

For which product do you need support?

Fancy Product Designer Multistep Product Configurator

Start a new topic
Answered

A solution to the new step in design choices

Previously, when we added a design choice to our designs, the choice window would close itself.  This was helpful for "simple" products, as we need to reduce clicks and steps to get more people to the finish line (ORDERS!)


Recently, an "x" was added, and for more complex or multiple designs it makes total sense.


For the rest of us, instead of a "request"  I am putting up a solution.


Add this to your favorite page footer script plugin, or even right into your code, and the click-to-choose-and-close behavior is back : 


 

<script type='text/javascript'>
jQuery( document ).ready(function() {
		
		setTimeout(function(){
		
			while (!jQuery( "div.fpd-view-stage").length ) {
				sleep(10);
			}
			
			//PUT YOUR JAVASCRIPT HERE
			
			jQuery("div.fpd-item picture").click(
				function() {
					setTimeout(function(){
						jQuery("div.fpd-close-stage-off-canvas span.fpd-icon-close").click();
					}, 20);
				}
			);		
			
		}, 10);

});
</script>

 


Best Answer

thanks


Answer

thanks

Thank you, I'm really surprised that closing isn't the default behavior!

Thanks, had the same problem but the solution is, somewhat strange :p


Just add the following anywhere for designs:

$(document).on('click', 'div[data-module="designs"] picture', function()
{
	$('div.fpd-close-dialog span.fpd-icon-close').trigger('click');
});

 

Sorry, just found the events *facepalm* so this solution will work for any elements not just designs.

Add the following after Initialization where 'product-designer' is the ID of your designer:

$('#product-designer').on('elementAdd', function() { $('div.fpd-close-dialog span.fpd-icon-close').trigger('click'); });

 

 Big thumbs up!


Here is a little code update:

fancyProductDesigner.$container.on('elementAdd', function() { $('div.fpd-close-dialog span.fpd-icon-close').trigger('click'); });

 

 

Login or Signup to post a comment