googlearchive / core-header-panel

Simple panel with top and bottom panes
9 stars 8 forks source link

Possible to publish the `scroller`? #20

Closed robdodson closed 10 years ago

robdodson commented 10 years ago

I'd like to bind the scroller to core-list's scrollTarget so mode="scroll" works properly. Right now I have to include this snippet to get it to work:

var list = document.querySelector('core-list');
var header = document.querySelector('core-header-panel');
list.scrollTarget = header.scroller;

cc @kevinpschaaf

frankiefu commented 10 years ago

You should be able to bind scrollTarget to $.header.scroller. No need to have scroller published.

<core-header-panel id="headerPanel" mode="scroll">
  <core-toolbar>My App</core-toolbar>
  <core-list flex scrollTarget="{{$.headerPanel.scroller}}">