angular / angular/components

[Sort] Implement API to clear sort

Ouverte
#10,524 12 commentaires 10 réactions 0 personnes assignées Voir sur GitHub
area: material/sort feature P3
Langage dominant
TypeScript
Étoiles
25k
Forks
6.8k
Merge moyen
1 j 8 h
PR mergées (30 j)
91

Description

#### Bug, feature request, or proposal:
I would like to know if there is a provision available to clear the sorting set by user on a mat-table column dynamically.

#### What is the expected behavior?
Provision to clear sort order set by user on mat-table

#### What is the current behavior?
Once user applies sort on a particular column, it is maintained permanently.

#### What are the steps to reproduce?
Click on one column header of a mat-table with sorting implemented. The table will be sorted based on the column data. Now if we need to reset the sorting, we need to click on the same column header 2 more times.

#### What is the use-case or motivation for changing an existing behavior?
Our requirement is to reset the user selected sort order on every reload.

#### Which versions of Angular, Material, OS, TypeScript, browsers are affected?
Angular CLI: 1.7.3
Node: 8.9.4
OS: win32 x64
Angular: 5.2.9

#### Is there anything else we should know?

Guide de contribution

Ouvrir le guide de contribution

Piste de recherche

Commencez au point d’entrée du tri de mat-table et suivez la façon dont l’état de tri sélectionné par l’utilisateur est conservé. Définissez l’API de clear-sorting autour du comportement de réinitialisation demandé, puis vérifiez qu’une table peut revenir à son état non trié sans nécessiter de clics répétés sur les en-têtes.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Évaluation

Stack technique
angular, typescript
Domaine
frontend
Type d'issue
Fonctionnalité
Difficulté
3/5
Temps estimé
1-2 jours
Activité
À l'abandon
Clarté
Plutôt claire
Accessibilité débutants
38/100

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.