فهرست منبع

Create InAppNotificationSubstance

Shun Miyazawa 2 سال پیش
والد
کامیت
6202efcba3

+ 10 - 1
apps/app/src/components/Sidebar/InAppNotification/InAppNotification.tsx

@@ -1,7 +1,12 @@
-import React from 'react';
+import React, { Suspense } from 'react';
 
+import dynamic from 'next/dynamic';
 import { useTranslation } from 'react-i18next';
 
+import ItemsTreeContentSkeleton from '../../ItemsTree/ItemsTreeContentSkeleton';
+
+const InAppNotificationSubstance = dynamic(() => import('./InAppNotificationSubstance').then(mod => mod.InAppNotificationSubstance), { ssr: false });
+
 export const InAppNotification = (): JSX.Element => {
   const { t } = useTranslation();
   return (
@@ -11,6 +16,10 @@ export const InAppNotification = (): JSX.Element => {
           {t('In-App Notification')}
         </h3>
       </div>
+
+      <Suspense fallback={<ItemsTreeContentSkeleton />}>
+        <InAppNotificationSubstance />
+      </Suspense>
     </div>
   );
 };

+ 8 - 0
apps/app/src/components/Sidebar/InAppNotification/InAppNotificationSubstance.tsx

@@ -0,0 +1,8 @@
+import React from 'react';
+
+export const InAppNotificationSubstance = (): JSX.Element => {
+
+  return (
+    <>InAppNotificationSubstance</>
+  );
+};