Commit 38db5f07 authored by Phil Hughes's avatar Phil Hughes

added computed prop for file list length

parent 74838724
...@@ -63,6 +63,9 @@ export default { ...@@ -63,6 +63,9 @@ export default {
title: this.title, title: this.title,
}); });
}, },
filesLength() {
return this.fileList.length;
},
}, },
methods: { methods: {
...mapActions(['stageAllChanges', 'unstageAllChanges']), ...mapActions(['stageAllChanges', 'unstageAllChanges']),
...@@ -92,9 +95,9 @@ export default { ...@@ -92,9 +95,9 @@ export default {
<div class="d-flex ml-auto"> <div class="d-flex ml-auto">
<button <button
v-tooltip v-tooltip
v-show="fileList.length" v-show="filesLength"
:class="{ :class="{
'd-flex': fileList.length 'd-flex': filesLength
}" }"
:title="actionBtnText" :title="actionBtnText"
type="button" type="button"
...@@ -112,17 +115,17 @@ export default { ...@@ -112,17 +115,17 @@ export default {
</button> </button>
<span <span
:class="{ :class="{
'rounded-right': !fileList.length 'rounded-right': !filesLength
}" }"
class="ide-commit-file-count order-0 rounded-left text-center" class="ide-commit-file-count order-0 rounded-left text-center"
> >
{{ fileList.length }} {{ filesLength }}
</span> </span>
</div> </div>
</div> </div>
</header> </header>
<ul <ul
v-if="fileList.length" v-if="filesLength"
class="multi-file-commit-list list-unstyled append-bottom-0" class="multi-file-commit-list list-unstyled append-bottom-0"
> >
<li <li
......
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