angular / angular/components

Provide Automatic Binding of FormControl Error Messages and Status to input hints

Offen
#2,810 13 Kommentare 23 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
area: material/input feature needs: discussion P4
Vorherrschende Sprache
TypeScript
Sterne
25k
Forks
6.8k
Ø Merge
1 T. 8 Std.
Gemergte PRs (30 T.)
91

Beschreibung

#### Bug, feature request, or proposal:
This is a feature request.

This is related to #348, but is specifically asking for the material guidance to be a part of the framework, integrating with standard functionality of @angular/forms.

#### What is the expected behavior?

Looking at [Material Error Patterns](https://material.io/guidelines/patterns/errors.html), there seems to be a standard behavior of inlining form error message into the hint area (with a specific color).

screen shot 2017-01-25 at 6 58 03 pm

It also supports separating the existing hint from the error message via a comma.

screen shot 2017-01-25 at 6 59 02 pm

#### What is the current behavior?
Error state and messages are not handled.

#### What are the steps to reproduce?
There is nothing to show as this is feature that is yet to be implemented. [Material Error Patterns](https://material.io/guidelines/patterns/errors.html) should provide the expected behavior and visual treatment.

#### What is the use-case or motivation for changing an existing behavior?
The general gist is that if everyone were to follow the guidelines from material.io, you would end up with a fair amount of duplicate code for every input. The pervasiveness of the desired functionality seems like a prime candidate for handling at the framework level.

#### Which versions of Angular, Material, OS, browsers are affected?
All

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

Beitragsleitfaden

Beitragsleitfaden öffnen

Rechercherichtung

Beginne mit der Referenz zu Material Error Patterns und der in der Issue beschriebenen @angular/forms-Integration von Angular. Da keine Datei oder kein Test genannt ist, identifiziere die Einstiegspunkte des Frameworks und definiere die Abdeckung für die automatische Anzeige von Fehlern/Status, die Trennung von Hinweisen und die angeforderte visuelle Gestaltung; als erledigt gilt, wenn das Verhalten auf Framework-Ebene bereitgestellt wird, statt pro Eingabefeld dupliziert zu werden.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
angular, typescript
Bereich
frontend
Issue-Typ
Feature
Schwierigkeit
5/5
Geschätzter Aufwand
Über eine Woche
Aktivitätsstatus
Veraltet
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
25/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.