You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@superset.apache.org by mi...@apache.org on 2023/06/09 11:35:22 UTC

[superset] branch master updated: chore: Removes getUiOverrideRegistry (#24330)

This is an automated email from the ASF dual-hosted git repository.

michaelsmolina pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/superset.git


The following commit(s) were added to refs/heads/master by this push:
     new bdb8bbef32 chore: Removes getUiOverrideRegistry (#24330)
bdb8bbef32 is described below

commit bdb8bbef32cf9f782b6a7dc7a93c1ad737712536
Author: Michael S. Molina <70...@users.noreply.github.com>
AuthorDate: Fri Jun 9 08:35:11 2023 -0300

    chore: Removes getUiOverrideRegistry (#24330)
---
 UPDATING.md                                                         | 1 +
 .../superset-ui-core/src/ui-overrides/ExtensionsRegistry.ts         | 4 ----
 superset-frontend/src/dashboard/components/Header/index.jsx         | 6 +++---
 3 files changed, 4 insertions(+), 7 deletions(-)

diff --git a/UPDATING.md b/UPDATING.md
index 70f7d5154d..e2f45f6937 100644
--- a/UPDATING.md
+++ b/UPDATING.md
@@ -33,6 +33,7 @@ assists people when migrating to a new version.
 
 ### Breaking Changes
 
+- [24330](https://github.com/apache/superset/pull/24330) Removes `getUiOverrideRegistry` from `ExtensionsRegistry`.
 - [23933](https://github.com/apache/superset/pull/23933) Removes the deprecated Multiple Line Charts.
 - [23741](https://github.com/apache/superset/pull/23741) Migrates the TreeMap chart and removes the legacy Treemap code.
 - [23712](https://github.com/apache/superset/pull/23712) Migrates the Pivot Table v1 chart to v2 and removes v1 code.
diff --git a/superset-frontend/packages/superset-ui-core/src/ui-overrides/ExtensionsRegistry.ts b/superset-frontend/packages/superset-ui-core/src/ui-overrides/ExtensionsRegistry.ts
index e361470662..a2ff52c2e3 100644
--- a/superset-frontend/packages/superset-ui-core/src/ui-overrides/ExtensionsRegistry.ts
+++ b/superset-frontend/packages/superset-ui-core/src/ui-overrides/ExtensionsRegistry.ts
@@ -29,7 +29,3 @@ class ExtensionsRegistry extends TypedRegistry<Extensions> {
 }
 
 export const getExtensionsRegistry = makeSingleton(ExtensionsRegistry, {});
-
-// Exporting this under the old name for backwards compatibility.
-// After downstream folks have migrated to `getExtensionsRegistry`, we should remove this.
-export const getUiOverrideRegistry = getExtensionsRegistry;
diff --git a/superset-frontend/src/dashboard/components/Header/index.jsx b/superset-frontend/src/dashboard/components/Header/index.jsx
index 72d583ebf2..e9cf63b5a4 100644
--- a/superset-frontend/src/dashboard/components/Header/index.jsx
+++ b/superset-frontend/src/dashboard/components/Header/index.jsx
@@ -26,7 +26,7 @@ import {
   FeatureFlag,
   t,
   getSharedLabelColor,
-  getUiOverrideRegistry,
+  getExtensionsRegistry,
 } from '@superset-ui/core';
 import { Global } from '@emotion/react';
 import { isFeatureEnabled } from 'src/featureFlags';
@@ -58,7 +58,7 @@ import { PageHeaderWithActions } from 'src/components/PageHeaderWithActions';
 import { DashboardEmbedModal } from '../DashboardEmbedControls';
 import OverwriteConfirm from '../OverwriteConfirm';
 
-const uiOverrideRegistry = getUiOverrideRegistry();
+const extensionsRegistry = getExtensionsRegistry();
 
 const propTypes = {
   addSuccessToast: PropTypes.func.isRequired,
@@ -495,7 +495,7 @@ class Header extends React.PureComponent {
       dashboardTitleChanged(updates.title);
     };
 
-    const NavExtension = uiOverrideRegistry.get('dashboard.nav.right');
+    const NavExtension = extensionsRegistry.get('dashboard.nav.right');
 
     return (
       <div