googlearchive / core-list

Polymer virtualized list element
25 stars 20 forks source link

core-list elements disappear in scrollview #70

Closed mountainraptor closed 7 years ago

mountainraptor commented 9 years ago

I have a core-list of elements in a scrollview. The number of things exceeds the 240px of height. Any elements that are below the view (there is a scroll bar) are blank. If I click on another item it appears. If I click on the item at the bottom of the list and scroll up it disappears. I am running Version 39.0.2171.99 (64-bit). The CSS is for the page that contains a thing_manager element which has the core-list.

relevent css & HTML:

#thing_manager {
  padding: 8px;
  height: 240px;
  width: 360px;
}
<div>
      <core-list id="list" data="{{things}}" multi="false" selection="{{selection}}" flex>
        <template>
          <paper-item class="{{ {selected: selected } | tokenList}}" noink>
            <div flex>{{model.name}}</div>
            <paper-icon-button icon="input" on-tap="{{install}}" hidden?="{{!selected}}"></paper-icon-button>

          </paper-item>
        </template>
      </core-list>
</div>
gertcuykens commented 9 years ago

I think I have the same issue

http://stackoverflow.com/questions/29245120/core-list-doesnt-display-all-my-items-in-scroll-view

http://embed.plnkr.co/9sxQHUcsBImmPTIZ3Fgq/preview

tamsler commented 9 years ago

I ran into the same issue. I had to set the core-list height to the same value of a list item height.

<core-list height=40>
    <template>
        <div style="height=40px">
        ...
        </div>
    </template>
</core-list>
denevell commented 9 years ago

@tamsler Thanks. That fixed my problem.