MatTab: selectedTabChange should not fire when the tab is changed programmatically
- Langage dominant
- TypeScript
- Étoiles
- 25k
- Forks
- 6.8k
- Merge moyen
- 1 j 8 h
- PR mergées (30 j)
- 91
Description
There should be a way to differentiate **between a UI and a programmaticcally induced tab change**. As of now, both cause the selectedTabChange: EventEmitter to emit.
My case is pretty simple: I want to display the currently opened Tab in the URL:
somePage?openedTab=1
somePage?openedTab=2
But I also want the corresponding tab to open when a URL pointing to a specific tab is navigated to. **Ideally, the [selectedIndex] input should not cause (selectedTabChange) to fire**.
Does this make sense?
Material 8.2.3, Angular 8.2.11
Guide de contribution
Ouvrir le guide de contribution
Piste de recherche
Commencez par le comportement de l’input selectedIndex et de l’EventEmitter selectedTabChange de MatTab décrit dans l’issue. Déterminez comment distinguer les changements de l’UI des changements programmatiques, puis vérifiez que les changements pilotés par l’URL ne déclenchent pas la notification de changement de l’UI, tandis que les changements d’onglet effectués par l’utilisateur la déclenchent toujours.
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é
- 4/5
- Temps estimé
- 3-5 jours
- Activité
- À l'abandon
- Clarté
- Plutôt claire
- Accessibilité débutants
- 35/100