rusackas commented on code in PR #37625:
URL: https://github.com/apache/superset/pull/37625#discussion_r2766000182
##########
superset-frontend/src/dashboard/components/Header/types.ts:
##########
@@ -17,71 +17,62 @@
* under the License.
*/
-import { Layout } from 'src/dashboard/types';
+import { type Dispatch, type SetStateAction } from 'react';
+import { DataMaskStateWithId, JsonObject } from '@superset-ui/core';
+import {
+ DashboardInfo as DashboardInfoType,
+ Layout,
+} from 'src/dashboard/types';
+import type { ReportObject } from 'src/features/reports/types';
import { ChartState } from 'src/explore/types';
-import { AlertObject } from 'src/features/alerts/types';
-
-interface DashboardInfo {
- id: number;
- userId: string | undefined;
- dash_edit_perm: boolean;
- dash_save_perm: boolean;
- dash_export_perm?: boolean;
- metadata?: Record<string, any>;
- common?: { conf: Record<string, any> };
- theme?: {
- id: number;
- name: string;
- } | null;
-}
export interface HeaderDropdownProps {
addSuccessToast: (msg: string) => void;
- addDangerToast: () => void;
- customCss: string;
+ addDangerToast: (msg: string) => void;
Review Comment:
This is a type correction, not a breaking change. The old signature () =>
void was incorrect - addDangerToast has always accepted a message parameter, as
seen in actual usage: addDangerToast(t('Your dashboard is too large...')). The
new type correctly reflects the actual API.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]