diff --git a/client/html/posts_header.tpl b/client/html/posts_header.tpl index 28938c8..1c27e02 100644 --- a/client/html/posts_header.tpl +++ b/client/html/posts_header.tpl @@ -8,11 +8,11 @@
- - '/> - '/> - '/> - Syntax help + + '/> + '/> + '/> + Syntax help
diff --git a/client/js/views/posts_header_view.js b/client/js/views/posts_header_view.js index 7a482e8..261aa87 100644 --- a/client/js/views/posts_header_view.js +++ b/client/js/views/posts_header_view.js @@ -30,6 +30,14 @@ class PostsHeaderView { form.querySelector('input').focus(); }); + keyboard.bind('p', () => { + const firstPostNode + = document.body.querySelector('.post-list li:first-child a'); + if (firstPostNode) { + firstPostNode.focus(); + } + }); + for (let safetyButton of form.querySelectorAll('.safety')) { safetyButton.addEventListener( 'click', e => this._evtSafetyButtonClick(e, ctx.clientUrl));