Skip to content

Commit

Permalink
chore: change private icon for private feed
Browse files Browse the repository at this point in the history
Signed-off-by: Innei <i@innei.in>
  • Loading branch information
Innei committed Aug 16, 2024
1 parent 1edf560 commit f439709
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 18 deletions.
11 changes: 11 additions & 0 deletions src/renderer/src/components/icons/OouiUserAnonymous.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import type { SVGProps } from "react"

export function OouiUserAnonymous(props: SVGProps<SVGSVGElement>) {
return (
<svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" viewBox="0 0 20 20" {...props}>
<path fill="currentColor" d="M15 2H5L4 8h12zM0 10s2 1 10 1s10-1 10-1l-4-2H4zm8 4h4v1H8z" />
<circle cx="6" cy="15" r="3" fill="currentColor" />
<circle cx="14" cy="15" r="3" fill="currentColor" />
</svg>
)
}
5 changes: 3 additions & 2 deletions src/renderer/src/modules/feed-column/item.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { getMainContainerElement } from "@renderer/atoms/dom"
import { useWhoami } from "@renderer/atoms/user"
import { FeedIcon } from "@renderer/components/feed-icon"
import { OouiUserAnonymous } from "@renderer/components/icons/OouiUserAnonymous"
import {
Tooltip,
TooltipContent,
Expand Down Expand Up @@ -166,8 +167,8 @@ const FeedItemImpl = ({
)}
{subscription.isPrivate && (
<Tooltip delayDuration={300}>
<TooltipTrigger asChild>
<i className="i-mgc-eye-close-cute-re ml-1 shrink-0 text-base" />
<TooltipTrigger>
<OouiUserAnonymous className="ml-1 shrink-0 text-base" />
</TooltipTrigger>
<TooltipPortal>
<TooltipContent>
Expand Down
20 changes: 4 additions & 16 deletions src/renderer/src/modules/feed-column/list.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -44,21 +44,6 @@ const useUpdateUnreadCount = () => {
useAuthQuery(Queries.subscription.unreadAll(), {
refetchInterval: false,
})
// const isPageVisible = usePageVisibility()

// useAccurateInterval(
// () => {
// if (!isPageVisible) {
// refetch()
// }
// },
// {
// enable: !isPageVisible,
// delay:
// // 10s
// 10_000,
// },
// )
}

export function FeedList({
Expand Down Expand Up @@ -144,7 +129,10 @@ export function FeedList({
onClick={() => setExpansion(true)}
/>
)}
<UnreadNumber unread={totalUnread} className="text-xs !text-inherit" />
<UnreadNumber
unread={totalUnread}
className="text-xs !text-inherit"
/>
</div>
</div>
<ScrollArea.ScrollArea
Expand Down

0 comments on commit f439709

Please sign in to comment.