mirror of
https://github.com/bitsocialnet/5chan.git
synced 2026-08-03 07:41:04 +02:00
style: add create board button and edit boards button
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
.mobileBoardButtons {
|
.mobileBoardButtons {
|
||||||
text-align: center;
|
text-align: center;
|
||||||
margin: 10px 0;
|
margin-bottom: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.mobileBoardButtons button {
|
.mobileBoardButtons button {
|
||||||
@@ -51,10 +51,29 @@
|
|||||||
padding-top: 15px;
|
padding-top: 15px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.createBoardButton {
|
||||||
|
text-align: center;
|
||||||
|
font-size: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.createBoardButton a {
|
||||||
|
text-decoration: none;
|
||||||
|
color: var(--button-desktop-text-color);
|
||||||
|
|
||||||
|
}
|
||||||
|
.createBoardButton a:hover {
|
||||||
|
cursor: pointer;
|
||||||
|
color: var(--button-desktop-text-color-hover);
|
||||||
|
}
|
||||||
|
|
||||||
@media (max-width: 640px) {
|
@media (max-width: 640px) {
|
||||||
.desktopBoardButtons {
|
.desktopBoardButtons {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.createBoardButton {
|
||||||
|
display: inline-flex;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@media (min-width: 640px) {
|
@media (min-width: 640px) {
|
||||||
|
|||||||
@@ -172,6 +172,24 @@ export const TimeFilter = ({ isInAllView, isInCatalogView, isInSubscriptionsView
|
|||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const CreateBoardButton = () => {
|
||||||
|
return (
|
||||||
|
<div className={styles.createBoardButton}>
|
||||||
|
[
|
||||||
|
<Link
|
||||||
|
to='/boards/create'
|
||||||
|
onClick={(e) => {
|
||||||
|
e.preventDefault();
|
||||||
|
alert('work in progress');
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
Create a Board
|
||||||
|
</Link>
|
||||||
|
]
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
export const MobileBoardButtons = () => {
|
export const MobileBoardButtons = () => {
|
||||||
const params = useParams();
|
const params = useParams();
|
||||||
const location = useLocation();
|
const location = useLocation();
|
||||||
@@ -186,6 +204,8 @@ export const MobileBoardButtons = () => {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<div className={styles.mobileBoardButtons}>
|
<div className={styles.mobileBoardButtons}>
|
||||||
|
<CreateBoardButton />
|
||||||
|
<hr />
|
||||||
{isInPostView || isInPendingPostPage ? (
|
{isInPostView || isInPendingPostPage ? (
|
||||||
<>
|
<>
|
||||||
<ReturnButton address={subplebbitAddress} isInAllView={isInAllView} isInSubscriptionsView={isInSubscriptionsView} />
|
<ReturnButton address={subplebbitAddress} isInAllView={isInAllView} isInSubscriptionsView={isInSubscriptionsView} />
|
||||||
@@ -233,6 +253,8 @@ export const DesktopBoardButtons = () => {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
|
<hr />
|
||||||
|
<CreateBoardButton />
|
||||||
<hr />
|
<hr />
|
||||||
<div className={styles.desktopBoardButtons}>
|
<div className={styles.desktopBoardButtons}>
|
||||||
{isInPostView || isInPendingPostPage ? (
|
{isInPostView || isInPendingPostPage ? (
|
||||||
|
|||||||
@@ -20,6 +20,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.boardSubtitle {
|
.boardSubtitle {
|
||||||
|
margin-top: 3px;
|
||||||
font-size: var(--board-address-font-size);
|
font-size: var(--board-address-font-size);
|
||||||
color: var(--board-address-text-color);
|
color: var(--board-address-text-color);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -80,7 +80,17 @@ const TopBarDesktop = () => {
|
|||||||
{subplebbits && (
|
{subplebbits && (
|
||||||
<>
|
<>
|
||||||
[{renderSubplebbits(plebbitSubs)}] [{renderSubplebbits(projectsSubs)}] [{renderSubplebbits(interestsSubs)}] [{renderSubplebbits(randomSubs)}] [
|
[{renderSubplebbits(plebbitSubs)}] [{renderSubplebbits(projectsSubs)}] [{renderSubplebbits(interestsSubs)}] [{renderSubplebbits(randomSubs)}] [
|
||||||
{renderSubplebbits(internationalSubs)}]
|
{renderSubplebbits(internationalSubs)}] [
|
||||||
|
<Link
|
||||||
|
to='boards'
|
||||||
|
onClick={(e) => {
|
||||||
|
e.preventDefault();
|
||||||
|
alert('work in progress');
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
Edit
|
||||||
|
</Link>
|
||||||
|
]
|
||||||
</>
|
</>
|
||||||
)}
|
)}
|
||||||
</span>
|
</span>
|
||||||
|
|||||||
Reference in New Issue
Block a user