fix: made placeholder for textarea, added outline offset

This commit is contained in:
2025-11-19 16:12:55 +03:00
parent 1ba701737e
commit 4f32be0b93
2 changed files with 5 additions and 2 deletions

View File

@@ -6,7 +6,7 @@ function localizePage(): void {
const message = (element as HTMLElement).dataset.i18n!;
const localizedText = chrome.i18n.getMessage(message);
if (localizedText) {
if (element.tagName === 'INPUT' && (element as HTMLInputElement).hasAttribute('placeholder')) {
if ((element.tagName === 'INPUT' || element.tagName === 'TEXTAREA') && (element as HTMLInputElement).hasAttribute('placeholder')) {
(element as HTMLInputElement).placeholder = localizedText;
} else {
element.textContent = localizedText;