diff --git a/lib/istio/addon/components/istio-catalog/template.hbs b/lib/istio/addon/components/istio-catalog/template.hbs index c3583eb87..750a15ba5 100644 --- a/lib/istio/addon/components/istio-catalog/template.hbs +++ b/lib/istio/addon/components/istio-catalog/template.hbs @@ -2,13 +2,6 @@

{{t "clusterIstioPage.header"}}

- {{#if (and enabled canEnable)}} -
- -
- {{/if}} {{#if canEnable}} @@ -141,7 +134,7 @@ detail=(t "clusterIstioPage.workload.detail" workload="Pilot") expandAll=al.expandAll expand=(action expandFn) - expandOnInit=true + expandOnInit=false }} {{form-reservation component="Pilot" @@ -203,7 +196,7 @@ detail=(t "clusterIstioPage.workload.detail" workload="Mixer") expandAll=al.expandAll expand=(action expandFn) - expandOnInit=true + expandOnInit=false }} {{form-reservation component="MixerTelemetry" @@ -265,7 +258,7 @@ detail=(t "clusterIstioPage.workload.detail" workload="Tracing") expandAll=al.expandAll expand=(action expandFn) - expandOnInit=true + expandOnInit=false }}
@@ -308,7 +301,7 @@ detail=(t "clusterIstioPage.workload.detail" workload="Ingress Gateway") expandAll=al.expandAll expand=(action expandFn) - expandOnInit=true + expandOnInit=false }}
@@ -424,25 +417,29 @@
{{/if}} {{/accordion-list-item}} - {{/accordion-list}} - {{#advanced-section}} -
- {{form-key-value - initialMap=customAnswers - changed=(action (mut customAnswers)) - allowEmptyValue=true - addInitialEmptyRow=true - editing=true - header=(t "newCatalog.answers.label") - addActionLabel="newCatalog.answers.addAction" - keyLabel="newContainer.environment.keyLabel" - keyPlaceholder="newContainer.environment.keyPlaceholder" - valueLabel="newContainer.environment.valueLabel" - valuePlaceholder="newContainer.environment.valuePlaceholder" + {{#accordion-list-item + title=(t "clusterIstioPage.customAnswers.title") + detail=(t "clusterIstioPage.customAnswers.detail") + expandAll=al.expandAll + expand=(action expandFn) + expandOnInit=false }} - {{/advanced-section}} - + {{form-key-value + initialMap=customAnswers + changed=(action (mut customAnswers)) + allowEmptyValue=true + addInitialEmptyRow=true + editing=true + header=(t "newCatalog.answers.label") + addActionLabel="newCatalog.answers.addAction" + keyLabel="newContainer.environment.keyLabel" + keyPlaceholder="newContainer.environment.keyPlaceholder" + valueLabel="newContainer.environment.valueLabel" + valuePlaceholder="newContainer.environment.valuePlaceholder" + }} + {{/accordion-list-item}} + {{/accordion-list}} {{#if (or pilotWarning mixerTelemetryWarning tracingWarning gatewayWarning (and mixerPolicyWarning config.mixerPolicyEnabled) mixerWarning istioWarning)}} {{#banner-message color="bg-warning"}} {{#if istioWarning}} @@ -466,14 +463,20 @@ {{top-errors errors=errors}} - {{save-cancel + {{#save-cancel saveDisabled=saveDisabled editing=enabled createLabel="clusterIstioPage.enableActionLabel" save=(action "save") saved=saved - cancel=cancel + cancelDisabled=true }} + {{#if (and enabled canEnable)}} + + {{/if}} + {{/save-cancel}} {{else}} {{#if enableClusterMonitoring}} {{#unless canReuse}} diff --git a/lib/istio/translations/en-us.yaml b/lib/istio/translations/en-us.yaml index c0406b669..85df79c1d 100644 --- a/lib/istio/translations/en-us.yaml +++ b/lib/istio/translations/en-us.yaml @@ -4,9 +4,12 @@ clusterIstioPage: disabled: "Istio is not enabled yet. Please click Enable button to enable it." notReady: Installing Istio into the system project of current cluster... confirmDisable: "Are you sure? Click again to disable Istio" - disable: Disable Istio + disable: Disable enableActionLabel: Enable version: Istio Version + customAnswers: + title: Custom Answers + detail: Config custom answers for Istio. links: kiali: label: Kiali UI diff --git a/lib/monitoring/addon/components/enable-monitoring/template.hbs b/lib/monitoring/addon/components/enable-monitoring/template.hbs index d7c5e3ded..24792fcc1 100644 --- a/lib/monitoring/addon/components/enable-monitoring/template.hbs +++ b/lib/monitoring/addon/components/enable-monitoring/template.hbs @@ -3,34 +3,6 @@

{{t (concat "monitoringPage." level ".title")}}

- {{#if (and enabled canDisableMonitor)}} -
- {{#if confirmDisable}} - - {{else}} - {{#if (and istioEnabled (eq level "cluster"))}} - {{#tooltip-element - type="tooltip-basic" - model=(t "monitoringPage.errors.disableIstioFirst") - tooltipTemplate="tooltip-static" - aria-describedby="tooltip-base" - inlineBlock=true - placement="top" - }} - - {{/tooltip-element}} - {{else}} - - {{/if}} - {{/if}} -
- {{/if}} {{#if settings.isRancher}} @@ -371,13 +343,40 @@ {{/if}}
- {{save-cancel + {{#save-cancel saveDisabled=saveDisabled cancelDisabled=true editing=enabled createLabel="monitoringPage.enableActionLabel" save="enable" }} + {{#if (and enabled canDisableMonitor)}} + {{#if confirmDisable}} + + {{else}} + {{#if (and istioEnabled (eq level "cluster"))}} + {{#tooltip-element + type="tooltip-basic" + model=(t "monitoringPage.errors.disableIstioFirst") + tooltipTemplate="tooltip-static" + aria-describedby="tooltip-base" + inlineBlock=true + placement="top" + }} + + {{/tooltip-element}} + {{else}} + + {{/if}} + {{/if}} + {{/if}} + {{/save-cancel}}
{{else if (and (eq level "project") scope.currentProject.isSystemProject)}} {{banner-message diff --git a/lib/monitoring/translations/en-us.yaml b/lib/monitoring/translations/en-us.yaml index 3c9d1f924..75eb5592a 100644 --- a/lib/monitoring/translations/en-us.yaml +++ b/lib/monitoring/translations/en-us.yaml @@ -94,8 +94,8 @@ monitoringPage: upgrade: Upgrade monitoring to the latest version {version} upgradeAvailable: "({version} Upgrade Available)" confirmDisable: "Are you sure? Click again to disable monitoring." - disable: Disable Monitoring - enableActionLabel: Enable Monitoring + disable: Disable + enableActionLabel: Enable systemProject: "If you want to collect custom metrics for pods in System Project, please enable cluster level monitoring directly." noPermission: "You do not have permission to configure {level} level monitoring." toUpdate: diff --git a/lib/shared/addon/components/save-cancel/template.hbs b/lib/shared/addon/components/save-cancel/template.hbs index df4652fa3..65eb71900 100644 --- a/lib/shared/addon/components/save-cancel/template.hbs +++ b/lib/shared/addon/components/save-cancel/template.hbs @@ -1,4 +1,3 @@ -{{yield}} {{#if saving}} {{/if}} +{{yield}} {{#unless cancelDisabled}}