From 3cf70cf3b66f840a92f3f44acc11d321e086fc0c Mon Sep 17 00:00:00 2001 From: Yann Bizeul Date: Sun, 6 Oct 2024 17:47:19 +0200 Subject: [PATCH] Removed unused imports --- web/ui/src/YBFeed/Components/YBFeedItemComponent.tsx | 1 - web/ui/src/YBFeed/YBFeedApp.tsx | 2 -- web/ui/src/YBFeed/YBFeedConnector.ts | 4 ++-- web/ui/src/YBFeed/YBFeedFeed.tsx | 6 +++--- 4 files changed, 5 insertions(+), 8 deletions(-) diff --git a/web/ui/src/YBFeed/Components/YBFeedItemComponent.tsx b/web/ui/src/YBFeed/Components/YBFeedItemComponent.tsx index 3d80352..2e6e95b 100644 --- a/web/ui/src/YBFeed/Components/YBFeedItemComponent.tsx +++ b/web/ui/src/YBFeed/Components/YBFeedItemComponent.tsx @@ -8,7 +8,6 @@ import { YBFeedItemTextComponent, YBFeedItemImageComponent, copyImageItem, FeedI import { YBFeedConnector, YBFeedItem } from '../' import { defaultNotificationProps } from '../config'; -import { YBFeedItemBinaryComponent } from './YBFeedItemBinaryComponent'; //const connection = new YBFeedConnector() diff --git a/web/ui/src/YBFeed/YBFeedApp.tsx b/web/ui/src/YBFeed/YBFeedApp.tsx index 67adfbf..9a8e6d4 100644 --- a/web/ui/src/YBFeed/YBFeedApp.tsx +++ b/web/ui/src/YBFeed/YBFeedApp.tsx @@ -2,9 +2,7 @@ import { AppShell, Container } from "@mantine/core" import { BrowserRouter, - createBrowserRouter, Route, - RouterProvider, Routes, } from "react-router-dom"; diff --git a/web/ui/src/YBFeed/YBFeedConnector.ts b/web/ui/src/YBFeed/YBFeedConnector.ts index 5bb8b85..a286abb 100644 --- a/web/ui/src/YBFeed/YBFeedConnector.ts +++ b/web/ui/src/YBFeed/YBFeedConnector.ts @@ -1,4 +1,4 @@ -import { AxiosResponse, AxiosResponseHeaders } from 'axios' +import { AxiosResponseHeaders } from 'axios' import { YBFeed, YBFeedItem, YBFeedError } from '.' import { Y } from '../YBFeedClient' @@ -229,7 +229,7 @@ export class YBFeedConnector { async AddSubscription(feedName: string, subscription: any): Promise { return new Promise((resolve, reject) => { Y.post('/feeds/' + encodeURIComponent(feedName) + "/subscription", subscription) - .then((f) => { + .then(() => { resolve(true) }) .catch((error) => { diff --git a/web/ui/src/YBFeed/YBFeedFeed.tsx b/web/ui/src/YBFeed/YBFeedFeed.tsx index b019496..86d3d1e 100644 --- a/web/ui/src/YBFeed/YBFeedFeed.tsx +++ b/web/ui/src/YBFeed/YBFeedFeed.tsx @@ -1,14 +1,14 @@ import { useEffect, useState, useMemo, useRef } from "react" -import { useParams, useSearchParams, Navigate, redirect } from 'react-router-dom'; +import { useParams, useSearchParams, redirect } from 'react-router-dom'; import { notifications } from '@mantine/notifications'; -import { Menu, ActionIcon, PinInput, Text, Modal, Center, Group, rem, Button, Box} from '@mantine/core'; +import { Menu, ActionIcon, Center, Group, rem, Button, Box} from '@mantine/core'; import { YBFeed, YBFeedConnector, YBFeedItem } from '.' -import { YBBreadCrumbComponent, YBPasteCardComponent, YBFeedItemsComponent, YBNotificationToggleComponent, YBFeedItemComponent } from './Components' +import { YBBreadCrumbComponent, YBPasteCardComponent, YBFeedItemsComponent, YBNotificationToggleComponent } from './Components' import { defaultNotificationProps } from './config'; import {