2019-09-21 20:42:56 +00:00
|
|
|
<div class="shortcut-help-info {inDialog ? 'in-dialog' : ''}"
|
|
|
|
tabindex="{inDialog ? '0' : '-1'}"
|
|
|
|
>
|
2019-03-03 04:06:56 +00:00
|
|
|
<!-- Svelte makes this file kind of ridiculously large for a static page (~17kB),
|
|
|
|
so just use raw HTML here to make it smaller -->
|
|
|
|
{@html `
|
2019-01-20 00:40:31 +00:00
|
|
|
<h2>Global</h2>
|
|
|
|
<div class="hotkey-group">
|
2019-09-23 06:53:29 +00:00
|
|
|
${$leftRightChangesFocus ?
|
|
|
|
`
|
|
|
|
<ul>
|
|
|
|
<li><kbd>→</kbd> to go to the next focusable element</li>
|
|
|
|
<li><kbd>←</kbd> to go to the previous focusable element</li>
|
|
|
|
</ul>
|
|
|
|
` : ''}
|
2019-01-20 00:40:31 +00:00
|
|
|
<ul>
|
2019-09-23 06:53:29 +00:00
|
|
|
<li>
|
|
|
|
<kbd>1</kbd> - <kbd>6</kbd>
|
|
|
|
${$leftRightChangesFocus ? '' : `or <kbd>←</kbd>/<kbd>→</kbd>`}
|
|
|
|
to switch columns
|
|
|
|
</li>
|
2019-09-21 20:43:24 +00:00
|
|
|
<li><kbd>7</kbd> or <kbd>c</kbd> to compose a new toot</li>
|
|
|
|
<li><kbd>s</kbd> to search</li>
|
2019-01-20 00:40:31 +00:00
|
|
|
<li><kbd>g</kbd> + <kbd>h</kbd> to go home</li>
|
|
|
|
<li><kbd>g</kbd> + <kbd>n</kbd> to go to notifications</li>
|
|
|
|
<li><kbd>g</kbd> + <kbd>l</kbd> to go to the local timeline</li>
|
|
|
|
<li><kbd>g</kbd> + <kbd>t</kbd> to go to the federated timeline</li>
|
|
|
|
<li><kbd>g</kbd> + <kbd>c</kbd> to go to the community page</li>
|
2019-04-02 10:05:27 +00:00
|
|
|
<li><kbd>g</kbd> + <kbd>d</kbd> to go to the conversations page</li>
|
2019-01-20 00:40:31 +00:00
|
|
|
<li><kbd>h</kbd> or <kbd>?</kbd> to toggle the help dialog</li>
|
|
|
|
<li><kbd>Backspace</kbd> to go back, close dialogs</li>
|
|
|
|
</ul>
|
|
|
|
</div>
|
2019-03-18 16:09:24 +00:00
|
|
|
<h2>Timeline</h2>
|
2019-01-20 00:40:31 +00:00
|
|
|
<div class="hotkey-group">
|
|
|
|
<ul>
|
2019-03-18 16:09:24 +00:00
|
|
|
<li><kbd>j</kbd> or <kbd>↓</kbd> to activate the next toot</li>
|
|
|
|
<li><kbd>k</kbd> or <kbd>↑</kbd> to activate the previous toot</li>
|
|
|
|
<li><kbd>.</kbd> to show more and scroll to top</li>
|
|
|
|
<li><kbd>o</kbd> to open</li>
|
2019-01-20 00:40:31 +00:00
|
|
|
<li><kbd>f</kbd> to favorite</li>
|
|
|
|
<li><kbd>b</kbd> to boost</li>
|
|
|
|
<li><kbd>r</kbd> to reply</li>
|
|
|
|
<li><kbd>m</kbd> to mention the author</li>
|
|
|
|
<li><kbd>p</kbd> to open the author's profile</li>
|
2019-04-10 14:56:24 +00:00
|
|
|
<li><kbd>l</kbd> to open the card's link in a new tab</li>
|
2019-01-20 00:40:31 +00:00
|
|
|
<li><kbd>x</kbd> to show or hide text behind content warning</li>
|
|
|
|
<li><kbd>y</kbd> to show or hide sensitive media</li>
|
|
|
|
</ul>
|
|
|
|
</div>
|
2019-02-03 19:56:07 +00:00
|
|
|
<h2>Media</h2>
|
|
|
|
<div class="hotkey-group">
|
|
|
|
<ul>
|
2019-09-23 06:53:29 +00:00
|
|
|
<li><kbd>←</kbd> / <kbd>→</kbd> to go to next or previous</li>
|
2019-02-03 19:56:07 +00:00
|
|
|
</ul>
|
|
|
|
</div>
|
2019-03-03 04:06:56 +00:00
|
|
|
`}
|
2019-01-13 19:35:04 +00:00
|
|
|
</div>
|
|
|
|
<style>
|
2019-09-21 20:42:56 +00:00
|
|
|
.shortcut-help-info.in-dialog {
|
|
|
|
overflow-y: auto;
|
|
|
|
}
|
|
|
|
.shortcut-help-info.in-dialog:not(:focus) {
|
2019-01-20 00:40:31 +00:00
|
|
|
scrollbar-width: none;
|
2019-02-09 20:01:29 +00:00
|
|
|
-ms-overflow-style: none;
|
2019-01-20 00:40:31 +00:00
|
|
|
}
|
2019-09-21 20:42:56 +00:00
|
|
|
.shortcut-help-info.in-dialog:not(:focus)::-webkit-scrollbar {
|
2019-01-20 00:40:31 +00:00
|
|
|
display: none;
|
|
|
|
}
|
2019-03-03 04:06:56 +00:00
|
|
|
:global(.shortcut-help-info li) {
|
2019-01-13 19:35:04 +00:00
|
|
|
list-style-type: none;
|
|
|
|
}
|
2019-03-03 04:06:56 +00:00
|
|
|
:global(.shortcut-help-info.in-dialog li) {
|
2019-01-13 19:35:04 +00:00
|
|
|
color: var(--muted-modal-text);
|
2019-01-20 00:40:31 +00:00
|
|
|
font-size: 0.9em;
|
|
|
|
}
|
2019-03-03 04:06:56 +00:00
|
|
|
:global(.shortcut-help-info.in-dialog h2) {
|
2019-01-20 00:40:31 +00:00
|
|
|
color: var(--muted-modal-text);
|
|
|
|
}
|
2019-03-03 04:06:56 +00:00
|
|
|
:global(.shortcut-help-info.hotkey-group) {
|
2019-01-20 00:40:31 +00:00
|
|
|
margin: 0 0 10px 10px;
|
|
|
|
}
|
2019-03-03 04:06:56 +00:00
|
|
|
:global(.shortcut-help-info h2) {
|
2019-01-20 00:40:31 +00:00
|
|
|
margin: 10px 0;
|
2019-01-13 19:35:04 +00:00
|
|
|
}
|
2019-03-03 04:06:56 +00:00
|
|
|
:global(.shortcut-help-info kbd) {
|
2019-01-13 19:35:04 +00:00
|
|
|
color: #333;
|
|
|
|
display: inline-block;
|
|
|
|
border: 1px solid #333;
|
|
|
|
border-radius: 2px;
|
|
|
|
padding: 0.1em;
|
|
|
|
margin: 0.2em;
|
|
|
|
background-color: #dadada;
|
|
|
|
}
|
|
|
|
</style>
|
|
|
|
<script>
|
2019-09-23 06:53:29 +00:00
|
|
|
import { store } from '../_store/store'
|
|
|
|
|
2019-01-13 19:35:04 +00:00
|
|
|
export default {
|
2019-09-23 06:53:29 +00:00
|
|
|
store: () => store,
|
2019-01-13 19:35:04 +00:00
|
|
|
data: () => ({
|
|
|
|
inDialog: false
|
|
|
|
})
|
|
|
|
}
|
|
|
|
</script>
|