[v10.0.x] Chore: Deprecate topnav feature flag (#72347)
Chore: Remove topnav feature flag (#72337)
* Remove topnav feature flag
* Allow deprecated flags to be enabled by default
* change topnav feature flag to deprecated instead
* fix lint
(cherry picked from commit 488eac0e49)
This commit is contained in:
@@ -27,7 +27,6 @@ Some stable features are enabled by default. You can disable a stable feature by
|
||||
| `cloudWatchDynamicLabels` | Use dynamic labels instead of alias patterns in CloudWatch datasource | Yes |
|
||||
| `dataConnectionsConsole` | Enables a new top-level page called Connections. This page is an experiment that provides a better experience when you install and configure data sources and other plugins. | Yes |
|
||||
| `internationalization` | Enables internationalization | Yes |
|
||||
| `topnav` | Enables new top navigation and page layouts | Yes |
|
||||
| `cloudWatchCrossAccountQuerying` | Enables cross-account querying in CloudWatch datasources | Yes |
|
||||
| `newPanelChromeUI` | Show updated look and feel of grafana-ui PanelChrome: panel header, icons, and menu | Yes |
|
||||
| `accessTokenExpirationCheck` | Enable OAuth access_token expiration check and token refresh using the refresh_token | |
|
||||
|
||||
@@ -200,9 +200,11 @@ var (
|
||||
Owner: grafanaUserEssentialsSquad,
|
||||
},
|
||||
{
|
||||
// Some plugins rely on topnav feature flag being enabled, so we cannot remove this until we
|
||||
// can afford the breaking change, or we've detemined no one else is relying on it
|
||||
Name: "topnav",
|
||||
Description: "Enables new top navigation and page layouts",
|
||||
State: FeatureStateStable,
|
||||
Description: "Enables topnav support in external plugins. The new Grafana navigation cannot be disabled.",
|
||||
State: FeatureStateDeprecated,
|
||||
Expression: "true", // enabled by default
|
||||
Owner: grafanaUserEssentialsSquad,
|
||||
},
|
||||
|
||||
@@ -28,7 +28,7 @@ disableSecretsCompatibility,alpha,@grafana/hosted-grafana-team,false,false,true,
|
||||
logRequestsInstrumentedAsUnknown,alpha,@grafana/hosted-grafana-team,false,false,false,false
|
||||
dataConnectionsConsole,stable,@grafana/plugins-platform-backend,false,false,false,false
|
||||
internationalization,stable,@grafana/user-essentials,false,false,false,false
|
||||
topnav,stable,@grafana/user-essentials,false,false,false,false
|
||||
topnav,deprecated,@grafana/user-essentials,false,false,false,false
|
||||
grpcServer,beta,@grafana/grafana-app-platform-squad,false,false,false,false
|
||||
entityStore,alpha,@grafana/grafana-app-platform-squad,true,false,false,false
|
||||
cloudWatchCrossAccountQuerying,stable,@grafana/aws-plugins,false,false,false,false
|
||||
|
||||
|
@@ -124,7 +124,7 @@ const (
|
||||
FlagInternationalization = "internationalization"
|
||||
|
||||
// FlagTopnav
|
||||
// Enables new top navigation and page layouts
|
||||
// Enables topnav support in external plugins. The new Grafana navigation cannot be disabled.
|
||||
FlagTopnav = "topnav"
|
||||
|
||||
// FlagGrpcServer
|
||||
|
||||
@@ -30,8 +30,8 @@ func TestFeatureToggleFiles(t *testing.T) {
|
||||
|
||||
t.Run("check registry constraints", func(t *testing.T) {
|
||||
for _, flag := range standardFeatureFlags {
|
||||
if flag.Expression == "true" && flag.State != FeatureStateStable {
|
||||
t.Errorf("only stable features can be enabled by default. See: %s", flag.Name)
|
||||
if flag.Expression == "true" && !(flag.State == FeatureStateStable || flag.State == FeatureStateDeprecated) {
|
||||
t.Errorf("only FeatureStateStable or FeatureStateDeprecated features can be enabled by default. See: %s", flag.Name)
|
||||
}
|
||||
if flag.RequiresDevMode && flag.State != FeatureStateAlpha {
|
||||
t.Errorf("only alpha features can require dev mode. See: %s", flag.Name)
|
||||
|
||||
@@ -4,7 +4,7 @@ import { Store } from 'redux';
|
||||
import { TestProvider } from 'test/helpers/TestProvider';
|
||||
|
||||
import { LayoutModes } from '@grafana/data';
|
||||
import { setAngularLoader, config } from '@grafana/runtime';
|
||||
import { setAngularLoader } from '@grafana/runtime';
|
||||
import { getRouteComponentProps } from 'app/core/navigation/__mocks__/routeProps';
|
||||
import { configureStore } from 'app/store/configureStore';
|
||||
|
||||
@@ -110,7 +110,6 @@ describe('<EditDataSourcePage>', () => {
|
||||
});
|
||||
|
||||
it('should show updated action buttons when topnav is on', async () => {
|
||||
config.featureToggles.topnav = true;
|
||||
setup(uid, store);
|
||||
|
||||
await waitFor(() => {
|
||||
|
||||
Reference in New Issue
Block a user