mirror of
https://github.com/hugo-fixit/FixIt.git
synced 2026-09-03 20:22:41 +00:00
🚸 Feat: focus code on unlock edit and blur code on lock edit (#76)
This commit is contained in:
Vendored
+1
-1
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -405,11 +405,13 @@ class Theme {
|
||||
$iconKey.classList.remove('fa-key');
|
||||
$iconKey.title = this.config.code.editLockTitle;
|
||||
$preChroma.setAttribute('contenteditable', true);
|
||||
$preChroma.focus();
|
||||
} else {
|
||||
$iconLock.classList.add('fa-key');
|
||||
$iconLock.classList.remove('fa-lock');
|
||||
$iconLock.title = this.config.code.editUnLockTitle;
|
||||
$preChroma.setAttribute('contenteditable', false);
|
||||
$preChroma.blur();
|
||||
}
|
||||
}, false);
|
||||
$header.appendChild($edit);
|
||||
|
||||
Reference in New Issue
Block a user