Skip to content
Snippets Groups Projects
ShortcutsModal.vue 5.09 KiB
Newer Older
  • Learn to ignore specific revisions
  • Georg Krause's avatar
    Georg Krause committed
      <modal
        :show="show"
        @update:show="$emit('update:show', $event)"
      >
    
    Georg Krause's avatar
    Georg Krause committed
          <translate translate-context="*/*/*/Noun">
            Keyboard shortcuts
          </translate>
    
          <div class="ui stackable two column grid">
            <div class="column">
              <table
                v-for="section in player"
    
    Georg Krause's avatar
    Georg Krause committed
                :key="section.title"
                class="ui compact basic table"
              >
                <caption>{{ section.title }}</caption>
                <tbody>
                  <tr
                    v-for="shortcut in section.shortcuts"
                    :key="shortcut.summary"
                  >
                    <td>{{ shortcut.summary }}</td>
                    <td><span class="ui label">{{ shortcut.key }}</span></td>
                  </tr>
                </tbody>
    
              </table>
            </div>
            <div class="column">
              <table
                v-for="section in general"
    
    Georg Krause's avatar
    Georg Krause committed
                :key="section.title"
                class="ui compact basic table"
              >
                <caption>{{ section.title }}</caption>
                <tbody>
                  <tr
                    v-for="shortcut in section.shortcuts"
                    :key="shortcut.summary"
                  >
                    <td>{{ shortcut.summary }}</td>
                    <td><span class="ui label">{{ shortcut.key }}</span></td>
                  </tr>
                </tbody>
    
              </table>
            </div>
          </div>
    
    Georg Krause's avatar
    Georg Krause committed
          <button class="ui basic cancel button">
            <translate translate-context="*/*/Button.Label/Verb">
              Close
            </translate>
          </button>
    
    Georg Krause's avatar
    Georg Krause committed
        Modal: () => import('@/components/semantic/Modal.vue')
    
    Georg Krause's avatar
    Georg Krause committed
      props: { show: { type: Boolean, required: true } },
    
    jovuit's avatar
    jovuit committed
              title: this.$pgettext('Popup/Keyboard shortcuts/Title', 'General shortcuts'),
    
    jovuit's avatar
    jovuit committed
                  summary: this.$pgettext('Popup/Keyboard shortcuts/Table.Label/Verb', 'Show available keyboard shortcuts')
    
                },
                {
                  key: 'shift + f',
                  summary: this.$pgettext('Popup/Keyboard shortcuts/Table.Label/Verb', 'Focus searchbar')
                },
                {
                  key: 'esc',
                  summary: this.$pgettext('Popup/Keyboard shortcuts/Table.Label/Verb', 'Unfocus searchbar')
    
    Georg Krause's avatar
    Georg Krause committed
                }
    
    Georg Krause's avatar
    Georg Krause committed
            }
    
        player () {
          return [
    
    jovuit's avatar
    jovuit committed
              title: this.$pgettext('Popup/Keyboard shortcuts/Title', 'Audio player shortcuts'),
    
    jovuit's avatar
    jovuit committed
                  summary: this.$pgettext('Popup/Keyboard shortcuts/Table.Label/Verb', 'Pause/play the current track')
    
                  key: 'left',
                  summary: this.$pgettext('Popup/Keyboard shortcuts/Table.Label/Verb', 'Seek backwards 5s')
                },
                {
                  key: 'right',
                  summary: this.$pgettext('Popup/Keyboard shortcuts/Table.Label/Verb', 'Seek forwards 5s')
                },
                {
                  key: 'shift + left',
                  summary: this.$pgettext('Popup/Keyboard shortcuts/Table.Label/Verb', 'Seek backwards 30s')
                },
                {
                  key: 'shift + right',
                  summary: this.$pgettext('Popup/Keyboard shortcuts/Table.Label/Verb', 'Seek forwards 30s')
                },
                {
                  key: 'ctrl + shift + left',
    
    jovuit's avatar
    jovuit committed
                  summary: this.$pgettext('Popup/Keyboard shortcuts/Table.Label/Verb', 'Play previous track')
    
                  key: 'ctrl + shift + right',
    
    jovuit's avatar
    jovuit committed
                  summary: this.$pgettext('Popup/Keyboard shortcuts/Table.Label/Verb', 'Play next track')
    
                  key: 'shift + up',
    
    jovuit's avatar
    jovuit committed
                  summary: this.$pgettext('Popup/Keyboard shortcuts/Table.Label/Verb', 'Increase volume')
    
                  key: 'shift + down',
    
    jovuit's avatar
    jovuit committed
                  summary: this.$pgettext('Popup/Keyboard shortcuts/Table.Label/Verb', 'Decrease volume')
    
                {
                  key: 'm',
                  summary: this.$pgettext('Popup/Keyboard shortcuts/Table.Label/Verb', 'Toggle mute')
                },
    
                {
                  key: 'e',
                  summary: this.$pgettext('Popup/Keyboard shortcuts/Table.Label/Verb', 'Expand queue/player view')
                },
    
    jovuit's avatar
    jovuit committed
                  summary: this.$pgettext('Popup/Keyboard shortcuts/Table.Label/Verb', 'Toggle queue looping')
    
    jovuit's avatar
    jovuit committed
                  summary: this.$pgettext('Popup/Keyboard shortcuts/Table.Label/Verb', 'Shuffle queue')
    
                {
                  key: 'q',
                  summary: this.$pgettext('Popup/Keyboard shortcuts/Table.Label/Verb', 'Clear queue')
                },
                {
                  key: 'f',
                  summary: this.$pgettext('Popup/Keyboard shortcuts/Table.Label/Verb', 'Toggle favorite')