fix(#2598): fixed auth page

keep-around/4734987790b7012fdad8799dc582ee3cb2df28bb
Rakov Roman 3 years ago
parent daeb0b1c06
commit 4734987790
  1. 7
      src/features/AuthServiceApp/components/Login/index.tsx
  2. 6
      src/features/AuthServiceApp/components/Registration/index.tsx
  3. 7
      src/features/CompanyInfo/index.tsx
  4. 2
      src/features/UserAccount/index.tsx
  5. 3
      src/pages/HighlightsPage/index.tsx

@ -1,6 +1,7 @@
import { T9n } from 'features/T9n'
import { ArrowLoader } from 'features/ArrowLoader'
import { RecoveryPopup } from 'features/AuthServiceApp/components/RecoveryPopup'
import { client } from 'features/AuthServiceApp/config/clients'
import { PAGES } from '../../config/pages'
import { LanguageSelect } from '../LanguageSelect'
@ -123,7 +124,11 @@ const Login = () => {
</Form>
<RecoveryPopup isModalOpen={isRecoveryPopupOpen} setIsModalOpen={setIsRecoveryPopupOpen} />
</CenterBlock>
<CompanyInfo textAlign='center' width='450px' />
<CompanyInfo
clientName={client.name}
textAlign='center'
width='450px'
/>
</Wrapper>
)
}

@ -138,7 +138,11 @@ const Registration = () => {
/>
</Form>
</CenterBlock>
<CompanyInfo textAlign='center' width='450px' />
<CompanyInfo
clientName={client.name}
textAlign='center'
width='450px'
/>
</Wrapper>
)
}

@ -4,7 +4,6 @@ import { T9n } from 'features/T9n'
import { useLexicsConfig } from 'features/LexicsStore'
import { PAGES } from 'config'
import { client } from 'config/clients'
import { ClientNames } from 'config/clients/types'
import {
@ -15,18 +14,20 @@ import {
import { lexics } from './config'
export type TCompanyInfo = {
clientName: ClientNames,
textAlign?: 'center' | 'left',
width?: string,
}
export const CompanyInfo = ({
clientName,
textAlign = 'left',
width = '100%',
}: TCompanyInfo) => {
useLexicsConfig(lexics)
const companyInfoContent = useMemo(() => {
switch (client.name) {
switch (clientName) {
case ClientNames.Facr:
return (
<Fragment>
@ -62,7 +63,7 @@ export const CompanyInfo = ({
</Fragment>
)
}
}, [])
}, [clientName])
return (
<CompanyInfoWrapper style={{ maxWidth: width, textAlign }}>

@ -106,7 +106,7 @@ const UserAccount = () => {
<Route path={`${PAGES.useraccount}/payment-history`}>
<PagePaymentsHistory />
</Route>
<CompanyInfo textAlign='left' />
<CompanyInfo clientName={client.name} textAlign='left' />
</ContentWrapper>
</Body>
{client.name !== 'instat' && <PoweredByInstat />}

@ -3,6 +3,7 @@ import { Link } from 'react-router-dom'
import { isMobileDevice } from 'config/userAgent'
import { PAGES } from 'config'
import { client } from 'config/clients'
import { isBoolean } from 'lodash'
@ -78,7 +79,7 @@ const HighlightsPage = () => {
</ScPrice>
</ScButton>
</ScButtonWrap>
<CompanyInfo textAlign='center' />
<CompanyInfo clientName={client.name} textAlign='center' />
<ChangeCardPopup
btnName='buy_subscription'
changeCardPopupOpen={isOpenPopupChangeCard}

Loading…
Cancel
Save