mirror of
				https://github.com/lingble/chatwoot.git
				synced 2025-10-31 02:57:57 +00:00 
			
		
		
		
	 d88d0bdd80
			
		
	
	d88d0bdd80
	
	
	
		
			
			* feat: add avatar * chore: add more colors * chore: add helpers * chore: build prettier issues * chore: refactor shouldShowImage * chore: code cleanup * Update app/javascript/v3/components/Form/InitialsAvatar.vue Co-authored-by: Sivin Varghese <64252451+iamsivin@users.noreply.github.com> * chore: revire comments --------- Co-authored-by: Sivin Varghese <64252451+iamsivin@users.noreply.github.com>
		
			
				
	
	
		
			11 lines
		
	
	
		
			345 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
			
		
		
	
	
			11 lines
		
	
	
		
			345 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
| import { userInitial } from '../CommonHelper';
 | |
| 
 | |
| describe('#userInitial', () => {
 | |
|   it('returns the initials of the user', () => {
 | |
|     expect(userInitial('John Doe')).toEqual('JD');
 | |
|     expect(userInitial('John')).toEqual('J');
 | |
|     expect(userInitial('John-Doe')).toEqual('JD');
 | |
|     expect(userInitial('John Doe Smith')).toEqual('JD');
 | |
|   });
 | |
| });
 |