Angular Material Inputs - Angular Material

What is Angular Material Inputs?

The md-input-container an Angular directive, is a container component to comprise any <input> or <text area> element as a child. Md-input-container also supports error handling using the standard ng-messages directives and animates the messages using ngEnter/ngLeave events or the ngShow/ngHide events.

Attributes

S.N.

Parameter & Description

1

md-maxlength
The maximum number of characters allowed in this input. If this is specified, a character counter will be shown underneath the input. The purpose of md-maxlength is exactly to show the max length counter text. If you don't want the counter text and only need "plain" validation, you can use the "simple" ng-maxlength or maxlength attributes.

2

aria-label
Aria-label is required when no label is present. A warning message will be logged in the console if not present.

3

placeholder
An alternative approach to using aria-label when the label is not PRESENT. The placeholder text is copied to the aria-label attribute.

4

md-no-autogrow
When present, textareas will not grow automatically.

5

md-detect-hidden
When present, textareas will be sized properly when they are revealed after being hidden. This is off by default for performance reasons because it guarantees a reflow every digest cycle.

Example

The next instance showcases the use of md-input-container directive to showcase uses of inputs.

am_inputs.htm

Result

AM Inputs

All rights reserved © 2020 Wisdom IT Services India Pvt. Ltd DMCA.com Protection Status

Angular Material Topics