Skip to content
Snippets Groups Projects
Commit 0c6bc544 authored by GitLab Bot's avatar GitLab Bot
Browse files

Add latest changes from gitlab-org/gitlab@master

parent d7ce7307
No related branches found
No related tags found
No related merge requests found
Showing
with 76 additions and 55 deletions
Loading
Loading
@@ -27,7 +27,7 @@ export default {
<template>
<div class="landing content-block">
<button
:aria-label="__('Dismiss Cycle Analytics introduction box')"
:aria-label="__('Dismiss Value Stream Analytics introduction box')"
class="js-ca-dismiss-button dismiss-button"
type="button"
@click="dismissOverviewDialog"
Loading
Loading
@@ -36,10 +36,10 @@ export default {
</button>
<div class="svg-container" v-html="iconCycleAnalyticsSplash"></div>
<div class="inner-content">
<h4>{{ __('Introducing Cycle Analytics') }}</h4>
<h4>{{ __('Introducing Value Stream Analytics') }}</h4>
<p>
{{
__(`Cycle Analytics gives an overview
__(`Value Stream Analytics gives an overview
of how much time it takes to go from idea to production in your project.`)
}}
</p>
Loading
Loading
Loading
Loading
@@ -71,7 +71,7 @@ export default () => {
},
created() {
// Conditional check placed here to prevent this method from being called on the
// new Cycle Analytics page (i.e. the new page will be initialized blank and only
// new Value Stream Analytics page (i.e. the new page will be initialized blank and only
// after a group is selected the cycle analyitcs data will be fetched). Once the
// old (current) page has been removed this entire created method as well as the
// variable itself can be completely removed.
Loading
Loading
@@ -81,7 +81,7 @@ export default () => {
methods: {
handleError() {
this.store.setErrorState(true);
return new Flash(__('There was an error while fetching cycle analytics data.'));
return new Flash(__('There was an error while fetching value stream analytics data.'));
},
initDropdown() {
const $dropdown = $('.js-ca-dropdown');
Loading
Loading
<script>
import { mapActions, mapGetters, mapState } from 'vuex';
import { GlTooltipDirective, GlLink, GlButton } from '@gitlab/ui';
import { GlTooltipDirective, GlLink, GlButton, GlSprintf } from '@gitlab/ui';
import { __ } from '~/locale';
import { polyfillSticky } from '~/lib/utils/sticky';
import Icon from '~/vue_shared/components/icon.vue';
Loading
Loading
@@ -15,6 +15,7 @@ export default {
Icon,
GlLink,
GlButton,
GlSprintf,
SettingsDropdown,
DiffStats,
},
Loading
Loading
@@ -106,23 +107,29 @@ export default {
>
<icon name="file-tree" />
</button>
<div v-if="showDropdowns" class="d-flex align-items-center compare-versions-container">
{{ __('Compare') }}
<compare-versions-dropdown
:other-versions="mergeRequestDiffs"
:merge-request-version="mergeRequestDiff"
:show-commit-count="true"
class="mr-version-dropdown"
/>
{{ __('and') }}
<compare-versions-dropdown
:other-versions="comparableDiffs"
:base-version-path="baseVersionPath"
:start-version="startVersion"
:target-branch="targetBranch"
class="mr-version-compare-dropdown"
/>
</div>
<gl-sprintf
v-if="showDropdowns"
class="d-flex align-items-center compare-versions-container"
:message="s__('MergeRequest|Compare %{source} and %{target}')"
>
<template #source>
<compare-versions-dropdown
:other-versions="mergeRequestDiffs"
:merge-request-version="mergeRequestDiff"
:show-commit-count="true"
class="mr-version-dropdown"
/>
</template>
<template #target>
<compare-versions-dropdown
:other-versions="comparableDiffs"
:base-version-path="baseVersionPath"
:start-version="startVersion"
:target-branch="targetBranch"
class="mr-version-compare-dropdown"
/>
</template>
</gl-sprintf>
<div v-else-if="commit">
{{ __('Viewing commit') }}
<gl-link :href="commit.commit_url" class="monospace">{{ commit.short_id }}</gl-link>
Loading
Loading
<script>
import _ from 'underscore';
import { mapState, mapGetters, createNamespacedHelpers } from 'vuex';
import { sprintf, __ } from '~/locale';
import { sprintf, s__ } from '~/locale';
import consts from '../../stores/modules/commit/constants';
import RadioGroup from './radio_group.vue';
import NewMergeRequestOption from './new_merge_request_option.vue';
Loading
Loading
@@ -21,7 +21,7 @@ export default {
...mapGetters(['currentBranch']),
commitToCurrentBranchText() {
return sprintf(
__('Commit to %{branchName} branch'),
s__('IDE|Commit to %{branchName} branch'),
{ branchName: `<strong class="monospace">${_.escape(this.currentBranchId)}</strong>` },
false,
);
Loading
Loading
@@ -56,8 +56,8 @@ export default {
},
commitToCurrentBranch: consts.COMMIT_TO_CURRENT_BRANCH,
commitToNewBranch: consts.COMMIT_TO_NEW_BRANCH,
currentBranchPermissionsTooltip: __(
"This option is disabled as you don't have write permissions for the current branch",
currentBranchPermissionsTooltip: s__(
"IDE|This option is disabled because you don't have write permissions for the current branch.",
),
};
</script>
Loading
Loading
<script>
import { mapActions, mapState, mapGetters } from 'vuex';
import tooltip from '~/vue_shared/directives/tooltip';
import { GlTooltipDirective } from '@gitlab/ui';
 
export default {
directives: {
tooltip,
GlTooltip: GlTooltipDirective,
},
props: {
value: {
Loading
Loading
@@ -53,8 +53,7 @@ export default {
<template>
<fieldset>
<label
v-tooltip
:title="tooltipTitle"
v-gl-tooltip="tooltipTitle"
:class="{
'is-disabled': disabled,
}"
Loading
Loading
<script>
import $ from 'jquery';
import { mapActions, mapGetters, mapState } from 'vuex';
import _ from 'underscore';
import { isEmpty } from 'lodash';
import Autosize from 'autosize';
import { __, sprintf } from '~/locale';
import TimelineEntryItem from '~/vue_shared/components/notes/timeline_entry_item.vue';
Loading
Loading
@@ -161,7 +161,7 @@ export default {
'toggleStateButtonLoading',
]),
setIsSubmitButtonDisabled(note, isSubmitting) {
if (!_.isEmpty(note) && !isSubmitting) {
if (!isEmpty(note) && !isSubmitting) {
this.isSubmitButtonDisabled = false;
} else {
this.isSubmitButtonDisabled = true;
Loading
Loading
<script>
import { mapActions } from 'vuex';
import _ from 'underscore';
import { escape } from 'lodash';
 
import { s__, __, sprintf } from '~/locale';
import { truncateSha } from '~/lib/utils/text_utility';
Loading
Loading
@@ -45,7 +45,7 @@ export default {
return this.notes.length > 1 ? this.lastNote.created_at : null;
},
headerText() {
const linkStart = `<a href="${_.escape(this.discussion.discussion_path)}">`;
const linkStart = `<a href="${escape(this.discussion.discussion_path)}">`;
const linkEnd = '</a>';
 
const { commit_id: commitId } = this.discussion;
Loading
Loading
<script>
import $ from 'jquery';
import { mapGetters, mapActions } from 'vuex';
import { escape } from 'underscore';
import { escape } from 'lodash';
import draftMixin from 'ee_else_ce/notes/mixins/draft';
import { truncateSha } from '~/lib/utils/text_utility';
import TimelineEntryItem from '~/vue_shared/components/notes/timeline_entry_item.vue';
Loading
Loading
<script>
import _ from 'underscore';
import { uniqBy } from 'lodash';
import Icon from '~/vue_shared/components/icon.vue';
import UserAvatarLink from '~/vue_shared/components/user_avatar/user_avatar_link.vue';
import TimeAgoTooltip from '~/vue_shared/components/time_ago_tooltip.vue';
Loading
Loading
@@ -27,7 +27,7 @@ export default {
uniqueAuthors() {
const authors = this.replies.map(reply => reply.author || {});
 
return _.uniq(authors, author => author.username);
return uniqBy(authors, author => author.username);
},
className() {
return this.collapsed ? 'collapsed' : 'expanded';
Loading
Loading
import _ from 'underscore';
import { flattenDeep } from 'lodash';
import * as constants from '../constants';
import { collapseSystemNotes } from './collapse_utils';
 
Loading
Loading
@@ -50,7 +50,7 @@ const isLastNote = (note, state) =>
!note.system && state.userData && note.author && note.author.id === state.userData.id;
 
export const getCurrentUserLastNote = state =>
_.flatten(reverseNotes(state.discussions).map(note => reverseNotes(note.notes))).find(el =>
flattenDeep(reverseNotes(state.discussions).map(note => reverseNotes(note.notes))).find(el =>
isLastNote(el, state),
);
 
Loading
Loading
Loading
Loading
@@ -579,7 +579,7 @@ $calendar-border-color: rgba(#000, 0.1);
$calendar-user-contrib-text: #959494;
 
/*
* Cycle Analytics
* Value Stream Analytics
*/
$cycle-analytics-box-padding: 30px;
$cycle-analytics-box-text-color: #8c8c8c;
Loading
Loading
Loading
Loading
@@ -35,7 +35,7 @@ module AnalyticsNavbarHelper
return unless project_nav_tab?(:cycle_analytics)
 
navbar_sub_item(
title: _('Cycle Analytics'),
title: _('Value Stream Analytics'),
path: 'cycle_analytics#show',
link: project_cycle_analytics_path(project),
link_to_options: { class: 'shortcuts-project-cycle-analytics' }
Loading
Loading
Loading
Loading
@@ -42,8 +42,8 @@
- unless should_display_analytics_pages_in_sidebar
- if can?(current_user, :read_cycle_analytics, @project)
= nav_link(path: 'cycle_analytics#show') do
= link_to project_cycle_analytics_path(@project), title: _('Cycle Analytics'), class: 'shortcuts-project-cycle-analytics' do
%span= _('Cycle Analytics')
= link_to project_cycle_analytics_path(@project), title: _('Value Stream Analytics'), class: 'shortcuts-project-cycle-analytics' do
%span= _('Value Stream Analytics')
 
= render_if_exists 'layouts/nav/project_insights_link'
 
Loading
Loading
Loading
Loading
@@ -4,12 +4,12 @@
.col-md-10.offset-md-1
.row.overview-details
.col-md-6.overview-text
%h4 Introducing Cycle Analytics
%h4 Introducing Value Stream Analytics
%p
Cycle Analytics gives an overview of how much time it takes to go from idea to production in your project.
To set up CA, you must first define a production environment by setting up your CI and then deploy to production.
Value Stream Analytics (VSA) gives an overview of how much time it takes to go from idea to production in your project.
To set up VSA, you must first define a production environment by setting up your CI and then deploy to production.
%p
%a.btn{ href: help_page_path('user/analytics/cycle_analytics.md'), target: '_blank' } Read more
%a.btn{ href: help_page_path('user/analytics/value_stream_analytics.md'), target: '_blank' } Read more
.col-md-6.overview-image
%span.overview-icon
= custom_icon ('icon_cycle_analytics_overview')
- page_title "Cycle Analytics"
- page_title "Value Stream Analytics"
 
#cycle-analytics{ "v-cloak" => "true", data: { request_path: project_cycle_analytics_path(@project) } }
- if @cycle_analytics_no_data
%banner{ "v-if" => "!isOverviewDialogDismissed",
"documentation-link": help_page_path('user/analytics/cycle_analytics.md'),
"documentation-link": help_page_path('user/analytics/value_stream_analytics.md'),
"v-on:dismiss-overview-dialog" => "dismissOverviewDialog()" }
= icon("spinner spin", "v-show" => "isLoading")
.wrapper{ "v-show" => "!isLoading && !hasError" }
Loading
Loading
---
title: Remove temporary index at services on project_id
merge_request: 24263
author:
type: removed
---
title: Rename cycle analytics interfaces to value stream analytics
merge_request: 23427
author:
type: changed
---
title: Minor text update to IDE commit to branch disabled tooltip
merge_request: 24521
author:
type: other
Loading
Loading
@@ -195,9 +195,8 @@ constraints(::Constraints::ProjectUrlConstrainer.new) do
end
end
 
resource :cycle_analytics, only: [:show]
namespace :cycle_analytics do
resource :cycle_analytics, only: :show, path: 'value_stream_analytics'
scope module: :cycle_analytics, as: 'cycle_analytics', path: 'value_stream_analytics' do
scope :events, controller: 'events' do
get :issue
get :plan
Loading
Loading
@@ -208,6 +207,7 @@ constraints(::Constraints::ProjectUrlConstrainer.new) do
get :production
end
end
get '/cycle_analytics', to: redirect('%{namespace_id}/%{project_id}/-/value_stream_analytics')
 
concerns :clusterable
 
Loading
Loading
Loading
Loading
@@ -109,7 +109,7 @@ class Gitlab::Seeder::CycleAnalytics
def create_issues
Array.new(@issue_count) do
issue_params = {
title: "Cycle Analytics: #{FFaker::Lorem.sentence(6)}",
title: "Value Stream Analytics: #{FFaker::Lorem.sentence(6)}",
description: FFaker::Lorem.sentence,
state: 'opened',
assignees: [@project.team.users.sample]
Loading
Loading
@@ -166,7 +166,7 @@ class Gitlab::Seeder::CycleAnalytics
Timecop.travel 12.hours.from_now
 
opts = {
title: 'Cycle Analytics merge_request',
title: 'Value Stream Analytics merge_request',
description: "Fixes #{issue.to_reference}",
source_branch: branch,
target_branch: 'master'
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment