@xenide-io/the-old-ui-theme 0.9.14 → 0.9.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -39,8 +39,6 @@ export interface SuiteNotificationsResponse {
39
39
  export interface SuiteNotificationsContextValue {
40
40
  notifications: SuiteNotification[];
41
41
  unreadCount: number;
42
- open: boolean;
43
- setOpen: (open: boolean) => void;
44
42
  refresh: () => void;
45
43
  select: (notification: SuiteNotification) => void;
46
44
  markAllRead: () => void;
@@ -96,7 +94,6 @@ export function SuiteNotificationsProvider({
96
94
  const router = useRouter();
97
95
  const [notifications, setNotifications] = useState<SuiteNotification[]>([]);
98
96
  const [unreadCount, setUnreadCount] = useState(0);
99
- const [open, setOpen] = useState(false);
100
97
 
101
98
  const load = useCallback(async () => {
102
99
  try {
@@ -168,17 +165,8 @@ export function SuiteNotificationsProvider({
168
165
  };
169
166
  }, [enabled, load, pollMs, cacheKey]);
170
167
 
171
- const setOpenAndRefresh = useCallback(
172
- (next: boolean) => {
173
- setOpen(next);
174
- if (next) void load();
175
- },
176
- [load],
177
- );
178
-
179
168
  const select = useCallback(
180
169
  (notification: SuiteNotification) => {
181
- setOpen(false);
182
170
  if (!notification.read_at) {
183
171
  setNotifications((prev) =>
184
172
  prev.map((item) =>
@@ -257,21 +245,11 @@ export function SuiteNotificationsProvider({
257
245
  () => ({
258
246
  notifications,
259
247
  unreadCount,
260
- open,
261
- setOpen: setOpenAndRefresh,
262
248
  refresh: () => void load(),
263
249
  select,
264
250
  markAllRead,
265
251
  }),
266
- [
267
- notifications,
268
- unreadCount,
269
- open,
270
- setOpenAndRefresh,
271
- load,
272
- select,
273
- markAllRead,
274
- ],
252
+ [notifications, unreadCount, load, select, markAllRead],
275
253
  );
276
254
 
277
255
  return (