mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-17 16:44:49 -04:00
Split user.ts into auth.ts and me.ts (#113)
Split user.ts into auth.ts and me.ts
This commit is contained in:
parent
1fa8c8ac53
commit
db5bec7000
9 changed files with 53 additions and 51 deletions
|
@ -1,7 +1,7 @@
|
|||
import { Trans, useTranslation } from 'react-i18next'
|
||||
import { Alert, Button, Card, Form } from 'react-bootstrap'
|
||||
import React, { FormEvent, useState } from 'react'
|
||||
import { doEmailLogin } from '../../../../../api/user'
|
||||
import { Alert, Button, Card, Form } from 'react-bootstrap'
|
||||
import { Trans, useTranslation } from 'react-i18next'
|
||||
import { doEmailLogin } from '../../../../../api/auth'
|
||||
import { getAndSetUser } from '../../../../../utils/apiUtils'
|
||||
|
||||
export const ViaEMail: React.FC = () => {
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
import React, { FormEvent, useState } from 'react'
|
||||
import { Alert, Button, Card, Form } from 'react-bootstrap'
|
||||
|
||||
import { Trans, useTranslation } from 'react-i18next'
|
||||
import { Alert, Button, Card, Form } from 'react-bootstrap'
|
||||
import { doLdapLogin } from '../../../../../api/user'
|
||||
import { getAndSetUser } from '../../../../../utils/apiUtils'
|
||||
import { useSelector } from 'react-redux'
|
||||
import { doLdapLogin } from '../../../../../api/auth'
|
||||
import { ApplicationState } from '../../../../../redux'
|
||||
import { getAndSetUser } from '../../../../../utils/apiUtils'
|
||||
|
||||
export const ViaLdap: React.FC = () => {
|
||||
const { t } = useTranslation()
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import React, { FormEvent, useState } from 'react'
|
||||
import { Trans, useTranslation } from 'react-i18next'
|
||||
import { Alert, Button, Card, Form } from 'react-bootstrap'
|
||||
import { doOpenIdLogin } from '../../../../../api/user'
|
||||
import { Trans, useTranslation } from 'react-i18next'
|
||||
import { doOpenIdLogin } from '../../../../../api/auth'
|
||||
import { getAndSetUser } from '../../../../../utils/apiUtils'
|
||||
|
||||
export const ViaOpenId: React.FC = () => {
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import React, { Fragment, useEffect, useRef, useState } from 'react'
|
||||
import { Button, Card, Modal } from 'react-bootstrap'
|
||||
import { Trans, useTranslation } from 'react-i18next'
|
||||
import { deleteUser } from '../../../../../api/user'
|
||||
import { deleteUser } from '../../../../../api/me'
|
||||
import { ForkAwesomeIcon } from '../../../../../fork-awesome/fork-awesome-icon'
|
||||
import { clearUser } from '../../../../../redux/user/methods'
|
||||
import { getBackendUrl } from '../../../../../utils/apiUtils'
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import React, { ChangeEvent, FormEvent, useState } from 'react'
|
||||
import { Button, Card, Form } from 'react-bootstrap'
|
||||
import { Trans, useTranslation } from 'react-i18next'
|
||||
import { changePassword } from '../../../../../api/user'
|
||||
import { changePassword } from '../../../../../api/me'
|
||||
|
||||
export const ProfileChangePassword: React.FC = () => {
|
||||
useTranslation()
|
||||
|
|
|
@ -2,7 +2,7 @@ import React, { ChangeEvent, FormEvent, useState } from 'react'
|
|||
import { Button, Card, Form } from 'react-bootstrap'
|
||||
import { Trans, useTranslation } from 'react-i18next'
|
||||
import { useSelector } from 'react-redux'
|
||||
import { updateDisplayName } from '../../../../../api/user'
|
||||
import { updateDisplayName } from '../../../../../api/me'
|
||||
import { ApplicationState } from '../../../../../redux'
|
||||
import { getAndSetUser } from '../../../../../utils/apiUtils'
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue