fix(frontend): reformat source files

Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>
This commit is contained in:
Tilman Vatteroth 2022-11-30 22:10:23 +01:00 committed by David Mehren
parent e260b77760
commit e390c0dd15
669 changed files with 1741 additions and 2354 deletions

View file

@ -3,9 +3,8 @@
*
* SPDX-License-Identifier: AGPL-3.0-only
*/
import { useMemo } from 'react'
import { useApplicationState } from './use-application-state'
import { useMemo } from 'react'
/**
* Calculates the app title with branding if set.

View file

@ -3,10 +3,9 @@
*
* SPDX-License-Identifier: AGPL-3.0-only
*/
import { useSelector } from 'react-redux'
import equal from 'fast-deep-equal'
import type { ApplicationState } from '../../redux/application-state'
import equal from 'fast-deep-equal'
import { useSelector } from 'react-redux'
/**
* Accesses the global application state to retrieve information.

View file

@ -3,13 +3,12 @@
*
* SPDX-License-Identifier: AGPL-3.0-only
*/
import { useEffect } from 'react'
import { useApplicationState } from './use-application-state'
import { DarkModePreference } from '../../redux/dark-mode/types'
import { isClientSideRendering } from '../../utils/is-client-side-rendering'
import { Logger } from '../../utils/logger'
import { useApplicationState } from './use-application-state'
import useMediaQuery from '@restart/hooks/useMediaQuery'
import { DarkModePreference } from '../../redux/dark-mode/types'
import { useEffect } from 'react'
const logger = new Logger('useApplyDarkMode')

View file

@ -3,7 +3,6 @@
*
* SPDX-License-Identifier: AGPL-3.0-only
*/
import { useRouter } from 'next/router'
import { useMemo } from 'react'

View file

@ -3,10 +3,9 @@
*
* SPDX-License-Identifier: AGPL-3.0-only
*/
import { useContext, useMemo } from 'react'
import { useRouter } from 'next/router'
import { baseUrlContext } from '../../components/common/base-url/base-url-context-provider'
import { useRouter } from 'next/router'
import { useContext, useMemo } from 'react'
export enum ORIGIN {
EDITOR,

View file

@ -3,7 +3,6 @@
*
* SPDX-License-Identifier: AGPL-3.0-only
*/
import { useEffect } from 'react'
/**

View file

@ -3,7 +3,6 @@
*
* SPDX-License-Identifier: AGPL-3.0-only
*/
import { useCallback, useState } from 'react'
/**

View file

@ -3,10 +3,9 @@
*
* SPDX-License-Identifier: AGPL-3.0-only
*/
import { DarkModePreference } from '../../redux/dark-mode/types'
import { useApplicationState } from './use-application-state'
import useMediaQuery from '@restart/hooks/useMediaQuery'
import { DarkModePreference } from '../../redux/dark-mode/types'
/**
* Uses the user settings and the browser preference to determine if dark mode should be used.

View file

@ -3,7 +3,6 @@
*
* SPDX-License-Identifier: AGPL-3.0-only
*/
import type { DependencyList, EffectCallback } from 'react'
import { useEffect, useState } from 'react'

View file

@ -3,7 +3,6 @@
*
* SPDX-License-Identifier: AGPL-3.0-only
*/
import { useApplicationState } from './use-application-state'
/**

View file

@ -3,10 +3,9 @@
*
* SPDX-License-Identifier: AGPL-3.0-only
*/
import { useTranslation } from 'react-i18next'
import { useApplicationState } from './use-application-state'
import { useMemo } from 'react'
import { useTranslation } from 'react-i18next'
/**
* Retrieves the title of the note or a placeholder text, if no title is set.

View file

@ -3,7 +3,6 @@
*
* SPDX-License-Identifier: AGPL-3.0-only
*/
import type { ChangeEvent } from 'react'
import { useCallback } from 'react'

View file

@ -3,7 +3,6 @@
*
* SPDX-License-Identifier: AGPL-3.0-only
*/
import { useRouter } from 'next/router'
import { useMemo } from 'react'

View file

@ -3,9 +3,8 @@
*
* SPDX-License-Identifier: AGPL-3.0-only
*/
import { useMemo } from 'react'
import { useApplicationState } from './use-application-state'
import { useMemo } from 'react'
/**
* Returns the markdown content from the global application state trimmed to the maximal note length and without the frontmatter lines.