diff --git a/projects/stream-chat-angular/src/lib/message-input/autocomplete-textarea/autocomplete-textarea.component.ts b/projects/stream-chat-angular/src/lib/message-input/autocomplete-textarea/autocomplete-textarea.component.ts index 29dabac7..3fe8f4a4 100644 --- a/projects/stream-chat-angular/src/lib/message-input/autocomplete-textarea/autocomplete-textarea.component.ts +++ b/projects/stream-chat-angular/src/lib/message-input/autocomplete-textarea/autocomplete-textarea.component.ts @@ -133,6 +133,7 @@ export class AutocompleteTextareaComponent private transliterationService: TransliterationService, private emojiInputService: EmojiInputService, private customTemplatesService: CustomTemplatesService, + private themeService: ThemeService, private cdRef: ChangeDetectorRef ) { this.searchTerm$.pipe(debounceTime(300)).subscribe((searchTerm) => { @@ -199,7 +200,7 @@ export class AutocompleteTextareaComponent } if (changes.value && !this.value && this.messageInput) { this.messageInput.nativeElement.style.height = 'auto'; - this.chatClientService?.chatClient?.logger?.( + this.chatClientService.chatClient.logger( 'info', '[Autocomplete textarea] Value reset, adjusting textarea height to auto' ); @@ -210,7 +211,7 @@ export class AutocompleteTextareaComponent this.messageInput && this.isViewInited ) { - this.chatClientService?.chatClient?.logger?.( + this.chatClientService.chatClient.logger( 'info', '[Autocomplete textarea] Value changed' ); @@ -224,7 +225,7 @@ export class AutocompleteTextareaComponent ngAfterViewInit(): void { this.isViewInited = true; - this.chatClientService?.chatClient?.logger?.( + this.chatClientService.chatClient.logger( 'info', '[Autocomplete textarea] View inited' ); @@ -262,7 +263,7 @@ export class AutocompleteTextareaComponent inputChanged() { this.valueChange.emit(this.messageInput.nativeElement.value); - this.chatClientService?.chatClient?.logger?.( + this.chatClientService.chatClient.logger( 'info', '[Autocomplete textarea] Input changed' ); @@ -284,12 +285,12 @@ export class AutocompleteTextareaComponent private adjustTextareaHeight() { const necessaryHeight = `${this.messageInput.nativeElement.scrollHeight}px`; if (this.messageInput.nativeElement.style.height === necessaryHeight) { - this.chatClientService?.chatClient?.logger?.( + this.chatClientService.chatClient.logger( 'info', `[Autocomplete textarea] No need to adjust textarea height` ); } else { - this.chatClientService?.chatClient?.logger?.( + this.chatClientService.chatClient.logger( 'info', `[Autocomplete textarea] Adjusting textarea height to ${necessaryHeight}` );