forked from EVOgeek/Vmeda.Online
		
	MOBILE-4272 rte: Fix contentChanged event types
This commit is contained in:
		
							parent
							
								
									aeb12fa472
								
							
						
					
					
						commit
						a07ae84f54
					
				| @ -111,7 +111,7 @@ export class AddonModAssignSubmissionOnlineTextComponent extends AddonModAssignS | |||||||
|      * |      * | ||||||
|      * @param text The new text. |      * @param text The new text. | ||||||
|      */ |      */ | ||||||
|     onChange(text: string): void { |     onChange(text?: string | null): void { | ||||||
|         // Count words if needed.
 |         // Count words if needed.
 | ||||||
|         if (this.wordLimitEnabled) { |         if (this.wordLimitEnabled) { | ||||||
|             // Cancel previous wait.
 |             // Cancel previous wait.
 | ||||||
|  | |||||||
| @ -332,8 +332,8 @@ export class AddonModForumPostComponent implements OnInit, OnDestroy, OnChanges | |||||||
|      * |      * | ||||||
|      * @param text The new text. |      * @param text The new text. | ||||||
|      */ |      */ | ||||||
|     onMessageChange(text: string): void { |     onMessageChange(text?: string | null): void { | ||||||
|         this.formData.message = text; |         this.formData.message = text ?? ''; | ||||||
|     } |     } | ||||||
| 
 | 
 | ||||||
|     /** |     /** | ||||||
|  | |||||||
| @ -511,8 +511,8 @@ export class AddonModForumNewDiscussionPage implements OnInit, OnDestroy, CanLea | |||||||
|      * |      * | ||||||
|      * @param text The new text. |      * @param text The new text. | ||||||
|      */ |      */ | ||||||
|     onMessageChange(text: string): void { |     onMessageChange(text?: string | null): void { | ||||||
|         this.newDiscussion.message = text; |         this.newDiscussion.message = text ?? ''; | ||||||
|     } |     } | ||||||
| 
 | 
 | ||||||
|     /** |     /** | ||||||
|  | |||||||
| @ -173,8 +173,8 @@ export class AddonModGlossaryEditPage implements OnInit, CanLeave { | |||||||
|      * |      * | ||||||
|      * @param text The new text. |      * @param text The new text. | ||||||
|      */ |      */ | ||||||
|     onDefinitionChange(text: string): void { |     onDefinitionChange(text?: string | null): void { | ||||||
|         this.data.definition = text; |         this.data.definition = text ?? ''; | ||||||
|     } |     } | ||||||
| 
 | 
 | ||||||
|     /** |     /** | ||||||
|  | |||||||
| @ -403,8 +403,8 @@ export class AddonModWorkshopAssessmentStrategyComponent implements OnInit, OnDe | |||||||
|      * |      * | ||||||
|      * @param text The new text. |      * @param text The new text. | ||||||
|      */ |      */ | ||||||
|     onFeedbackChange(text: string): void { |     onFeedbackChange(text?: string | null): void { | ||||||
|         this.feedbackText = text; |         this.feedbackText = text ?? ''; | ||||||
|     } |     } | ||||||
| 
 | 
 | ||||||
|     /** |     /** | ||||||
|  | |||||||
| @ -332,7 +332,7 @@ export class CoreTextUtilsProvider { | |||||||
|      * @param text Text to count. |      * @param text Text to count. | ||||||
|      * @returns Number of words. |      * @returns Number of words. | ||||||
|      */ |      */ | ||||||
|     countWords(text: string): number { |     countWords(text?: string | null): number { | ||||||
|         if (!text || typeof text != 'string') { |         if (!text || typeof text != 'string') { | ||||||
|             return 0; |             return 0; | ||||||
|         } |         } | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user