Skip to content

Commit 5b4f81f

Browse files
authored
Merge pull request #623 from raghavyuva/feat/disable-notification-domains
chore: disable notifications and domain pages for now
2 parents 4f18d26 + 383be27 commit 5b4f81f

File tree

6 files changed

+66
-30
lines changed

6 files changed

+66
-30
lines changed

api/doc/openapi.json

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

view/app/dashboard/hooks/use-smtp-banner.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,10 @@ export default function useSmtpBanner() {
2222
};
2323

2424
const handleConfigure = () => {
25-
router.push('/settings/notifications');
25+
// TODO: Re-enable when notifications feature is working
26+
// router.push('/settings/notifications');
27+
// Temporarily disabled - redirect to general settings instead
28+
router.push('/settings/general');
2629
};
2730

2831
return {

view/app/dashboard/page.tsx

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,8 @@ import NetworkWidget from './components/system/network';
1515
// TODO: Add weather widget back in with configuration for api key
1616
// import WeatherWidget from './components/system/weather';
1717
import { useTranslation } from '@/hooks/use-translation';
18-
import { SMTPBanner } from './components/smtp-banner';
18+
// TODO: Re-enable SMTP banner when notifications feature is working
19+
// import { SMTPBanner } from './components/smtp-banner';
1920
import DisabledFeature from '@/components/features/disabled-feature';
2021
import { Button } from '@/components/ui/button';
2122
import { useRouter } from 'next/navigation';
@@ -34,7 +35,8 @@ function DashboardPage() {
3435
isDashboardEnabled,
3536
containersData,
3637
systemStats,
37-
smtpConfig,
38+
// TODO: Re-enable when SMTP banner is working
39+
// smtpConfig,
3840
showDragHint,
3941
mounted,
4042
layoutResetKey,
@@ -108,7 +110,8 @@ function DashboardPage() {
108110
availableWidgets={availableWidgets}
109111
/>
110112
<DragHintBanner mounted={mounted} showDragHint={showDragHint} onDismiss={dismissHint} />
111-
<SMTPBannerConditional hasSMTPConfig={!!smtpConfig} />
113+
{/* TODO: Re-enable SMTP banner when notifications feature is working */}
114+
{/* <SMTPBannerConditional hasSMTPConfig={!!smtpConfig} /> */}
112115
<MonitoringSection
113116
systemStats={systemStats}
114117
containersData={containersData}
@@ -189,10 +192,11 @@ const DragHintBanner = ({
189192
);
190193
};
191194

192-
const SMTPBannerConditional = ({ hasSMTPConfig }: { hasSMTPConfig: boolean }) => {
193-
if (hasSMTPConfig) return null;
194-
return <SMTPBanner />;
195-
};
195+
// TODO: Re-enable SMTP banner when notifications feature is working
196+
// const SMTPBannerConditional = ({ hasSMTPConfig }: { hasSMTPConfig: boolean }) => {
197+
// if (hasSMTPConfig) return null;
198+
// return <SMTPBanner />;
199+
// };
196200

197201
const MonitoringSection = ({
198202
systemStats,

view/app/settings/domains/page.tsx

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
// TODO: Re-enable domains page when feature is required
2+
/*
13
'use client';
24
import DashboardPageHeader from '@/components/layout/dashboard-page-header';
35
import { Button } from '@/components/ui/button';
@@ -122,3 +124,11 @@ const NoDomainsFound = ({ onPressAddDomain }: NoDomainsFoundProps) => {
122124
</div>
123125
);
124126
};
127+
*/
128+
129+
// Temporary placeholder component
130+
const Page = () => {
131+
return null;
132+
};
133+
134+
export default Page;

view/app/settings/notifications/page.tsx

Lines changed: 28 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,40 @@
11
'use client';
22
import React from 'react';
33
import DashboardPageHeader from '@/components/layout/dashboard-page-header';
4-
import NotificationPreferencesTab from './components/preferenceTab';
5-
import NotificationChannelsTab from './components/channelTab';
6-
import useNotificationSettings from '../hooks/use-notification-settings';
7-
import { Tabs, TabsContent, TabsList, TabsTrigger } from '@/components/ui/tabs';
8-
import { useTranslation } from '@/hooks/use-translation';
9-
import { SMTPFormData } from '@/redux/types/notification';
10-
import { useFeatureFlags } from '@/hooks/features_provider';
11-
import Skeleton from '@/app/file-manager/components/skeleton/Skeleton';
12-
import DisabledFeature from '@/components/features/disabled-feature';
13-
import { FeatureNames } from '@/types/feature-flags';
14-
import { ResourceGuard } from '@/components/rbac/PermissionGuard';
154
import PageLayout from '@/components/layout/page-layout';
5+
// TODO: Re-enable notifications when feature is working
6+
// import NotificationPreferencesTab from './components/preferenceTab';
7+
// import NotificationChannelsTab from './components/channelTab';
8+
// import useNotificationSettings from '../hooks/use-notification-settings';
9+
// import { Tabs, TabsContent, TabsList, TabsTrigger } from '@/components/ui/tabs';
10+
// import { useTranslation } from '@/hooks/use-translation';
11+
// import { SMTPFormData } from '@/redux/types/notification';
12+
// import { useFeatureFlags } from '@/hooks/features_provider';
13+
// import Skeleton from '@/app/file-manager/components/skeleton/Skeleton';
14+
// import DisabledFeature from '@/components/features/disabled-feature';
15+
// import { FeatureNames } from '@/types/feature-flags';
16+
// import { ResourceGuard } from '@/components/rbac/PermissionGuard';
1617

1718
export type NotificationChannelConfig = {
1819
[key: string]: string;
1920
};
2021

2122
const Page: React.FC = () => {
23+
// TODO: Re-enable notifications when feature is working
24+
// Temporarily disabled - notifications feature is not working
25+
return (
26+
<PageLayout maxWidth="6xl" padding="md" spacing="lg">
27+
<DashboardPageHeader
28+
label="Notifications"
29+
description="Notifications feature is temporarily disabled"
30+
/>
31+
<div className="text-center py-8 text-muted-foreground">
32+
Notifications feature is currently disabled. This will be re-enabled in a future update.
33+
</div>
34+
</PageLayout>
35+
);
36+
37+
/* COMMENTED OUT - Re-enable when notifications feature is working
2238
const { t } = useTranslation();
2339
const {
2440
smtpConfigs,
@@ -128,6 +144,7 @@ const Page: React.FC = () => {
128144
</PageLayout>
129145
</ResourceGuard>
130146
);
147+
*/
131148
};
132149

133150
export default Page;

view/hooks/use-app-sidebar.ts

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -61,21 +61,23 @@ const data = {
6161
url: '/settings/general',
6262
resource: 'settings'
6363
},
64-
{
65-
title: 'navigation.notifications',
66-
url: '/settings/notifications',
67-
resource: 'notification'
68-
},
64+
// TODO: Re-enable notifications when feature is working
65+
// {
66+
// title: 'navigation.notifications',
67+
// url: '/settings/notifications',
68+
// resource: 'notification'
69+
// },
6970
{
7071
title: 'navigation.team',
7172
url: '/settings/teams',
7273
resource: 'organization'
73-
},
74-
{
75-
title: 'navigation.domains',
76-
url: '/settings/domains',
77-
resource: 'domain'
7874
}
75+
// TODO: Re-enable domains when feature is required
76+
// {
77+
// title: 'navigation.domains',
78+
// url: '/settings/domains',
79+
// resource: 'domain'
80+
// }
7981
]
8082
}
8183
]

0 commit comments

Comments
 (0)