Top Dropdowns not working when hover disabled
The new top menus do not work when screen size is reduced below a certain point (at least when using mouse on small screen pc).
The test NSL site works, if I reduce the screen size to the point hover is disabled I can click.
In the last NSL zip I received this was no longer working.
Below is a screen recording to illustrate this:
Comments (24)
-
-
reporter They are hidden on mobile as you mention under:
@media (max-width: 768px)
This issue seems to be due to what happens on line 103 of menu.css:
@media only screen and (min-width : 1068px) { /*on hover only for large screens adjusted to exclude ipad portrait*/
which will affect intermediate screens such as notebooks or ipads
-
reporter Below is another screen recording showing where I think the issue is coming from:
There are a couple of other points which maybe relevant:
1) The theme contains a lang settings for "newmenu1trigger", "newmenu2trigger" neither of which seem to be applied in the theme? 2) All the top menus are using the class "newmenus newmenu5" (as opposed to newmenu1, newmenu2).
The verson on your test site http://newschoolnetwork.com/moodle/29/?theme=bcu works perfectly, clicking the links triggers "dropdown open" as it should, however this was not working in the last zip you sent me. So, it seems you have a working versoin on your test site but it was not working in the zip you sent me.
I really need to get this fixed ASAP, could you please take a look?
-
reporter And below another screen recording showing the difference between what we have now and your test site which works well. We are using 2.8 whereas your test site is 2.9 which could be a factor. As mentioned before I tested a version using your original zip (as opposed to our current GIT versoin) and had the same issue:
-
The test site is 2.9 and your site is 2.8. I will try this out on my 2.8 site to see if I can replicate.
-
reporter Thanks John,
I sent you another mail earlier linking to a proposal to remove hover entirely and replicate menus from another theme. Perhaps you could reply to that mail before doing any more on this?
-
If I remove hover entirely, it would also remove it for the regular custom menu (if that is okay).
-
Okay, I found the issue and was able to replicate in 2.8. It is related to the version of bootstrap in 2.8 vs 2.9. If I add in the dropdown js directly it seems to work:
http://newschoolnetwork.com/moodle/28rc/?theme=bcu http://newschoolnetwork.com/moodle/28rc/?theme=bcu
Can you confirm this is now working for you?
-
reporter Yes that seems to work, thanks!. Will this still work in 2.9? If not I can try load that js conditionally based on the Moodle version. Can you pull this repo, apply the change and push it back?
-
I'm going to test in 2.9 tonight.
-
It did not work in 2.9 so I added it to the conditional check in the lib. Tested on 2.8 and 2.8 and working. Just sent to your repo.
-
reporter Hi John, I cannot see either a commit or pull request for this?
-
Sorry I committed but did not push. Will do so in just a bit.
-
Okay, should be there now.
-
reporter Did you pull the latest version before doing that? It looks like its zapped all the changes ww made recently, for example removing a lot of the settings in lib.php?
-
I did and then just changed the Lib etc. if you want to roll it back I can re-try.
-
lib.php has many settings removed and now the fonts are not applied.
Could we roll back these changes? I only detected the fonts but looks like there are more settings impacted with these changes after see the commit.
-
reporter Hi Fernando,
I assume you have pulled this version (I have not yet) in which case you should be able to revert the commit:
https://www.atlassian.com/git/tutorials/undoing-changes/git-revert
That will leave Johns commit there ( so we can still see his code) but add another commit that reverses all the changes.
I think that would be the best option?
-
I made the pull to the dev server, The test server, located in testlab.ws, is not updated so for the moment I will get the copy from there.
I see there are many changes in lib.php and also in the styles that can have impact in the rest of the site. Since I modified only settings.php I got a copy from the test server and now the dev server is working well.
Please, review all the changes of this commit. Also a DS_file is added to the repo that is not useful.
-
reporter Hi Fernando, I have just rolled back that commit, if you pull again it should put all the lib.php values back. You may want to double check the changes you made after Johns commit are still ok, I think you were working in different files.
-
reporter Hi John,
I have rolled back that commit. Could you please pull the current copy, ensure it is up to date, re-apply changes and make another commit please?
You will want to make sure you have copies of your code before you pull lest you overwrite it.
Thanks
-
Okay, should be re-done now.
-
reporter Thanks John, that looks ok now.
-
reporter - changed status to resolved
This issue was resolved and should have been closed at that time.
- Log in to comment
As far as I can see, they are hidden on smaller screens since they could not be made responsive. This was based on our discussion of the item. Is that not what you are seeing from your end?