mirror of
https://github.com/bitsocialnet/5chan.git
synced 2026-08-03 07:41:04 +02:00
fix board title in pending
This commit is contained in:
@@ -2,7 +2,7 @@ import React, { useEffect, useMemo, useState } from 'react';
|
|||||||
import { Helmet } from 'react-helmet-async';
|
import { Helmet } from 'react-helmet-async';
|
||||||
import { Link, useNavigate, useParams } from 'react-router-dom';
|
import { Link, useNavigate, useParams } from 'react-router-dom';
|
||||||
import { Tooltip } from 'react-tooltip';
|
import { Tooltip } from 'react-tooltip';
|
||||||
import { useAccount, useAccountComment } from '@plebbit/plebbit-react-hooks';
|
import { useAccount, useAccountComment, useSubplebbit } from '@plebbit/plebbit-react-hooks';
|
||||||
import useGeneralStore from '../../hooks/stores/useGeneralStore';
|
import useGeneralStore from '../../hooks/stores/useGeneralStore';
|
||||||
import { Container, NavBar, Header, Break, PostForm, BoardForm } from '../styled/views/Board.styled';
|
import { Container, NavBar, Header, Break, PostForm, BoardForm } from '../styled/views/Board.styled';
|
||||||
import { ReplyFormLink, TopBar, BottomBar } from '../styled/views/Thread.styled';
|
import { ReplyFormLink, TopBar, BottomBar } from '../styled/views/Thread.styled';
|
||||||
@@ -27,7 +27,7 @@ const Pending = () => {
|
|||||||
isSettingsOpen, setIsSettingsOpen,
|
isSettingsOpen, setIsSettingsOpen,
|
||||||
selectedAddress, setSelectedAddress,
|
selectedAddress, setSelectedAddress,
|
||||||
selectedStyle,
|
selectedStyle,
|
||||||
selectedTitle, setSelectedTitle,
|
setSelectedTitle,
|
||||||
showPostFormLink
|
showPostFormLink
|
||||||
} = useGeneralStore(state => state);
|
} = useGeneralStore(state => state);
|
||||||
|
|
||||||
@@ -39,6 +39,8 @@ const Pending = () => {
|
|||||||
const [isThumbnailClicked, setIsThumbnailClicked] = useState({});
|
const [isThumbnailClicked, setIsThumbnailClicked] = useState({});
|
||||||
const [isMobileThumbnailClicked, setIsMobileThumbnailClicked] = useState({});
|
const [isMobileThumbnailClicked, setIsMobileThumbnailClicked] = useState({});
|
||||||
|
|
||||||
|
const subplebbit = useSubplebbit({subplebbitAddress: comment?.subplebbitAddress})
|
||||||
|
const selectedTitle = subplebbit?.title;
|
||||||
|
|
||||||
const handleThumbnailClick = (index, isMobile=false) => {
|
const handleThumbnailClick = (index, isMobile=false) => {
|
||||||
if (isMobile) {
|
if (isMobile) {
|
||||||
|
|||||||
Reference in New Issue
Block a user