Skip to content

Commit

Permalink
#1370 | Ensure only first two characters of initials are taken
Browse files Browse the repository at this point in the history
  • Loading branch information
vinayvenu committed Apr 28, 2024
1 parent bb937cf commit 6ffa48f
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ import _, {isEmpty} from 'lodash';
import AvniModel from "./AvniModel";
import Styles from "../primitives/Styles";

function Initials({name}) {
const initials = name.split(' ').map(n => n[0].toUpperCase()).join('');
function Initials({name = ''}) {
const initials = name.split(' ').map(n => n[0].toUpperCase()).join('').substring(0,2);
return <Text style={{
color: Styles.blackColor,
fontWeight: 'bold',
Expand Down

0 comments on commit 6ffa48f

Please sign in to comment.