summaryrefslogtreecommitdiff
path: root/app/assets/javascripts/environments/components/environment.js.es6
diff options
context:
space:
mode:
Diffstat (limited to 'app/assets/javascripts/environments/components/environment.js.es6')
-rw-r--r--app/assets/javascripts/environments/components/environment.js.es613
1 files changed, 8 insertions, 5 deletions
diff --git a/app/assets/javascripts/environments/components/environment.js.es6 b/app/assets/javascripts/environments/components/environment.js.es6
index 88c3d257cea..facd653fd72 100644
--- a/app/assets/javascripts/environments/components/environment.js.es6
+++ b/app/assets/javascripts/environments/components/environment.js.es6
@@ -18,7 +18,7 @@
* The environments array is a recursive tree structure and we need to filter
* both root level environments and children environments.
*
- * In order to acomplish that, both `filterState` and `filterEnvironmnetsByState`
+ * In order to acomplish that, both `filterState` and `filterEnvironmentsByState`
* functions work together.
* The first one works as the filter that verifies if the given environment matches
* the given state.
@@ -34,9 +34,9 @@
* @param {Array} array
* @return {Array}
*/
- const filterEnvironmnetsByState = (fn, arr) => arr.map((item) => {
+ const filterEnvironmentsByState = (fn, arr) => arr.map((item) => {
if (item.children) {
- const filteredChildren = filterEnvironmnetsByState(fn, item.children).filter(Boolean);
+ const filteredChildren = filterEnvironmentsByState(fn, item.children).filter(Boolean);
if (filteredChildren.length) {
item.children = filteredChildren;
return item;
@@ -76,12 +76,13 @@
helpPagePath: environmentsData.helpPagePath,
commitIconSvg: environmentsData.commitIconSvg,
playIconSvg: environmentsData.playIconSvg,
+ terminalIconSvg: environmentsData.terminalIconSvg,
};
},
computed: {
filteredEnvironments() {
- return filterEnvironmnetsByState(filterState(this.visibility), this.state.environments);
+ return filterEnvironmentsByState(filterState(this.visibility), this.state.environments);
},
scope() {
@@ -102,7 +103,7 @@
},
/**
- * Fetches all the environmnets and stores them.
+ * Fetches all the environments and stores them.
* Toggles loading property.
*/
created() {
@@ -230,6 +231,7 @@
:can-create-deployment="canCreateDeploymentParsed"
:can-read-environment="canReadEnvironmentParsed"
:play-icon-svg="playIconSvg"
+ :terminal-icon-svg="terminalIconSvg"
:commit-icon-svg="commitIconSvg"></tr>
<tr v-if="model.isOpen && model.children && model.children.length > 0"
@@ -240,6 +242,7 @@
:can-create-deployment="canCreateDeploymentParsed"
:can-read-environment="canReadEnvironmentParsed"
:play-icon-svg="playIconSvg"
+ :terminal-icon-svg="terminalIconSvg"
:commit-icon-svg="commitIconSvg">
</tr>