PolymerElements / paper-dropdown-menu

A Material Design browser select element
https://www.webcomponents.org/element/PolymerElements/paper-dropdown-menu
61 stars 107 forks source link

Menu not showing up when clicked #89

Closed edfungus closed 8 years ago

edfungus commented 8 years ago

I am getting this error in console: "Uncaught TypeError: Cannot read property 'cancel' of null" when click on the dropdown. The underline animation happens but the menu with options does not show up

I have installed paper-dropdown-menu, paper-listbox, paper-item and web-animations-js.

Not sure if I missed something but I looked through the demo file and am using pretty much the same code.

Any ideas?

morficus commented 8 years ago

@edfungus could you post a sample of your code?

edfungus commented 8 years ago

@morficus

       div.dropDownDisplay
          paper-dropdown-menu(label="Moods", value="{{selectedOption}}")
            paper-listbox(selected="0", class="dropdown-content").dropdown-content
              template(is="dom-repeat", items="{{endPointJson.options}}")
                paper-item {{item}}

From: https://github.com/edfungus/Crouton/blob/master/public/app/dashboard-elements/crouton-simple-dropdown/crouton-simple-dropdown.jade

Sorry it is in jade, but this is how I am populating the menu. It shows up fine including the ripple affect when clicked but the dropdown does not show.

It has been a while, so I have changed the code around it so no more console error. Not sure if that helps too.

If you want a live demo, I can do that too. Just let me know.

cdata commented 8 years ago

Please re-open this issue if it still occurs, with a JSBin containing a set of reproducible steps! For more details on filing issues, please refer to our contributing guidelines.