Skip to content

Commit

Permalink
refactor: Remove unused BookmarkedTextViewer (#310)
Browse files Browse the repository at this point in the history
  • Loading branch information
kamtschatka authored Jul 21, 2024
1 parent 98fc559 commit eb0a28e
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 31 deletions.
23 changes: 0 additions & 23 deletions apps/web/components/dashboard/bookmarks/BookmarkedTextViewer.tsx

This file was deleted.

8 changes: 0 additions & 8 deletions apps/web/components/dashboard/bookmarks/TextCard.tsx
Original file line number Diff line number Diff line change
@@ -1,13 +1,11 @@
"use client";

import { useState } from "react";
import { MarkdownComponent } from "@/components/ui/markdown-component";
import { bookmarkLayoutSwitch } from "@/lib/userLocalSettings/bookmarksLayout";
import { cn } from "@/lib/utils";

import type { ZBookmarkTypeText } from "@hoarder/shared/types/bookmarks";

import { BookmarkedTextViewer } from "./BookmarkedTextViewer";
import { BookmarkLayoutAdaptingCard } from "./BookmarkLayoutAdaptingCard";

export default function TextCard({
Expand All @@ -17,16 +15,10 @@ export default function TextCard({
bookmark: ZBookmarkTypeText;
className?: string;
}) {
const [previewModalOpen, setPreviewModalOpen] = useState(false);
const bookmarkedText = bookmark.content;

return (
<>
<BookmarkedTextViewer
content={bookmarkedText.text}
open={previewModalOpen}
setOpen={setPreviewModalOpen}
/>
<BookmarkLayoutAdaptingCard
title={bookmark.title}
content={<MarkdownComponent>{bookmarkedText.text}</MarkdownComponent>}
Expand Down

0 comments on commit eb0a28e

Please sign in to comment.