| 
						
						
							
								
							
						
						
					 | 
				
			
			 | 
			 | 
			
				@ -622,6 +622,7 @@ export function fetchComposeSuggestions(token) {
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				      fetchComposeSuggestionsEmojis(dispatch, getState, token);
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				      break;
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				    case '#':
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				    case '#':
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				      fetchComposeSuggestionsTags(dispatch, getState, token);
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				      break;
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				    default:
 | 
			
		
		
	
	
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
				
			
			 | 
			 | 
			
				@ -663,11 +664,11 @@ export function selectComposeSuggestion(position, token, suggestion, path) {
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				      dispatch(useEmoji(suggestion));
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				    } else if (suggestion.type === 'hashtag') {
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				      completion    = `#${suggestion.name}`;
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				      startPosition = position - 1;
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				      completion    = suggestion.name.slice(token.length - 1);
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				      startPosition = position + token.length;
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				    } else if (suggestion.type === 'account') {
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				      completion    = getState().getIn(['accounts', suggestion.id, 'acct']);
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				      startPosition = position;
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				      completion    = `@${getState().getIn(['accounts', suggestion.id, 'acct'])}`;
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				      startPosition = position - 1;
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				    }
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				    // We don't want to replace hashtags that vary only in case due to accessibility, but we need to fire off an event so that
 | 
			
		
		
	
	
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
				
			
			 | 
			 | 
			
				@ -727,7 +728,7 @@ function insertIntoTagHistory(recognizedTags, text) {
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				    // complicated because of new normalization rules, it's no longer just
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				    // a case sensitivity issue
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				    const names = recognizedTags.map(tag => {
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				      const matches = text.match(new RegExp(`#${tag.name}`, 'i'));
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				      const matches = text.match(new RegExp(`[##]${tag.name}`, 'i'));
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				      if (matches && matches.length > 0) {
 | 
			
		
		
	
		
			
				 | 
				 | 
			
			 | 
			 | 
			
				        return matches[0].slice(1);
 | 
			
		
		
	
	
		
			
				
					| 
						
							
								
							
						
						
						
					 | 
				
			
			 | 
			 | 
			
				
 
 |