diff --git a/src/components/Board.jsx b/src/components/Board.jsx
index 88f96789..5a02ae25 100644
--- a/src/components/Board.jsx
+++ b/src/components/Board.jsx
@@ -1,4 +1,4 @@
-import React, { useState, useEffect, useContext } from 'react';
+import React, { useState, useEffect, useContext, Fragment } from 'react';
import { Link, useNavigate, useParams, useLocation } from 'react-router-dom';
import { BoardContext } from '../App';
import { Container, NavBar, Header, Break, PostFormLink, PostFormTable, PostForm, TopBar, BoardForm } from './styles/Board.styled';
@@ -447,189 +447,189 @@ const Board = ({ setBodyStyle }) => {
pageStart={0}
loadMore={tryLoadMore}
hasMore={hasMore}
- loader={
Loading...
}
+ loader={Loading...
}
>
{renderedFeed.map(thread => {
const { replies: { pages: { topAll: { comments } } } } = thread;
const { renderedComments, omittedCount } = renderComments(comments);
return (
- <>
-
-
-
-
-
-
-
+
+
+
+
+
+
+
-
+
{thread.title ? (
thread.title.length > 75 ?
- <>
-
-
+
+
{thread.title.slice(0, 75) + " (...)"}
- >
- :
+
+ :
{thread.title}
)
: null}
{thread.author.displayName
? thread.author.displayName.length > 20
- ? <>
-
-
+
+
{thread.author.displayName.slice(0, 20) + " (...)"}
- >
- :
+
+ :
{thread.author.displayName}
- :
+ :
Anonymous }
(u/
{thread.author.address.length > 15 ?
- <>
-
-
+
+
{thread.author.address.slice(0, 15) + "..."}
- >
- :
+
+ :
{thread.author.address}
})
- {getDate(thread.timestamp)}
+ {getDate(thread.timestamp)}
-
- c/
- {thread.cid.slice(0, 8)}
+
+ c/
+ {thread.cid.slice(0, 8)}
-
+
[
- handleClickThread(thread.cid)} className="reply-link" >Reply
+ handleClickThread(thread.cid)} className="reply-link" >Reply
]
- ▶
-
-
- {'c/'}{thread.cid.slice(0, 8)}
+ ▶
+
{thread.content ? (
thread.content.length > 2000 ?
- <>
-
+
+
{thread.content.slice(0, 2000)}
- (...)
-
+ (...)
+
Post too long.
- handleClickThread(thread.cid)} className="ttl-link">Click here
+ handleClickThread(thread.cid)} className="ttl-link">Click here
to view.
- >
- :
+
+ :
{thread.content}
)
: null}
-
+
{omittedCount > 0 ? (
-
-
+
+
{omittedCount} post{omittedCount > 1 ? "s" : ""} omitted. Click
- handleClickThread(thread.cid)} className="ttl-link">here
+ handleClickThread(thread.cid)} className="ttl-link">here
to view.
) : null}
{renderedComments.map(reply => {
return (
-
-
{'>>'}
-
-
-
+
-
-
-
-
-
-
...
-
+
+
+
+
+
+
...
+
{thread.author.displayName
? thread.author.displayName.length > 15
- ? <>
-
-
+
+
{thread.author.displayName.slice(0, 15) + " (...)"}
- >
- :
+
+ :
{thread.author.displayName}
- :
+ :
Anonymous }
-
+
(u/
{thread.author.address.length > 15 ?
- <>
-
-
+
+
{thread.author.address.slice(0, 15) + "..."}
- >
- :
+
+ :
{thread.author.address}
}
)
-
+
{thread.title ? (
thread.title.length > 30 ?
- <>
-
-
+
+
{thread.title.slice(0, 30) + " (...)"}
- >
- :
+
+ :
{thread.title}
)
: null}
-
+
{getDate(thread.timestamp)}
- c/
- {thread.cid.slice(0, 8)}
+ c/
+ {thread.cid.slice(0, 8)}
-
-
-
{thread.replyCount} Replies / ? Images
-
handleClickThread(thread.cid)} className="button-mobile" >View Thread
+
+ {thread.replyCount} Replies / ? Images
+ handleClickThread(thread.cid)} className="button-mobile" >View Thread
{renderedComments.map(reply => {
return (
-
-
-
diff --git a/src/components/Catalog.jsx b/src/components/Catalog.jsx
index 8a531425..f10062e9 100644
--- a/src/components/Catalog.jsx
+++ b/src/components/Catalog.jsx
@@ -284,9 +284,9 @@ const Catalog = ({ setBodyStyle }) => {
<>
{defaultSubplebbits.map(subplebbit => (
-
+
[
- handleClickTitle(subplebbit.title, subplebbit.address)}
+ handleClickTitle(subplebbit.title, subplebbit.address)}
>{subplebbit.title}
]
@@ -306,7 +306,7 @@ const Catalog = ({ setBodyStyle }) => {
{defaultSubplebbits.map(subplebbit => (
- {subplebbit.title}
))}
@@ -420,23 +420,23 @@ const Catalog = ({ setBodyStyle }) => {
pageStart={0}
loadMore={tryLoadMore}
hasMore={hasMore}
- loader={Loading...
}
+ loader={Loading...
}
>
{feed.map(thread => {
return (
-
-
handleClickThread(thread.cid)}>
-
+
+
handleClickThread(thread.cid)}>
+
-
-
+
+
-
+
R:
- {thread.replyCount}
+ {thread.replyCount}
-
-
{thread.title ? `${thread.title}` : null}
+
+ {thread.title ? `${thread.title}` : null}
{thread.content ? `: ${thread.content}` : null}
diff --git a/src/components/Thread.jsx b/src/components/Thread.jsx
index 6f12fab7..2bd74b75 100644
--- a/src/components/Thread.jsx
+++ b/src/components/Thread.jsx
@@ -209,9 +209,9 @@ const Thread = ({ setBodyStyle }) => {
<>
{defaultSubplebbits.map(subplebbit => (
-
+
[
- handleClickTitle(subplebbit.title, subplebbit.address)}
>{subplebbit.title}
@@ -233,7 +233,7 @@ const Thread = ({ setBodyStyle }) => {
{defaultSubplebbits.map(subplebbit => (
- {subplebbit.title}
))}
@@ -375,28 +375,28 @@ const Thread = ({ setBodyStyle }) => {
-
-
+
{comment.title ? (
comment.title.length > 75 ?
<>
-
-
+
{comment.title.slice(0, 75) + " (...)"}
>
- :
+ :
{comment.title}
)
: null}
@@ -404,17 +404,17 @@ const Thread = ({ setBodyStyle }) => {
{comment.author.displayName
? comment.author.displayName.length > 20
? <>
-
-
+
{comment.author.displayName.slice(0, 20) + " (...)"}
>
- :
+ :
{comment.author.displayName}
- :
+ :
Anonymous }
@@ -422,15 +422,15 @@ const Thread = ({ setBodyStyle }) => {
(u/
{comment.author.address.length > 20 ?
<>
-
-
+
{comment.author.address.slice(0, 20) + "..."}
>
- :
+ :
{comment.author.address}
})
@@ -441,7 +441,7 @@ const Thread = ({ setBodyStyle }) => {
c/
{comment.cid.slice(0, 8)}
- ▶
+ ▶
c/{comment.cid.slice(0, 8)}
@@ -459,55 +459,55 @@ const Thread = ({ setBodyStyle }) => {
const renderedComments = renderComments(comment.replies.pages.topAll.comments);
return renderedComments.map(reply => {
return (
-
-
{'>>'}
-
-
+
+
{'>>'}
+
+
-
+
{reply.author.displayName
? reply.author.displayName.length > 20
? <>
-
-
+
{reply.author.displayName.slice(0, 20) + " (...)"}
>
- :
+ :
{reply.author.displayName}
- :
+ :
Anonymous }
-
+
(u/
{reply.author.address.length > 20 ?
<>
-
-
+
{reply.author.address.slice(0, 20) + "..."}
>
- :
+ :
{reply.author.address}
})
- {getDate(reply.timestamp)}
+ {getDate(reply.timestamp)}
-
- c/
- {reply.cid.slice(0, 8)}
+
+ c/
+ {reply.cid.slice(0, 8)}
- ▶
+ ▶
-
+
{`c/${reply.parentCid.slice(0, 8)}`}{ }
@@ -522,73 +522,73 @@ const Thread = ({ setBodyStyle }) => {
-
-
-
...
+
+
+
...
{comment.author.displayName
? comment.author.displayName.length > 15
? <>
-
-
+
{comment.author.displayName.slice(0, 15) + " (...)"}
>
- :
+ :
{comment.author.displayName}
- :
+ :
Anonymous }
-
+
(u/
{comment.author.address.length > 15 ?
<>
-
-
+
{comment.author.address.slice(0, 15) + "..."}
>
- :
+ :
{comment.author.address}
}
)
-
+
{comment.title ? (
comment.title.length > 30 ?
<>
-
-
+
{comment.title.slice(0, 30) + " (...)"}
>
- :
+ :
{comment.title}
) : null}
-
+
{getDate(comment.timestamp)}
- c/
- {comment.cid.slice(0, 8)}
+ c/
+ {comment.cid.slice(0, 8)}
-