alfresco-ng2-components/docs/core/user-initial.pipe.md
Andy Stark 347b2bb5e8 [ADF-2526] Fixed interpolation marker issue in doc files (#3098)
* [ADF-2526] Test commit of a file with escape tags

* [ADF-2526] Fixed interpolation marker issue in doc code samples
2018-03-20 14:03:12 +00:00

30 lines
732 B
Markdown

---
Added: v2.0.0
Status: Active
---
# User Initial pipe
Takes the name fields of a UserProcessModel object and extracts and formats the initials.
## Basic Usage
<!-- {% raw %} -->
```HTML
<div>
Project Leader: {{ user | usernameInitials:"initialsClass" }}
</div>
```
<!-- {% endraw %} -->
## Details
The pipe gets the initial characters of the user's first and last names and
concatenates them. The results are returned in an HTML &lt;div> element.
The first pipe parameter specifies an optional CSS class to add to the &lt;div>
element (eg, a background color is commonly used to emphasise initials). The
second parameter is an optional delimiter to add between the initials.
Both parameters default to empty strings.