Commit 4c5364ac authored by Clement Ho's avatar Clement Ho

Merge branch 'ce-to-ee-2018-10-31' into 'master'

CE upstream - 2018-10-31 15:53 UTC

See merge request gitlab-org/gitlab-ee!8165
parents d55c9568 fe652b32
import Vue from 'vue'; import Vue from 'vue';
import { import {
GlPagination,
GlProgressBar, GlProgressBar,
GlLoadingIcon, GlLoadingIcon,
GlTooltipDirective, GlTooltipDirective,
} from '@gitlab-org/gitlab-ui'; } from '@gitlab-org/gitlab-ui';
Vue.component('gl-pagination', GlPagination);
Vue.component('gl-progress-bar', GlProgressBar); Vue.component('gl-progress-bar', GlProgressBar);
Vue.component('gl-loading-icon', GlLoadingIcon); Vue.component('gl-loading-icon', GlLoadingIcon);
......
...@@ -43,7 +43,7 @@ export default { ...@@ -43,7 +43,7 @@ export default {
'currentProjectId', 'currentProjectId',
'errorMessage', 'errorMessage',
]), ]),
...mapGetters(['activeFile', 'hasChanges', 'someUncommitedChanges', 'isCommitModeActive']), ...mapGetters(['activeFile', 'hasChanges', 'someUncommittedChanges', 'isCommitModeActive']),
}, },
mounted() { mounted() {
window.onbeforeunload = e => this.onBeforeUnload(e); window.onbeforeunload = e => this.onBeforeUnload(e);
...@@ -63,7 +63,7 @@ export default { ...@@ -63,7 +63,7 @@ export default {
onBeforeUnload(e = {}) { onBeforeUnload(e = {}) {
const returnValue = __('Are you sure you want to lose unsaved changes?'); const returnValue = __('Are you sure you want to lose unsaved changes?');
if (!this.someUncommitedChanges) return undefined; if (!this.someUncommittedChanges) return undefined;
Object.assign(e, { Object.assign(e, {
returnValue, returnValue,
......
...@@ -25,11 +25,11 @@ export default { ...@@ -25,11 +25,11 @@ export default {
}, },
computed: { computed: {
...mapState(['loading', 'currentActivityView', 'changedFiles', 'stagedFiles', 'lastCommitMsg']), ...mapState(['loading', 'currentActivityView', 'changedFiles', 'stagedFiles', 'lastCommitMsg']),
...mapGetters(['currentProject', 'someUncommitedChanges']), ...mapGetters(['currentProject', 'someUncommittedChanges']),
showSuccessMessage() { showSuccessMessage() {
return ( return (
this.currentActivityView === activityBarViews.edit && this.currentActivityView === activityBarViews.edit &&
(this.lastCommitMsg && !this.someUncommitedChanges) (this.lastCommitMsg && !this.someUncommittedChanges)
); );
}, },
}, },
......
...@@ -27,10 +27,10 @@ export default { ...@@ -27,10 +27,10 @@ export default {
'unusedSeal', 'unusedSeal',
]), ]),
...mapState('commit', ['commitMessage', 'submitCommitLoading']), ...mapState('commit', ['commitMessage', 'submitCommitLoading']),
...mapGetters(['lastOpenedFile', 'hasChanges', 'someUncommitedChanges', 'activeFile']), ...mapGetters(['lastOpenedFile', 'hasChanges', 'someUncommittedChanges', 'activeFile']),
...mapGetters('commit', ['discardDraftButtonDisabled']), ...mapGetters('commit', ['discardDraftButtonDisabled']),
showStageUnstageArea() { showStageUnstageArea() {
return !!(this.someUncommitedChanges || this.lastCommitMsg || !this.unusedSeal); return !!(this.someUncommittedChanges || this.lastCommitMsg || !this.unusedSeal);
}, },
activeFileKey() { activeFileKey() {
return this.activeFile ? this.activeFile.key : null; return this.activeFile ? this.activeFile.key : null;
......
...@@ -63,7 +63,7 @@ export const isEditModeActive = state => state.currentActivityView === activityB ...@@ -63,7 +63,7 @@ export const isEditModeActive = state => state.currentActivityView === activityB
export const isCommitModeActive = state => state.currentActivityView === activityBarViews.commit; export const isCommitModeActive = state => state.currentActivityView === activityBarViews.commit;
export const isReviewModeActive = state => state.currentActivityView === activityBarViews.review; export const isReviewModeActive = state => state.currentActivityView === activityBarViews.review;
export const someUncommitedChanges = state => export const someUncommittedChanges = state =>
!!(state.changedFiles.length || state.stagedFiles.length); !!(state.changedFiles.length || state.stagedFiles.length);
export const getChangesInFolder = state => path => { export const getChangesInFolder = state => path => {
......
<script> <script>
import { GlPagination } from '@gitlab-org/gitlab-ui';
import { s__ } from '../../locale'; import { s__ } from '../../locale';
export default { export default {
components: {
GlPagination,
},
props: { props: {
change: { change: {
type: Function, type: Function,
......
---
title: Remove gitlab-ui's pagination from global
merge_request:
author:
type: performance
---
title: Fix IDE typos in props
merge_request: 22685
author: George Tsiolis
type: other
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