Commit 7bbdb2a2 authored by Filipa Lacerda's avatar Filipa Lacerda

Merge branch 'ee-parallel-diff-view-ce' into 'master'

CE backport of ee-parallel-diff-view

See merge request gitlab-org/gitlab-ce!25734
parents bd28bcbf 40f767e9
<script> <script>
import { mapGetters } from 'vuex'; import { mapGetters } from 'vuex';
import draftCommentsMixin from 'ee_else_ce/diffs/mixins/draft_comments';
import parallelDiffTableRow from './parallel_diff_table_row.vue'; import parallelDiffTableRow from './parallel_diff_table_row.vue';
import parallelDiffCommentRow from './parallel_diff_comment_row.vue'; import parallelDiffCommentRow from './parallel_diff_comment_row.vue';
...@@ -7,7 +8,10 @@ export default { ...@@ -7,7 +8,10 @@ export default {
components: { components: {
parallelDiffTableRow, parallelDiffTableRow,
parallelDiffCommentRow, parallelDiffCommentRow,
ParallelDraftCommentRow: () =>
import('ee_component/batch_comments/components/parallel_draft_comment_row.vue'),
}, },
mixins: [draftCommentsMixin],
props: { props: {
diffFile: { diffFile: {
type: Object, type: Object,
...@@ -56,6 +60,12 @@ export default { ...@@ -56,6 +60,12 @@ export default {
:line-index="index" :line-index="index"
:help-page-path="helpPagePath" :help-page-path="helpPagePath"
/> />
<parallel-draft-comment-row
v-if="shouldRenderParallelDraftRow(diffFile.file_hash, line)"
:key="`drafts-${index}`"
:line="line"
:diff-file-content-sha="diffFile.file_hash"
/>
</template> </template>
</tbody> </tbody>
</table> </table>
......
export default { export default {
computed: { computed: {
shouldRenderDraftRow: () => () => false, shouldRenderDraftRow: () => () => false,
shouldRenderParallelDraftRow: () => () => false,
draftForLine: () => () => ({}), draftForLine: () => () => ({}),
}, },
}; };
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