22
web/src/pages/PartPage/PartPage.js
Normal file
22
web/src/pages/PartPage/PartPage.js
Normal file
@@ -0,0 +1,22 @@
|
||||
import { useAuth } from '@redwoodjs/auth'
|
||||
|
||||
import MainLayout from 'src/layouts/MainLayout'
|
||||
import PartCell from 'src/components/PartCell'
|
||||
import Seo from 'src/components/Seo/Seo'
|
||||
|
||||
const PartPage = ({ userName, partTitle }) => {
|
||||
const { currentUser } = useAuth()
|
||||
return (
|
||||
<MainLayout>
|
||||
<Seo title={partTitle} description={partTitle} lang="en-US" />
|
||||
|
||||
<PartCell
|
||||
userName={userName}
|
||||
partTitle={partTitle}
|
||||
currentUserId={currentUser?.sub}
|
||||
/>
|
||||
</MainLayout>
|
||||
)
|
||||
}
|
||||
|
||||
export default PartPage
|
||||
7
web/src/pages/PartPage/PartPage.stories.js
Normal file
7
web/src/pages/PartPage/PartPage.stories.js
Normal file
@@ -0,0 +1,7 @@
|
||||
import PartPage from './PartPage'
|
||||
|
||||
export const generated = () => {
|
||||
return <PartPage />
|
||||
}
|
||||
|
||||
export default { title: 'Pages/PartPage' }
|
||||
11
web/src/pages/PartPage/PartPage.test.js
Normal file
11
web/src/pages/PartPage/PartPage.test.js
Normal file
@@ -0,0 +1,11 @@
|
||||
import { render } from '@redwoodjs/testing'
|
||||
|
||||
import PartPage from './PartPage'
|
||||
|
||||
describe('PartPage', () => {
|
||||
it('renders successfully', () => {
|
||||
expect(() => {
|
||||
render(<PartPage />)
|
||||
}).not.toThrow()
|
||||
})
|
||||
})
|
||||
Reference in New Issue
Block a user