From 688fc80bae5f0d782a08f645c6b6bb75ad9e4275 Mon Sep 17 00:00:00 2001 From: plebbitor Date: Sun, 16 Apr 2023 11:21:05 +0200 Subject: [PATCH] update posting logic --- .env | 3 +++ src/components/CaptchaModal.jsx | 4 ++-- src/components/ReplyModal.jsx | 4 +++- src/components/views/Board.jsx | 5 +++-- src/components/views/Catalog.jsx | 35 ++++++++++++-------------------- src/components/views/Pending.jsx | 20 +++++++++--------- 6 files changed, 34 insertions(+), 37 deletions(-) create mode 100644 .env diff --git a/.env b/.env new file mode 100644 index 00000000..b39d8ffd --- /dev/null +++ b/.env @@ -0,0 +1,3 @@ +REACT_APP_PLEBBIT_REACT_HOOKS_MOCK_CONTENT=1 +REACT_APP_PLEBBIT_REACT_HOOKS_MOCK_CONTENT_LOADING_TIME=1000 +REACT_APP_PLEBBIT_REACT_HOOKS_MOCK_CONTENT_DOUBLE_MEDIA=1 \ No newline at end of file diff --git a/src/components/CaptchaModal.jsx b/src/components/CaptchaModal.jsx index 2e23a18b..40802fd7 100644 --- a/src/components/CaptchaModal.jsx +++ b/src/components/CaptchaModal.jsx @@ -62,9 +62,9 @@ const CaptchaModal = () => { - {comment.displayName - ? comment.displayName.length > 15 + {comment.author?.displayName + ? comment.author?.displayName.length > 15 ? <> - {comment.displayName.slice(0, 15) + " (...)"} + {comment.author?.displayName.slice(0, 15) + " (...)"} : - {comment.displayName} + {comment.author?.displayName} : Anonymous}