mirror of https://github.com/buster-so/buster.git
Add more descriptions and remove logs
This commit is contained in:
parent
9d5850cc07
commit
1fb5310f76
|
@ -10,7 +10,7 @@ import { isDev } from '@/config';
|
||||||
import { useUserConfigContextSelector } from '../Users';
|
import { useUserConfigContextSelector } from '../Users';
|
||||||
|
|
||||||
const POSTHOG_KEY = process.env.NEXT_PUBLIC_POSTHOG_KEY;
|
const POSTHOG_KEY = process.env.NEXT_PUBLIC_POSTHOG_KEY;
|
||||||
const DEBUG_POSTHOG = false;
|
const DEBUG_POSTHOG = true;
|
||||||
|
|
||||||
export const BusterPosthogProvider: React.FC<PropsWithChildren> = React.memo(({ children }) => {
|
export const BusterPosthogProvider: React.FC<PropsWithChildren> = React.memo(({ children }) => {
|
||||||
if ((isDev && !DEBUG_POSTHOG) || !POSTHOG_KEY) {
|
if ((isDev && !DEBUG_POSTHOG) || !POSTHOG_KEY) {
|
||||||
|
@ -30,9 +30,13 @@ const options: Partial<PostHogConfig> = {
|
||||||
|
|
||||||
loaded: () => {
|
loaded: () => {
|
||||||
console.log(
|
console.log(
|
||||||
'%c🚀 Powered by Buster',
|
'%c🚀 Welcome to Buster',
|
||||||
'background: linear-gradient(to right, #a21caf, #8b1cb1, #6b21a8); color: white; font-size: 16px; font-weight: bold; padding: 10px; border-radius: 5px;'
|
'background: linear-gradient(to right, #a21caf, #8b1cb1, #6b21a8); color: white; font-size: 16px; font-weight: bold; padding: 10px; border-radius: 5px;'
|
||||||
);
|
);
|
||||||
|
console.log(
|
||||||
|
'%cBuster is your open-source data analytics platform. Found a bug? The code is open-source! Report it at https://github.com/buster-so/buster. Better yet, fix it yourself and send a PR.',
|
||||||
|
'background: #6b21a8; color: white; font-size: 10px; font-weight: normal; padding: 8px; border-radius: 4px;'
|
||||||
|
);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -26,8 +26,6 @@ export const SelectAxis: React.FC<
|
||||||
> = React.memo(({ selectedChartType, columnMetadata, selectedAxis, ...props }) => {
|
> = React.memo(({ selectedChartType, columnMetadata, selectedAxis, ...props }) => {
|
||||||
const { onUpdateMetricChartConfig } = useUpdateMetricChart();
|
const { onUpdateMetricChartConfig } = useUpdateMetricChart();
|
||||||
|
|
||||||
console.log(selectedChartType);
|
|
||||||
|
|
||||||
const items: SelectAxisItem[] = useMemo(() => {
|
const items: SelectAxisItem[] = useMemo(() => {
|
||||||
return columnMetadata.map((column) => column.name);
|
return columnMetadata.map((column) => column.name);
|
||||||
}, [columnMetadata]);
|
}, [columnMetadata]);
|
||||||
|
|
|
@ -87,8 +87,6 @@ export const ThreeDotMenuButton = React.memo(
|
||||||
const renameMetricMenu = useRenameMetricSelectMenu({ metricId });
|
const renameMetricMenu = useRenameMetricSelectMenu({ metricId });
|
||||||
const shareMenu = useShareMenuSelectMenu({ metricId });
|
const shareMenu = useShareMenuSelectMenu({ metricId });
|
||||||
|
|
||||||
console.log(permission);
|
|
||||||
|
|
||||||
const isEditor = canEdit(permission);
|
const isEditor = canEdit(permission);
|
||||||
const isOwnerEffective = getIsEffectiveOwner(permission);
|
const isOwnerEffective = getIsEffectiveOwner(permission);
|
||||||
const isOwner = getIsOwner(permission);
|
const isOwner = getIsOwner(permission);
|
||||||
|
|
|
@ -25,8 +25,6 @@ describe('createDashboardRoute', () => {
|
||||||
page: 'dashboard'
|
page: 'dashboard'
|
||||||
});
|
});
|
||||||
|
|
||||||
console.log('result', result);
|
|
||||||
|
|
||||||
expect(result).toBe(
|
expect(result).toBe(
|
||||||
'/app/chats/chat-456/dashboards/dashboard-123?secondary_view=version-history&dashboard_version_number=5'
|
'/app/chats/chat-456/dashboards/dashboard-123?secondary_view=version-history&dashboard_version_number=5'
|
||||||
);
|
);
|
||||||
|
|
|
@ -395,7 +395,6 @@ describe('createMetricRoute', () => {
|
||||||
expect(result).toContain(BusterRoutes.APP_CHAT_ID_METRIC_ID_CHART);
|
expect(result).toContain(BusterRoutes.APP_CHAT_ID_METRIC_ID_CHART);
|
||||||
expect(result).toContain('chatId=chat-456');
|
expect(result).toContain('chatId=chat-456');
|
||||||
expect(result).toContain('metricId=metric-123');
|
expect(result).toContain('metricId=metric-123');
|
||||||
console.log('result', result);
|
|
||||||
expect(result).toContain('metricVersionNumber=1');
|
expect(result).toContain('metricVersionNumber=1');
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue