Commit b5c46172 authored by Coung Ngo's avatar Coung Ngo Committed by Miguel Rincon

Show all quick actions in `/` autocomplete

Only 5 quick actions are shown at maximum in the autocomplete
menu currently. To improve discoverability of all quick
actions, all quick actions (assuming there's less than 100)
will be shown.

https://gitlab.com/gitlab-org/gitlab/-/issues/292393
parent c1be1689
......@@ -103,6 +103,7 @@ class GfmAutoComplete {
at: '/',
alias: 'commands',
searchKey: 'search',
limit: 100,
skipSpecialCharacterTest: true,
skipMarkdownCharacterTest: true,
data: GfmAutoComplete.defaultLoadingData,
......
---
title: Show all quick actions in `/` autocomplete
merge_request: 51239
author:
type: added
......@@ -9,8 +9,10 @@ info: To determine the technical writer assigned to the Stage/Group associated w
> - Introduced in [GitLab 12.1](https://gitlab.com/gitlab-org/gitlab-foss/-/merge_requests/26672):
> once an action is executed, an alert appears when a quick action is successfully applied.
> - In [GitLab 13.2](https://gitlab.com/gitlab-org/gitlab/-/issues/16877) and later, you can use
> - Introduced in [GitLab 13.2](https://gitlab.com/gitlab-org/gitlab/-/issues/16877): you can use
> quick actions when updating the description of issues, epics, and merge requests.
> - Introduced in [GitLab 13.8](https://gitlab.com/gitlab-org/gitlab/-/issues/292393): when you enter
> `/` into a description or comment field, all available quick actions are displayed in a scrollable list.
Quick actions are textual shortcuts for common actions on issues, epics, merge requests,
and commits that are usually done by clicking buttons or dropdowns in the GitLab UI.
......
......@@ -294,6 +294,15 @@ RSpec.describe 'GFM autocomplete', :js do
user_item = find('.atwho-view li', text: user.username)
expect(user_item).to have_content(user.username)
end
it 'does not limit quick actions autocomplete list to 5' do
note = find('#note-body')
page.within '.timeline-content-form' do
note.native.send_keys('/')
end
expect(page).to have_selector('.atwho-view li', minimum: 6, visible: true)
end
end
context 'assignees' do
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment