From b41120bb2d9d0e5bda76275e8140bd813009805d Mon Sep 17 00:00:00 2001 From: Vinayak Goyal Date: Fri, 18 Oct 2024 17:41:58 +0000 Subject: [PATCH] Update the feature-state shortcode to display the default value. Signed-off-by: Vinayak Goyal --- data/i18n/en/en.toml | 3 +++ layouts/shortcodes/feature-state.html | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/data/i18n/en/en.toml b/data/i18n/en/en.toml index 0029e53b5e607..2809132e8f2d4 100644 --- a/data/i18n/en/en.toml +++ b/data/i18n/en/en.toml @@ -161,6 +161,9 @@ other = "Were you looking for:" [examples_heading] other = "Examples" +[feature_gate_enabled] +other = "(enabled by default: {{ .enabled }})" + [feature_gate_stage_alpha] other = "Alpha" diff --git a/layouts/shortcodes/feature-state.html b/layouts/shortcodes/feature-state.html index 739fc3a14b4c2..239269dcafab6 100644 --- a/layouts/shortcodes/feature-state.html +++ b/layouts/shortcodes/feature-state.html @@ -33,7 +33,7 @@
{{ T "feature_state" }} - {{ T "feature_state_kubernetes_label" }} v{{ .fromVersion }} [{{ .stage }}] + {{ T "feature_state_kubernetes_label" }} v{{ .fromVersion }} [{{ .stage }}] {{ T "feature_gate_enabled" (dict "enabled" .defaultValue) }}
{{- $featureGateFound = true -}}