mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-06-01 23:58:58 -04:00
Switch the base framework from Create React App to Next.JS
Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>
This commit is contained in:
parent
a979b6ffdd
commit
77a60c6c48
361 changed files with 5130 additions and 9605 deletions
27
src/pages/p/[id].tsx
Normal file
27
src/pages/p/[id].tsx
Normal file
|
@ -0,0 +1,27 @@
|
|||
/*
|
||||
* SPDX-FileCopyrightText: 2021 The HedgeDoc developers (see AUTHORS file)
|
||||
*
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
import React from 'react'
|
||||
import { useLoadNoteFromServer } from '../../components/editor-page/hooks/useLoadNoteFromServer'
|
||||
import { ShowIf } from '../../components/common/show-if/show-if'
|
||||
import { EditorToRendererCommunicatorContextProvider } from '../../components/editor-page/render-context/editor-to-renderer-communicator-context-provider'
|
||||
import { SlideShowPageContent } from '../../components/slide-show-page/slide-show-page-content'
|
||||
import { useDocumentTitleWithNoteTitle } from '../../hooks/common/use-document-title-with-note-title'
|
||||
|
||||
export const SlideShowPage: React.FC = () => {
|
||||
const [error, loading] = useLoadNoteFromServer()
|
||||
useDocumentTitleWithNoteTitle()
|
||||
|
||||
return (
|
||||
<EditorToRendererCommunicatorContextProvider>
|
||||
<ShowIf condition={!error && !loading}>
|
||||
<SlideShowPageContent />
|
||||
</ShowIf>
|
||||
</EditorToRendererCommunicatorContextProvider>
|
||||
)
|
||||
}
|
||||
|
||||
export default SlideShowPage
|
Loading…
Add table
Add a link
Reference in a new issue