Posts: 58
Threads: 17
Joined: May 2017
Reputation:
1
Hi!
I have Menu Widget that contains multiple buttons that open another widgets. When i work with PC it works fine, but when I work with iphone the widgets don't autoscale.
If i create a button outside of menu widget to open the same widget, the widget get autoscale.
What can i do? Is ther a function to do this?
Thanks!
Posts: 58
Threads: 17
Joined: May 2017
Reputation:
1
Resolved with Edgars help.
I had:
$('.Screens').on('vclick', function() {
$("#widget-47").removeClass("hide");
$("#widget-29").addClass("hide");
});
$('.TempTec').on('vclick', function() {
$("#widget-48").removeClass("hide");
$("#widget-29").addClass("hide");
});
$('.Alimentacions').on('vclick', function() {
$("#widget-49").removeClass("hide");
$("#widget-29").addClass("hide");
});
$('.Apagat').on('vclick', function() {
$("#widget-50").removeClass("hide");
$("#widget-29").addClass("hide");
});
$('.Crepuscular').on('vclick', function() {
$("#widget-62").removeClass("hide");
$("#widget-29").addClass("hide");
});
Replaced with:
$('.Screens').on('vclick', function() {
$("#widget-47").appendTo('.widgets').removeClass("hide");
$("#widget-29").addClass("hide");
//$('.Screens').trigger('vclick')
});
$('.TempTec').on('vclick', function() {
$("#widget-48").appendTo('.widgets').removeClass("hide");
$("#widget-29").addClass("hide");
});
$('.Alimentacions').on('vclick', function() {
$("#widget-49").appendTo('.widgets').removeClass("hide");
$("#widget-29").addClass("hide");
});
$('.Apagat').on('vclick', function() {
$("#widget-50").appendTo('.widgets').removeClass("hide");
$("#widget-29").addClass("hide");
});
$('.Crepuscular').on('vclick', function() {
$("#widget-62").appendTo('.widgets').removeClass("hide");
$("#widget-29").addClass("hide");
});
Lot of thanks Edgars!