degmods.com/src/pages/write.tsx

76 lines
2.4 KiB
TypeScript
Raw Normal View History

2024-07-12 09:22:31 +00:00
import { CheckboxField, InputField } from '../components/Inputs'
import { ProfileSection } from '../components/ProfileSection'
2024-09-03 08:15:47 +00:00
import { useAppSelector } from '../hooks'
2024-07-12 09:22:31 +00:00
import '../styles/innerPage.css'
import '../styles/styles.css'
import '../styles/write.css'
export const WritePage = () => {
2024-09-03 08:15:47 +00:00
const userState = useAppSelector((state) => state.user)
2024-07-12 09:22:31 +00:00
return (
<div className='InnerBodyMain'>
<div className='ContainerMain'>
<div className='IBMSecMainGroup IBMSecMainGroupAlt'>
<div className='IBMSMSplitMain'>
<div className='IBMSMSplitMainBigSide'>
<div className='IBMSMTitleMain'>
2024-09-03 08:15:47 +00:00
<h2 className='IBMSMTitleMainHeading'>
Write a blog post (WIP)
</h2>
2024-07-12 09:22:31 +00:00
</div>
<div className='IBMSMSMBS_Write'>
2024-08-08 17:28:28 +00:00
<InputField
label='Title'
placeholder=''
name='title'
value=''
onChange={() => {}}
/>
<InputField
label='Body'
placeholder=''
name='body'
value=''
onChange={() => {}}
/>
2024-07-12 09:22:31 +00:00
<InputField
label='Featured Image URL'
placeholder=''
name='imageUrl'
inputMode='url'
2024-08-08 17:28:28 +00:00
value=''
onChange={() => {}}
2024-07-12 09:22:31 +00:00
/>
<InputField
label='Summary'
placeholder=''
name='summary'
type='textarea'
2024-08-08 17:28:28 +00:00
value=''
onChange={() => {}}
2024-07-12 09:22:31 +00:00
/>
<CheckboxField
label='This mod not safe for work (NSFW)'
name='nsfw'
2024-08-08 17:28:28 +00:00
isChecked={false}
handleChange={() => {}}
2024-10-23 15:23:48 +00:00
type='stylized'
2024-07-12 09:22:31 +00:00
/>
<div className='IBMSMSMBS_WriteAction'>
<button className='btn btnMain' type='button'>
Publish
</button>
</div>
</div>
</div>
2024-09-03 08:15:47 +00:00
{userState.auth && userState.user?.pubkey && (
<ProfileSection pubkey={userState.user.pubkey as string} />
)}
2024-07-12 09:22:31 +00:00
</div>
</div>
</div>
</div>
)
}