question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

virtual scroll: sticky header/footer

See original GitHub issue

Requirement

We need the ability to make things sticky within the virtual scroll area. This directly relates to sticky header/footer/rows in the table.

API

An idea for the API would be to expose a new content projection area like:

  <cdk-virtual-scroll-viewport [itemSize]="35">
    <cdk-virtual-scroll-sticky position="start">
      MY HEADER
    </cdk-virtual-scroll-sticky>
    <div *cdkVirtualFor="let row of rows$ | async">
    </div>
    <cdk-virtual-scroll-sticky position="end">
      MY FOOTER
    </cdk-virtual-scroll-sticky>
</cdk-virtual-scroll-viewport>

Then we could set position sticky to those sticky projections. One issue with this approach is how do we tell the cdk-virtual-scroll-content-wrapper to accommodate the offset of the header/footer?

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:3
  • Comments:10 (2 by maintainers)

github_iconTop GitHub Comments

2reactions
amcdnlcommented, Jun 1, 2018

After thinking about this, I think we should go w/ a different approach for the table thus making this not applicable.

0reactions
angular-automatic-lock-bot[bot]commented, Sep 11, 2019

This issue has been automatically locked due to inactivity. Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

Read more comments on GitHub >

github_iconTop Results From Across the Web

The table virtual scroll breaks the sticky header and footer
When using the virtual scroll feature, the sticky header and footer don't work as expected. The header jumps and the footer disappears when ......
Read more >
Angular Table Virtual Scroll Sticky Headers (forked) - StackBlitz
Virtual Scroll with mat-table.
Read more >
Sticky table header border is overlapped by <td> elements
I'm using a package called ngx-virtual-scroller to implement virtual scroll for the table. It has an option to make the headers sticky -...
Read more >
Virtual Scroll - Quasar Framework
Dessert (100g serving) Calories Fat (g) Carbs (g) Protein (g) Sodium (mg) Ca... Index: 4994 Cupcake 305 3.7 67 4.3 413 3% Index: 4995 Gingerbread...
Read more >
Making Tables With Sticky Header and Footers Got a Bit Easier
It wasn't long ago when I looked at sticky headers and footers in HTML s in the blog post A table with both...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found