Skip to content

help(mat-tab-nav-bar): Can't make auto-scrool to work along with mat tabs when dragging an item #26294

Open
@PierreDugue

Description

@PierreDugue

What are you trying to do?

I'm using material tabs. Is there a way to use the auto scroll when dragging a tab with CDK drag drop?
See :
https://stackblitz.com/edit/angular-wpv2er-djgsig?file=src%2Fapp%2Fcdk-drag-drop-horizontal-sorting-example.ts,src%2Fapp%2Fcdk-drag-drop-horizontal-sorting-example.html

What troubleshooting steps have you tried?

Trying to add cdkScrollable is not working.

Reproduction

Steps to reproduce:

  1. Create a mat-tab-nav-bar with a list of mat-tab-link inside (enough to trigger tabs pagination)
  2. Add cdk Dragdrop
  3. Try to drag a tab on the right or left to trigger pagination -> nothing is happening

Environment

  • Angular: latest version
  • CDK/Material: latest version
  • Browser(s): all
  • Operating System (e.g. Windows, macOS, Ubuntu): all

Metadata

Metadata

Assignees

No one assigned

    Labels

    P5The team acknowledges the request but does not plan to address it, it remains open for discussionarea: manyArea label for issues related to many componentstroubleshootingThis issue is not reporting an issue, but just asking for help

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions