diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-01-28 06:09:02 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-01-28 06:09:02 +0300 |
commit | deb09d4cc12ea6302ef0b7534e1a1b5789732472 (patch) | |
tree | dd844d6373a0d5959c343ed50945a4c6119d7df5 | |
parent | 31aa5407f8ebffd4cf8f4c31e1133e310dc0a30f (diff) |
Add latest changes from gitlab-org/gitlab@master
9 files changed, 39 insertions, 29 deletions
diff --git a/app/assets/javascripts/batch_comments/components/draft_note.vue b/app/assets/javascripts/batch_comments/components/draft_note.vue index 74069b61f07..6e55022e1cc 100644 --- a/app/assets/javascripts/batch_comments/components/draft_note.vue +++ b/app/assets/javascripts/batch_comments/components/draft_note.vue @@ -79,7 +79,6 @@ export default { </script> <template> <article - role="article" class="draft-note-component note-wrapper" @mouseenter="handleMouseEnter(draft)" @mouseleave="handleMouseLeave(draft)" diff --git a/app/assets/javascripts/groups/components/group_item.vue b/app/assets/javascripts/groups/components/group_item.vue index d65ad974c73..4082d05c9e9 100644 --- a/app/assets/javascripts/groups/components/group_item.vue +++ b/app/assets/javascripts/groups/components/group_item.vue @@ -179,7 +179,12 @@ export default { <div class="metadata align-items-md-center d-flex flex-grow-1 flex-shrink-0 flex-wrap justify-content-md-between" > - <item-actions v-if="isGroup" :group="group" :parent-group="parentGroup" /> + <item-actions + v-if="isGroup" + :group="group" + :parent-group="parentGroup" + :action="action" + /> <item-stats :item="group" class="group-stats gl-mt-2 d-none d-md-flex" /> </div> </div> diff --git a/app/assets/javascripts/milestones/components/milestone_results_section.vue b/app/assets/javascripts/milestones/components/milestone_results_section.vue index d53a59e58d4..b866977b974 100644 --- a/app/assets/javascripts/milestones/components/milestone_results_section.vue +++ b/app/assets/javascripts/milestones/components/milestone_results_section.vue @@ -77,12 +77,7 @@ export default { </div> </template> <template v-else> - <gl-dropdown-item - v-for="{ title } in items" - :key="title" - role="milestone option" - @click="$emit('selected', title)" - > + <gl-dropdown-item v-for="{ title } in items" :key="title" @click="$emit('selected', title)"> <span class="gl-pl-6" :class="{ 'selected-item': isSelectedMilestone(title) }"> {{ title }} </span> diff --git a/app/assets/javascripts/related_issues/components/related_issues_block.vue b/app/assets/javascripts/related_issues/components/related_issues_block.vue index 2591e3e7f48..6f43cf1989d 100644 --- a/app/assets/javascripts/related_issues/components/related_issues_block.vue +++ b/app/assets/javascripts/related_issues/components/related_issues_block.vue @@ -146,7 +146,7 @@ export default { class="gl-display-flex gl-align-items-center gl-ml-2 gl-text-gray-500" :aria-label="__('Read more about related issues')" > - <gl-icon name="question" :size="12" role="text" /> + <gl-icon name="question" :size="12" /> </gl-link> <div class="gl-display-inline-flex"> diff --git a/app/assets/javascripts/vue_merge_request_widget/components/mr_widget_header.vue b/app/assets/javascripts/vue_merge_request_widget/components/mr_widget_header.vue index 6628ab7be83..26693a8f51c 100644 --- a/app/assets/javascripts/vue_merge_request_widget/components/mr_widget_header.vue +++ b/app/assets/javascripts/vue_merge_request_widget/components/mr_widget_header.vue @@ -133,14 +133,12 @@ export default { v-gl-tooltip :title="ideButtonTitle" class="gl-display-none d-md-inline-block gl-mr-3" - :tabindex="!mr.canPushToSourceBranch ? 0 : null" + :tabindex="ideButtonTitle ? 0 : null" > <gl-button :href="webIdePath" :disabled="!mr.canPushToSourceBranch" class="js-web-ide" - tabindex="0" - role="button" data-qa-selector="open_in_web_ide_button" > {{ s__('mrWidget|Open in Web IDE') }} diff --git a/app/assets/javascripts/vue_merge_request_widget/components/mr_widget_pipeline.vue b/app/assets/javascripts/vue_merge_request_widget/components/mr_widget_pipeline.vue index e0729e69283..3ff7d436c97 100644 --- a/app/assets/javascripts/vue_merge_request_widget/components/mr_widget_pipeline.vue +++ b/app/assets/javascripts/vue_merge_request_widget/components/mr_widget_pipeline.vue @@ -139,41 +139,33 @@ export default { <div class="ci-widget media"> <template v-if="hasCIError"> <gl-icon name="status_failed" class="gl-text-red-500" :size="24" /> - <div - class="gl-flex-fill-1 gl-ml-5" - tabindex="0" - role="text" - :aria-label="$options.errorText" - data-testid="ci-error-message" - > + <p class="gl-flex-fill-1 gl-ml-5 gl-mb-0" data-testid="ci-error-message"> <gl-sprintf :message="$options.errorText"> <template #link="{ content }"> <gl-link :href="mrTroubleshootingDocsPath">{{ content }}</gl-link> </template> </gl-sprintf> - </div> + </p> </template> <template v-else-if="!hasPipeline"> <gl-loading-icon size="md" /> - <div class="gl-flex-fill-1 gl-display-flex gl-ml-5" data-testid="monitoring-pipeline-message"> - <span tabindex="0" role="text" :aria-label="$options.monitoringPipelineText"> - <gl-sprintf :message="$options.monitoringPipelineText" /> - </span> + <p + class="gl-flex-fill-1 gl-display-flex gl-ml-5 gl-mb-0" + data-testid="monitoring-pipeline-message" + > + {{ $options.monitoringPipelineText }} <gl-link :href="ciTroubleshootingDocsPath" target="_blank" class="gl-display-flex gl-align-items-center gl-ml-2" - tabindex="0" > <gl-icon name="question" :size="12" - tabindex="0" - role="text" :aria-label="__('Link to go to GitLab pipeline documentation')" /> </gl-link> - </div> + </p> </template> <template v-else-if="hasPipeline"> <a :href="status.details_path" class="align-self-start gl-mr-3"> diff --git a/changelogs/unreleased/296521-leave-this-group-button-not-working.yml b/changelogs/unreleased/296521-leave-this-group-button-not-working.yml new file mode 100644 index 00000000000..9fea6214cae --- /dev/null +++ b/changelogs/unreleased/296521-leave-this-group-button-not-working.yml @@ -0,0 +1,5 @@ +--- +title: Missing action prop on group page +merge_request: 52379 +author: +type: fixed diff --git a/lib/gitlab/utils/markdown.rb b/lib/gitlab/utils/markdown.rb index d5fd765bcfd..5087020affe 100644 --- a/lib/gitlab/utils/markdown.rb +++ b/lib/gitlab/utils/markdown.rb @@ -4,7 +4,7 @@ module Gitlab module Utils module Markdown PUNCTUATION_REGEXP = /[^\p{Word}\- ]/u.freeze - PRODUCT_SUFFIX = /\s*\**\((core|starter|premium|ultimate)(\s+(only|self|sass))?\)\**/.freeze + PRODUCT_SUFFIX = /\s*\**\((core|starter|premium|ultimate|free|bronze|silver|gold)(\s+(only|self|sass))?\)\**/.freeze def string_to_anchor(string) string diff --git a/spec/frontend/groups/components/item_actions_spec.js b/spec/frontend/groups/components/item_actions_spec.js index 9adbc9abe13..ffbdf9b1aa6 100644 --- a/spec/frontend/groups/components/item_actions_spec.js +++ b/spec/frontend/groups/components/item_actions_spec.js @@ -66,6 +66,22 @@ describe('ItemActions', () => { }); }); + it('emits `showLeaveGroupModal` event with the correct prefix if `action` prop is passed', () => { + const group = { + ...mockParentGroupItem, + canEdit: true, + canLeave: true, + }; + createComponent({ + group, + action: 'test', + }); + jest.spyOn(eventHub, '$emit'); + findLeaveGroupBtn().vm.$emit('click', { stopPropagation: () => {} }); + + expect(eventHub.$emit).toHaveBeenCalledWith('testshowLeaveGroupModal', group, parentGroup); + }); + it('does not render leave button if group can not be left', () => { createComponent({ group: { |