Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Safari: hide not triggered #51

Open
Evekt opened this issue Jul 4, 2016 · 3 comments
Open

Safari: hide not triggered #51

Evekt opened this issue Jul 4, 2016 · 3 comments

Comments

@Evekt
Copy link

Evekt commented Jul 4, 2016

The hide event is not triggering on an ipad. When i touch the element, the tooltip opens after a short delay. But when i touch it a second time, it's not hiding.

We have the same issue on the offical tipso-website "http://tipso.object505.com"

Is this a known issue ?

Kind regards

Simon

@Evekt Evekt changed the title IOS: hide not triggered Safari: hide not triggered Jul 5, 2016
@gustavobs
Copy link

Also facing same issue, anyone has a fix ?

@susanacrai
Copy link

I had the same problem today, and in the end I could fix it by adding in my css

.tipso_content {
cursor: pointer;
}

See here why: https://developer.mozilla.org/en-US/docs/Web/Events/click#Safari_Mobile
Hope it works for you too

@AFishNamedFish
Copy link

AFishNamedFish commented Mar 12, 2018

I have the same issue has @Evekt. When viewing any Tipso tooltip on iOS (both in iOS Safari and in iOS Chrome), the tooltip cannot be dismissed. It remains on-screen indefinitely (that is, until another tooltip has been opened, until page refresh, or until a hyperlink has been clicked).

@SusanaDubstone Unfortunately, your suggestion no longer works.

Does anyone know how to fix this?

UPDATE:

I've spent the entirety of the last 2 days working on this.

I've finally devised a working solution:

jQuery('.rightColorOrange').tipso({
	position: 'right',
	background: 'rgba(218, 103, 0, 1.0)',
	titleBackground: 'tomato',
	// MY CODE BEGINS HERE.
	onShow : function(e){
		var touchCounterForThisTooltip = 0;
	
		$(document).on({ 'touchstart' : function(ev){
			var theClassThatWasJustTapped = $(ev.originalEvent.targetTouches[0].target).attr('class');
			if (touchCounterForThisTooltip == 0) {
				e.tipso('hide');
			}
			else if (touchCounterForThisTooltip > 0) {
				if (theClassThatWasJustTapped == "rightColorOrange tipso_style") {
					e.tipso('show');
			
					$(document).off('touchstart');						
				}
			}
			touchCounterForThisTooltip = touchCounterForThisTooltip + 1;
		} });
	},
	// MY CODE ENDS HERE.
});

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants