Cody Blue
Posts: 0
Joined: Sun Aug 25, 2013 2:11 am

Map visibilty issue

Hello,

As suggested in the thread here (https://getsatisfaction.com/apperyio/...), I had been using

jQuery('[name="googlemap_29"]').css("visibility", "hidden");
jQuery('[name="googlemap_29"]').css("visibility", "visible");

to hide and display maps when I needed to. On checking today (browser, iOS device), the above commands are suddenly failing to achieve desired effect.

Is there a change in Appery causing this? Will appreciate advise of resolution soon as it is breaking the functionality that took us time to build and quite a bit is riding on the use of above JS to hide and display maps.

PS - Use of $('[dsid="googlemap"]').hide() skews markers and all the display within the maps (which are bounded appropriately in JS), so we'd rather not use it . Hope you can help fix the above JS working in Appery.

Evgene Karachevtsev
Posts: 12
Joined: Mon Apr 28, 2014 1:12 pm

Map visibilty issue

Hello Cody,

There wasn't to be any changes causing this. Could you please clarify, do you still have this issue?

Cody Blue
Posts: 0
Joined: Sun Aug 25, 2013 2:11 am

Map visibilty issue

I've checked again and yes, I do. As mentioned above, setting "visibility" to "hidden" is no longer effective in hiding the map, when things were working absolutely fine until at the most a few days ago. You might want to consult with Yurii, regarding the JS that was proposed. The problem should reproducible via simple test https://getsatisfaction.com/apperyio/...

Evgene Karachevtsev
Posts: 12
Joined: Mon Apr 28, 2014 1:12 pm

Map visibilty issue

Cody,

Could you please also detail a few things:
1) Have you changed the component name ?
2) Have you tried to debug your project with wienre ?
3) What exactly line of code doesn't work ?

Cody Blue
Posts: 0
Joined: Sun Aug 25, 2013 2:11 am

Map visibilty issue

Everything has been checked and thoroughly tested. Component name is as it should be. Apologies but this is becoming bit frustrating: I am genuinely reporting a problem you seem to have, and am being countered twice with obvious questions. Again, please reproduce the solution you had suggested on the get-satisfaction link above and you'll see it does not work any longer. I'll appreciate if you can provide a resolution - a suggestion that it will be fixed in two months in the next release won't be helpful to us, as I have indicated a lot of our implementation is riding on this working properly.

Evgene Karachevtsev
Posts: 12
Joined: Mon Apr 28, 2014 1:12 pm

Map visibilty issue

Hello Cody,

We checked the code, please use this one
prejQuery('[name="googlemap_29"]').css("display", "none");
jQuery('[name="googlemap_29"]').css("display", "block");/pre

Cody Blue
Posts: 0
Joined: Sun Aug 25, 2013 2:11 am

Map visibilty issue

Evgeny - thanks the feedback. But this breaks the map display in several ways (the map zoom and boundaries set via latlngbounds in JS are not preserved and the map display shows up skewed). Is there a way you guys can get the "visibility" css property to work again in Appery, as it did before? I have maps in several places of the project which were all working fine till now, and the breakage will warrant rework that will take substantial time.

M&M
Posts: 0
Joined: Tue Nov 11, 2014 6:59 am

Map visibilty issue

have you tried this method to hide / show the map

// To Hide map
var gmap = Appery("googlemap_16");
gmap.hide();

// To Show map
var gmap = Appery("googlemap_16");
gmap.show();

Hopefully it won't mess with existing zoom / lat lon bounds

Cody Blue
Posts: 0
Joined: Sun Aug 25, 2013 2:11 am

Map visibilty issue

That doesn't work unfortunately. The zoom and bounds do get distorted as with "display" css solution above. The "visibility" attribute implementation was working well before and I hope the folks can suggest if that can be restored.

M&M
Posts: 0
Joined: Tue Nov 11, 2014 6:59 am

Map visibilty issue

You may want to try another trick while the folks at Appery find a fix:

code
jQuery('[name="googlemap_29"]').css("opacity", "0.0"); // Transparent / Hidden

jQuery('[name="googlemap_29"]').css("opacity", "1.0"); // Opaque / Visible
/code

Technically this should not mess with the markers and stuff

Necessity is the mother of invention :-)

Return to “Issues”