Commit 46654acc authored by George Tsiolis's avatar George Tsiolis

Replace icons in environment item vue component

parent b4d1ce0a
......@@ -458,6 +458,14 @@ export default {
return 'chevron-right';
},
deployIconName() {
if (this.model.isDeployBoardVisible) {
return 'chevron-down';
}
return 'chevron-right';
},
},
methods: {
......@@ -491,23 +499,14 @@ export default {
>
{{ s__("Environments|Environment") }}
</div>
<span
<icon
v-if="model.hasDeployBoard"
:name="deployIconName"
class="deploy-board-icon"
@click="toggleDeployBoard">
<i
v-show="!model.isDeployBoardVisible"
class="fa fa-caret-right"
aria-hidden="true">
</i>
<i
v-show="model.isDeployBoardVisible"
class="fa fa-caret-down"
aria-hidden="true">
</i>
</span>
@click="toggleDeployBoard"
/>
<span
v-if="!model.isFolder"
class="environment-name table-mobile-content">
......
......@@ -113,9 +113,7 @@ describe('Environment', () => {
describe('deploy boards', () => {
it('should render arrow to open deploy boards', (done) => {
setTimeout(() => {
expect(
component.$el.querySelector('.deploy-board-icon i.fa-caret-right'),
).toBeDefined();
expect(component.$el.querySelector('.deploy-board-icon.ic-chevron-right')).not.toBeNull();
done();
}, 0);
});
......
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