diff --git a/src/views/media/media-post.tsx b/src/views/media/post/index.tsx similarity index 65% rename from src/views/media/media-post.tsx rename to src/views/media/post/index.tsx index 437209e41..a7dc1b0e3 100644 --- a/src/views/media/media-post.tsx +++ b/src/views/media/post/index.tsx @@ -1,28 +1,30 @@ import { ButtonGroup, Flex, Heading, Spinner } from "@chakra-ui/react"; import { NostrEvent } from "nostr-tools"; -import { useReadRelays } from "../../hooks/use-client-relays"; -import useParamsEventPointer from "../../hooks/use-params-event-pointer"; -import useSingleEvent from "../../hooks/use-single-event"; -import UserAvatarLink from "../../components/user/user-avatar-link"; -import UserLink from "../../components/user/user-link"; -import UserDnsIdentity from "../../components/user/user-dns-identity"; -import MediaPostSlides from "../../components/media-post/media-slides"; -import MediaPostContents from "../../components/media-post/media-post-content"; -import { TrustProvider } from "../../providers/local/trust-provider"; -import DebugEventButton from "../../components/debug-modal/debug-event-button"; -import EventShareButton from "../../components/note/timeline-note/components/event-share-button"; -import EventQuoteButton from "../../components/note/event-quote-button"; -import { useBreakpointValue } from "../../providers/global/breakpoint-provider"; -import EventZapIconButton from "../../components/zap/event-zap-icon-button"; -import AddReactionButton from "../../components/note/timeline-note/components/add-reaction-button"; -import EventReactionButtons from "../../components/event-reactions/event-reactions"; +import { useReadRelays } from "../../../hooks/use-client-relays"; +import useParamsEventPointer from "../../../hooks/use-params-event-pointer"; +import useSingleEvent from "../../../hooks/use-single-event"; +import UserAvatarLink from "../../../components/user/user-avatar-link"; +import UserLink from "../../../components/user/user-link"; +import UserDnsIdentity from "../../../components/user/user-dns-identity"; +import MediaPostSlides from "../../../components/media-post/media-slides"; +import MediaPostContents from "../../../components/media-post/media-post-content"; +import { TrustProvider } from "../../../providers/local/trust-provider"; +import DebugEventButton from "../../../components/debug-modal/debug-event-button"; +import EventShareButton from "../../../components/note/timeline-note/components/event-share-button"; +import EventQuoteButton from "../../../components/note/event-quote-button"; +import { useBreakpointValue } from "../../../providers/global/breakpoint-provider"; +import EventZapIconButton from "../../../components/zap/event-zap-icon-button"; +import AddReactionButton from "../../../components/note/timeline-note/components/add-reaction-button"; +import EventReactionButtons from "../../../components/event-reactions/event-reactions"; import { MediaPostComments } from "./media-comments"; import MediaPostCommentForm from "./media-post-comment-form"; +import BackButton from "../../../components/router/back-button"; function Header({ post }: { post: NostrEvent }) { return ( + @@ -76,10 +78,10 @@ function HorizontalLayout({ post }: { post: NostrEvent }) { function VerticalLayout({ post }: { post: NostrEvent }) { return ( - +
- + diff --git a/src/views/media/media-comments.tsx b/src/views/media/post/media-comments.tsx similarity index 66% rename from src/views/media/media-comments.tsx rename to src/views/media/post/media-comments.tsx index e5674750e..745631cd7 100644 --- a/src/views/media/media-comments.tsx +++ b/src/views/media/post/media-comments.tsx @@ -4,14 +4,14 @@ import { COMMENT_KIND } from "applesauce-core/helpers"; import { useStoreQuery } from "applesauce-react/hooks"; import { CommentsQuery } from "applesauce-core/queries"; -import { useReadRelays } from "../../hooks/use-client-relays"; -import UserLink from "../../components/user/user-link"; -import DebugEventButton from "../../components/debug-modal/debug-event-button"; -import useTimelineLoader from "../../hooks/use-timeline-loader"; -import IntersectionObserverProvider from "../../providers/local/intersection-observer"; -import { useTimelineCurserIntersectionCallback } from "../../hooks/use-timeline-cursor-intersection-callback"; -import TextNoteContents from "../../components/note/timeline-note/text-note-contents"; -import Timestamp from "../../components/timestamp"; +import { useReadRelays } from "../../../hooks/use-client-relays"; +import UserLink from "../../../components/user/user-link"; +import DebugEventButton from "../../../components/debug-modal/debug-event-button"; +import useTimelineLoader from "../../../hooks/use-timeline-loader"; +import IntersectionObserverProvider from "../../../providers/local/intersection-observer"; +import { useTimelineCurserIntersectionCallback } from "../../../hooks/use-timeline-cursor-intersection-callback"; +import TextNoteContents from "../../../components/note/timeline-note/text-note-contents"; +import Timestamp from "../../../components/timestamp"; function Comment({ comment }: { comment: NostrEvent }) { return ( diff --git a/src/views/media/media-post-comment-form.tsx b/src/views/media/post/media-post-comment-form.tsx similarity index 83% rename from src/views/media/media-post-comment-form.tsx rename to src/views/media/post/media-post-comment-form.tsx index 7c7f6174e..24e446277 100644 --- a/src/views/media/media-post-comment-form.tsx +++ b/src/views/media/post/media-post-comment-form.tsx @@ -5,12 +5,12 @@ import { NostrEvent } from "nostr-tools"; import { useEventFactory } from "applesauce-react/hooks"; import { Emoji } from "applesauce-core/helpers/emoji"; -import { usePublishEvent } from "../../providers/global/publish-provider"; -import { useContextEmojis } from "../../providers/global/emoji-provider"; -import { MagicInput, RefType } from "../../components/magic-textarea"; -import useTextAreaUploadFile, { useTextAreaInsertTextWithForm } from "../../hooks/use-textarea-upload-file"; -import { useWriteRelays } from "../../hooks/use-client-relays"; -import MessageSquare01 from "../../components/icons/message-square-01"; +import { usePublishEvent } from "../../../providers/global/publish-provider"; +import { useContextEmojis } from "../../../providers/global/emoji-provider"; +import { MagicInput, RefType } from "../../../components/magic-textarea"; +import useTextAreaUploadFile, { useTextAreaInsertTextWithForm } from "../../../hooks/use-textarea-upload-file"; +import { useWriteRelays } from "../../../hooks/use-client-relays"; +import MessageSquare01 from "../../../components/icons/message-square-01"; export default function MediaPostCommentForm({ post, diff --git a/src/views/media/routes.tsx b/src/views/media/routes.tsx index 4cf4a969d..c55beb65d 100644 --- a/src/views/media/routes.tsx +++ b/src/views/media/routes.tsx @@ -1,6 +1,6 @@ import { RouteObject } from "react-router-dom"; import MediaFeedView from "."; -import MediaPostView from "./media-post"; +import MediaPostView from "./post"; export default [ { index: true, Component: MediaFeedView },