diff options
Diffstat (limited to 'usecaseui-portal/src/app/views/maas/maas-service.service.ts')
-rw-r--r-- | usecaseui-portal/src/app/views/maas/maas-service.service.ts | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/usecaseui-portal/src/app/views/maas/maas-service.service.ts b/usecaseui-portal/src/app/views/maas/maas-service.service.ts index 257f7a1c..3d4b9859 100644 --- a/usecaseui-portal/src/app/views/maas/maas-service.service.ts +++ b/usecaseui-portal/src/app/views/maas/maas-service.service.ts @@ -11,4 +11,11 @@ export class MaasService { return `${timestamp}${randomNum}`; } + updateCharCount(textarea: HTMLTextAreaElement, charCount: HTMLElement) { + const charCountValue = textarea.value.length; + const maxLength = textarea.getAttribute('maxlength'); + charCount.innerText = `${charCountValue}/${maxLength}`; + + } + } |