Maximenu mobile and preventDefault
- johnoatwork
- Topic Author
- Offline
- New Member
-
Less
More
- Posts: 19
- Thank you received: 0
9 years 7 months ago #29259
by johnoatwork
Replied by johnoatwork on topic Maximenu mobile and preventDefault
Hi Ced,
Listening for clicks on menu item number class as you suggested works. I note the mobile menu still doesn't render the other link classes (eg the fontawsome classes) but I can insert them with CSS.
Thanks so much for your help with this. Love your work
Regards
John
Listening for clicks on menu item number class as you suggested works. I note the mobile menu still doesn't render the other link classes (eg the fontawsome classes) but I can insert them with CSS.
Thanks so much for your help with this. Love your work

Regards
John
Please Log in or Create an account to join the conversation.
9 years 7 months ago #29260
by ced1870
Joomlack Webmaster and Developer
Replied by ced1870 on topic Maximenu mobile and preventDefault
cool ! thank you 
yes the menu mobile does not take all the css classes to avoid some CSS conflicts

yes the menu mobile does not take all the css classes to avoid some CSS conflicts
Joomlack Webmaster and Developer
Please Log in or Create an account to join the conversation.
- johnoatwork
- Topic Author
- Offline
- New Member
-
Less
More
- Posts: 19
- Thank you received: 0
9 years 6 months ago #30477
by johnoatwork
Replied by johnoatwork on topic Maximenu mobile and preventDefault
Hi Ced,
Back on this again
I've run into an issue with a third party service that is called using classes that are controlled by the service provider (AddThis).
I've tried a few approaches to make this work from the mobile menu but no luck so far. Is there any way to allow some classes to be passed through to the mobile menu?
Thanks
John
Back on this again

I've run into an issue with a third party service that is called using classes that are controlled by the service provider (AddThis).
I've tried a few approaches to make this work from the mobile menu but no luck so far. Is there any way to allow some classes to be passed through to the mobile menu?
Thanks
John
Please Log in or Create an account to join the conversation.
9 years 5 months ago #30487
by ced1870
Joomlack Webmaster and Developer
Replied by ced1870 on topic Maximenu mobile and preventDefault
Hi
the only way is to modify the javascript, all the menu items are passed in the loop and only the needed informations are taken .Then here you can check for a class
CEd
the only way is to modify the javascript, all the menu items are passed in the loop and only the needed informations are taken .Then here you can check for a class
CEd
Joomlack Webmaster and Developer
Please Log in or Create an account to join the conversation.
- johnoatwork
- Topic Author
- Offline
- New Member
-
Less
More
- Posts: 19
- Thank you received: 0
9 years 5 months ago #30549
by johnoatwork
Replied by johnoatwork on topic Maximenu mobile and preventDefault
Hi Ced,
I tried adding the classes back in document ready but of course it doesn't work because it runs before the mobile menu code. So I think I need to run some js after maximenumobile.js executes. I assume it's triggered by a screen resize event. Is this correct?
Thanks
John
I tried adding the classes back in document ready but of course it doesn't work because it runs before the mobile menu code. So I think I need to run some js after maximenumobile.js executes. I assume it's triggered by a screen resize event. Is this correct?
Thanks
John
Please Log in or Create an account to join the conversation.
9 years 5 months ago #30554
by ced1870
Joomlack Webmaster and Developer
Replied by ced1870 on topic Maximenu mobile and preventDefault
The maximenu mobile is loaded on page load (dom ready). you could use a dom ready and a setInterval to check when the mobile menu is created, then execute your script. Just an idea

Joomlack Webmaster and Developer
Please Log in or Create an account to join the conversation.
Time to create page: 0.217 seconds