We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f569ca3 commit 39c1cdbCopy full SHA for 39c1cdb
scripts/apps/authoring/authoring/components/CharacterCount.tsx
@@ -10,8 +10,8 @@ interface IProps {
10
item: string;
11
}
12
13
-export function getEditorFieldCharactersCount(text: string, html?: boolean) {
14
- let input = text?.trim() ?? '';
+export function getEditorFieldCharactersCount(text: string | number, html?: boolean) {
+ let input = `${text ?? ''}`.trim();
15
16
input = html ? cleanHtml(input) : input;
17
input = input.replace(/\r?\n|\r/g, '');
0 commit comments