Projects/Namespaces, istio enabled icon

Signed-off-by: Francesco Torchia <francesco.torchia@suse.com>
This commit is contained in:
Francesco Torchia 2023-02-21 13:42:05 +01:00
parent f76a53c02c
commit 2f49ba0694
No known key found for this signature in database
GPG Key ID: E6D011B7415D4393
4 changed files with 30 additions and 0 deletions

View File

@ -4143,6 +4143,7 @@ projectNamespaces:
label: Projects/Namespaces
noNamespaces: There are no namespaces defined.
noProjectNoNamespaces: All namespaces are in a project
isIstioInjectionEnabled: Istio automatic sidecar injection is enabled for this namespace
prometheusRule:
alertingRules:

View File

@ -415,6 +415,11 @@ export default {
<span v-else>
{{ row.name }}
</span>
<i
v-if="row.isIstioInjectionEnabled"
v-tooltip="t('projectNamespaces.isIstioInjectionEnabled')"
class="icon icon-istio ml-5"
/>
<i
v-if="row.hasSystemLabels"
v-tooltip="getPsaTooltip(row)"
@ -487,6 +492,10 @@ export default {
.namespace-name {
display: flex;
align-items: center;
.icon-istio {
color: var(--primary);
}
}
}
}

View File

@ -429,6 +429,15 @@ export default {
class="masthead-state"
:value="value"
/>
<span
v-if="!isCreate && value.isIstioInjectionEnabled"
class="masthead-istio"
>
<i
v-tooltip="t('projectNamespaces.isIstioInjectionEnabled')"
class="icon icon-sm icon-istio"
/>
</span>
</h1>
</div>
<div
@ -568,6 +577,13 @@ export default {
top: -2px;
}
.masthead-istio {
.icon {
vertical-align: middle;
color: var(--primary);
}
}
.left-right-split {
display: grid;
align-items: center;

View File

@ -260,4 +260,8 @@ export default class Namespace extends SteveModel {
get hideDetailLocation() {
return !!this.$rootGetters['currentProduct'].hideNamespaceLocation;
}
get isIstioInjectionEnabled() {
return this.metadata.labels[ISTIO_LABELS.AUTO_INJECTION] === 'enabled';
}
}