mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-07-28 17:02:04 +03:00
Changelog: Tweaked spacing, count and element referencing
During review of #5663
This commit is contained in:
@ -25,6 +25,7 @@ export class PageEditor extends Component {
|
||||
this.draftDisplayIcon = this.$refs.draftDisplayIcon;
|
||||
this.changelogInput = this.$refs.changelogInput;
|
||||
this.changelogDisplay = this.$refs.changelogDisplay;
|
||||
this.changelogCounter = this.$refs.changelogCounter;
|
||||
this.changeEditorButtons = this.$manyRefs.changeEditor || [];
|
||||
this.switchDialogContainer = this.$refs.switchDialog;
|
||||
this.deleteDraftDialogContainer = this.$refs.deleteDraftDialog;
|
||||
@ -77,8 +78,7 @@ export class PageEditor extends Component {
|
||||
const updateChangelogDebounced = debounce(this.updateChangelogDisplay.bind(this), 300, false);
|
||||
this.changelogInput.addEventListener('input', () => {
|
||||
const count = this.changelogInput.value.length;
|
||||
const counterEl = document.getElementById('changelog-count');
|
||||
if (counterEl) counterEl.innerText = `${count} / 250`;
|
||||
this.changelogCounter.innerText = `${count} / 180`;
|
||||
updateChangelogDebounced();
|
||||
});
|
||||
|
||||
|
Reference in New Issue
Block a user