Skip to content
This repository has been archived by the owner on Jun 18, 2024. It is now read-only.

some navbar issues #119

Closed
gkht opened this issue Sep 13, 2015 · 8 comments
Closed

some navbar issues #119

gkht opened this issue Sep 13, 2015 · 8 comments

Comments

@gkht
Copy link

gkht commented Sep 13, 2015

navbar
1, the upload menü item ''fall out"
2, when the drop down is open, you can select the menü items behind the drop down
(IE, version: 11.0.10011.0)

@ericthompson
Copy link
Contributor

Good catches - we'll look into this asap!

@aremes
Copy link
Contributor

aremes commented Sep 17, 2015

edit -> just wanted to issue a pull request for this and saw @robi26 already had this done :/ nevermind

One more: if i want to use the navbar without the search bar but with a dropdown (
"ContextualMenu", that is), it breaks on lines 419ff in fabric.js due to a missing null-check.

        // Close and blur the search box if it doesn't have text.
        if ($navBar.find('.ms-NavBar-item.ms-NavBar-item--search .ms-TextField-field').val().length === 0) {
          $('.ms-NavBar-item.ms-NavBar-item--search').removeClass('is-open').find('.ms-TextField-field').blur();
        }

changing these lines to

        // Close and blur the search box if it exists and doesn't have text.
        $searchBox = $navBar.find('.ms-NavBar-item.ms-NavBar-item--search .ms-TextField-field');
        if ($searchBox.length > 0 && $searchBox.val().length === 0) {
          $('.ms-NavBar-item.ms-NavBar-item--search').removeClass('is-open').find('.ms-TextField-field').blur();
        }

solves it. this also has to be done a few lines below at around line 464:

        // Close and blur the search box if it exists and doesn't have text.
        $searchBox = $navBar.find('.ms-NavBar-item.ms-NavBar-item--search .ms-TextField-field');
        if ($searchBox.length > 0 && $searchBox.val().length === 0) {
          $navBar.find('.ms-NavBar-item.ms-NavBar-item--search').removeClass('is-open').find('.ms-TextField-field').blur();
        }

Wouldn't you agree? or is it just me being an idiot assuming one might like to use the navbar without a search field? :)

@pbjorklund
Copy link

I'm having the same issue and solved it the same was as @aremes

@aremes
Copy link
Contributor

aremes commented Oct 2, 2015

@pbjorklund there's already a pull request under review by the office devs. :) as for the original issue, i couldnt reproduce.. any more info? if i can reproduce it, i'd be glad to attempt a fix.

@pbjorklund
Copy link

If it's the same bug I think it just has to do with that a dropdown isn't closed when selecting another dropdown
image

edit: Glad to hear it! I actually just reverted to a hidden dummy that matched the search selectors just so that I could use bower correctly :)

@jonahkirangi
Copy link
Member

The upload menu item "fall out" issue has been resolved in pull request #173. The layering issue has been resolved in pull request #175.

@pbjorklund
Copy link

Is there a issue open for the search-field @jonahkirangi (I can't see an open one, might be resolved already as well)? I can create a new one and pull mine and @aremes comments together in that if there is none.

@ericthompson
Copy link
Contributor

Editing this after going back and re-reading the thread - sorry bout that!

We aren't tracking a separate issue for the search field problem @aremes noted above. It seems like he has a fix that would work. If one of you sent out a pull request we wouldn't mind reviewing it!

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

No branches or pull requests

6 participants
@pbjorklund @ericthompson @aremes @jonahkirangi @gkht and others