Navigation: Update synthetics placement in IA (#79302)

* update synthetics placement in IA

* lowercase s in synthetics
pull/78901/head^2
Ashley Harrison 1 year ago committed by GitHub
parent 3647ba7360
commit 7c2b3ee1af
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 32
      pkg/services/navtree/models.go
  2. 23
      pkg/services/navtree/navtreeimpl/applinks.go
  3. 9
      public/app/core/utils/navBarItem-translations.ts
  4. 4
      public/app/routes/routes.tsx
  5. 7
      public/locales/de-DE/grafana.json
  6. 7
      public/locales/en-US/grafana.json
  7. 7
      public/locales/es-ES/grafana.json
  8. 7
      public/locales/fr-FR/grafana.json
  9. 7
      public/locales/pseudo-LOCALE/grafana.json
  10. 7
      public/locales/zh-Hans/grafana.json

@ -17,6 +17,7 @@ const (
WeightExplore
WeightAlerting
WeightAlertsAndIncidents
WeightTestingAndSynthetics
WeightMonitoring
WeightInfrastructure
WeightApplication
@ -30,21 +31,22 @@ const (
)
const (
NavIDRoot = "root"
NavIDDashboards = "dashboards/browse"
NavIDExplore = "explore"
NavIDCfg = "cfg" // NavIDCfg is the id for org configuration navigation node
NavIDAlertsAndIncidents = "alerts-and-incidents"
NavIDAlerting = "alerting"
NavIDAlertingLegacy = "alerting-legacy"
NavIDMonitoring = "monitoring"
NavIDInfrastructure = "infrastructure"
NavIDFrontend = "frontend"
NavIDReporting = "reports"
NavIDApps = "apps"
NavIDCfgGeneral = "cfg/general"
NavIDCfgPlugins = "cfg/plugins"
NavIDCfgAccess = "cfg/access"
NavIDRoot = "root"
NavIDDashboards = "dashboards/browse"
NavIDExplore = "explore"
NavIDCfg = "cfg" // NavIDCfg is the id for org configuration navigation node
NavIDAlertsAndIncidents = "alerts-and-incidents"
NavIDTestingAndSynthetics = "testing-and-synthetics"
NavIDAlerting = "alerting"
NavIDAlertingLegacy = "alerting-legacy"
NavIDMonitoring = "monitoring"
NavIDInfrastructure = "infrastructure"
NavIDFrontend = "frontend"
NavIDReporting = "reports"
NavIDApps = "apps"
NavIDCfgGeneral = "cfg/general"
NavIDCfgPlugins = "cfg/plugins"
NavIDCfgAccess = "cfg/access"
)
type NavLink struct {

@ -249,6 +249,16 @@ func (s *ServiceImpl) addPluginToSection(c *contextmodel.ReqContext, treeRoot *n
Children: alertsAndIncidentsChildren,
Url: s.cfg.AppSubURL + "/alerts-and-incidents",
})
case navtree.NavIDTestingAndSynthetics:
treeRoot.AddSection(&navtree.NavLink{
Text: "Testing & synthetics",
Id: navtree.NavIDTestingAndSynthetics,
SubTitle: "Optimize performance with k6 and Synthetic Monitoring insights",
Icon: "k6",
SortWeight: navtree.WeightTestingAndSynthetics,
Children: []*navtree.NavLink{appLink},
Url: s.cfg.AppSubURL + "/testing-and-synthetics",
})
default:
s.log.Error("Plugin app nav id not found", "pluginId", plugin.ID, "navId", sectionID)
}
@ -276,6 +286,7 @@ func (s *ServiceImpl) readNavigationSettings() {
appO11yCfg := NavigationAppConfig{SectionID: navtree.NavIDMonitoring, SortWeight: 2, Text: "Application"}
profilesCfg := NavigationAppConfig{SectionID: navtree.NavIDMonitoring, SortWeight: 3, Text: "Profiles"}
frontendCfg := NavigationAppConfig{SectionID: navtree.NavIDMonitoring, SortWeight: 4, Text: "Frontend"}
k6Cfg := NavigationAppConfig{SectionID: navtree.NavIDRoot, SortWeight: navtree.WeightAlertsAndIncidents + 1, Text: "Performance testing", Icon: "k6"}
syntheticsCfg := NavigationAppConfig{SectionID: navtree.NavIDMonitoring, SortWeight: 5, Text: "Synthetics"}
if s.features.IsEnabledGlobally(featuremgmt.FlagDockedMegaMenu) {
@ -288,10 +299,14 @@ func (s *ServiceImpl) readNavigationSettings() {
profilesCfg.SectionID = navtree.NavIDExplore
profilesCfg.SortWeight = 1
frontendCfg.SectionID = navtree.NavIDFrontend
frontendCfg.SortWeight = 1
frontendCfg.SectionID = navtree.NavIDRoot
frontendCfg.SortWeight = navtree.WeightFrontend
k6Cfg.SectionID = navtree.NavIDTestingAndSynthetics
k6Cfg.SortWeight = 1
k6Cfg.Text = "Performance"
syntheticsCfg.SectionID = navtree.NavIDFrontend
syntheticsCfg.SectionID = navtree.NavIDTestingAndSynthetics
syntheticsCfg.SortWeight = 2
}
@ -307,7 +322,7 @@ func (s *ServiceImpl) readNavigationSettings() {
"grafana-cloud-link-app": {SectionID: navtree.NavIDCfg},
"grafana-costmanagementui-app": {SectionID: navtree.NavIDCfg, Text: "Cost management"},
"grafana-easystart-app": {SectionID: navtree.NavIDRoot, SortWeight: navtree.WeightApps + 1, Text: "Connections", Icon: "adjust-circle"},
"k6-app": {SectionID: navtree.NavIDRoot, SortWeight: navtree.WeightAlertsAndIncidents + 1, Text: "Performance testing", Icon: "k6"},
"k6-app": k6Cfg,
}
if s.features.IsEnabledGlobally(featuremgmt.FlagCostManagementUi) {

@ -1,3 +1,4 @@
import { config } from '@grafana/runtime';
import { t } from 'app/core/internationalization';
// Maps the ID of the nav item to a translated phrase to later pass to <Trans />
@ -126,6 +127,8 @@ export function getNavTitle(navId: string | undefined) {
return t('nav.apps.title', 'Apps');
case 'alerts-and-incidents':
return t('nav.alerts-and-incidents.title', 'Alerts & IRM');
case 'testing-and-synthetics':
return t('nav.testing-and-synthetics.title', 'Testing & synthetics');
case 'plugin-page-grafana-incident-app':
return t('nav.incidents.title', 'Incidents');
case 'plugin-page-grafana-ml-app':
@ -133,7 +136,9 @@ export function getNavTitle(navId: string | undefined) {
case 'plugin-page-grafana-slo-app':
return t('nav.slo.title', 'SLO');
case 'plugin-page-k6-app':
return t('nav.performance-testing.title', 'Performance testing');
return config.featureToggles.dockedMegaMenu
? t('nav.k6.title', 'Performance')
: t('nav.performance-testing.title', 'Performance testing');
case 'monitoring':
return t('nav.observability.title', 'Observability');
case 'plugin-page-grafana-k8s-app':
@ -256,6 +261,8 @@ export function getNavSubTitle(navId: string | undefined) {
return t('nav.frontend.subtitle', 'Gain real user monitoring insights');
case 'alerts-and-incidents':
return t('nav.alerts-and-incidents.subtitle', 'Alerting and incident management apps');
case 'testing-and-synthetics':
return t('nav.testing-and-synthetics.subtitle', 'Optimize performance with k6 and Synthetic Monitoring insights');
case 'connections-add-new-connection':
return t('nav.connections.subtitle', 'Browse and create new connections');
case 'connections-datasources':

@ -170,6 +170,10 @@ export function getAppRoutes(): RouteDescriptor[] {
path: '/alerts-and-incidents',
component: () => <NavLandingPage navId="alerts-and-incidents" />,
},
{
path: '/testing-and-synthetics',
component: () => <NavLandingPage navId="testing-and-synthetics" />,
},
{
path: '/monitoring',
component: () => <NavLandingPage navId="monitoring" />,

@ -810,6 +810,9 @@
"integrations": {
"title": "Integrationen"
},
"k6": {
"title": ""
},
"kubernetes": {
"title": "Kubernetes"
},
@ -929,6 +932,10 @@
"subtitle": "Gruppen von Benutzern mit gemeinsamen Dashboards und Benachrichtigungen",
"title": "Teams"
},
"testing-and-synthetics": {
"subtitle": "",
"title": ""
},
"upgrading": {
"title": "Statistiken und Lizenz"
},

@ -810,6 +810,9 @@
"integrations": {
"title": "Integrations"
},
"k6": {
"title": "Performance"
},
"kubernetes": {
"title": "Kubernetes"
},
@ -929,6 +932,10 @@
"subtitle": "Groups of users that have common dashboard and permission needs",
"title": "Teams"
},
"testing-and-synthetics": {
"subtitle": "Optimize performance with k6 and Synthetic Monitoring insights",
"title": "Testing & synthetics"
},
"upgrading": {
"title": "Stats and license"
},

@ -816,6 +816,9 @@
"integrations": {
"title": "Integraciones"
},
"k6": {
"title": ""
},
"kubernetes": {
"title": "Kubernetes"
},
@ -935,6 +938,10 @@
"subtitle": "Grupos de usuarios que tienen necesidades comunes de permisos y de panel de control",
"title": "Equipos"
},
"testing-and-synthetics": {
"subtitle": "",
"title": ""
},
"upgrading": {
"title": "Estadísticas y licencia"
},

@ -816,6 +816,9 @@
"integrations": {
"title": "Intégrations"
},
"k6": {
"title": ""
},
"kubernetes": {
"title": "Kubernetes"
},
@ -935,6 +938,10 @@
"subtitle": "Groupes d'utilisateurs ayant des besoins communs en matière de tableau de bord et d'autorisations",
"title": "Équipes"
},
"testing-and-synthetics": {
"subtitle": "",
"title": ""
},
"upgrading": {
"title": "Statistiques et licence"
},

@ -810,6 +810,9 @@
"integrations": {
"title": "Ĩʼnŧęģřäŧįőʼnş"
},
"k6": {
"title": "Pęřƒőřmäʼnčę"
},
"kubernetes": {
"title": "Ķūþęřʼnęŧęş"
},
@ -929,6 +932,10 @@
"subtitle": "Ğřőūpş őƒ ūşęřş ŧĥäŧ ĥävę čőmmőʼn đäşĥþőäřđ äʼnđ pęřmįşşįőʼn ʼnęęđş",
"title": "Ŧęämş"
},
"testing-and-synthetics": {
"subtitle": "Øpŧįmįžę pęřƒőřmäʼnčę ŵįŧĥ ĸ6 äʼnđ Ŝyʼnŧĥęŧįč Mőʼnįŧőřįʼnģ įʼnşįģĥŧş",
"title": "Ŧęşŧįʼnģ & şyʼnŧĥęŧįčş"
},
"upgrading": {
"title": "Ŝŧäŧş äʼnđ ľįčęʼnşę"
},

@ -804,6 +804,9 @@
"integrations": {
"title": "集成"
},
"k6": {
"title": ""
},
"kubernetes": {
"title": "Kubernetes"
},
@ -923,6 +926,10 @@
"subtitle": "具有共同仪表板和权限需求的用户组",
"title": "团队"
},
"testing-and-synthetics": {
"subtitle": "",
"title": ""
},
"upgrading": {
"title": "统计信息和许可证"
},

Loading…
Cancel
Save