fix: wrong fonts on the operator info pages (#430)
* fix: fix bug when loading the contact info page with no phone configured or no country configured in locales style: fixed contact info styles style: fixes on the terms & conditions styles * fix: re-add H4 style after merge fix: code styling
This commit is contained in:
parent
3c0f4ec194
commit
02474a0a6d
4 changed files with 41 additions and 32 deletions
|
|
@ -13,14 +13,7 @@ import PromptWhenDirty from 'src/components/PromptWhenDirty'
|
||||||
import { Link } from 'src/components/buttons'
|
import { Link } from 'src/components/buttons'
|
||||||
import Switch from 'src/components/inputs/base/Switch'
|
import Switch from 'src/components/inputs/base/Switch'
|
||||||
import { TextInput, NumberInput } from 'src/components/inputs/formik'
|
import { TextInput, NumberInput } from 'src/components/inputs/formik'
|
||||||
import {
|
import { P, H4, Info3, Label1, Label2, Label3 } from 'src/components/typography'
|
||||||
P,
|
|
||||||
Info2,
|
|
||||||
Info3,
|
|
||||||
Label1,
|
|
||||||
Label2,
|
|
||||||
Label3
|
|
||||||
} from 'src/components/typography'
|
|
||||||
import { ReactComponent as EditIcon } from 'src/styling/icons/action/edit/enabled.svg'
|
import { ReactComponent as EditIcon } from 'src/styling/icons/action/edit/enabled.svg'
|
||||||
import { ReactComponent as WarningIcon } from 'src/styling/icons/warning-icon/comet.svg'
|
import { ReactComponent as WarningIcon } from 'src/styling/icons/warning-icon/comet.svg'
|
||||||
import { fontSize5 } from 'src/styling/variables'
|
import { fontSize5 } from 'src/styling/variables'
|
||||||
|
|
@ -174,7 +167,7 @@ const ContactInfo = () => {
|
||||||
locale.country
|
locale.country
|
||||||
).formatInternational()
|
).formatInternational()
|
||||||
: '',
|
: '',
|
||||||
component: TextInput
|
component: NumberInput
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: 'email',
|
name: 'email',
|
||||||
|
|
@ -214,11 +207,10 @@ const ContactInfo = () => {
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
<div className={classes.header}>
|
<div className={classes.rowWrapper}>
|
||||||
<Info2>Contact information</Info2>
|
<H4>Contact information</H4>
|
||||||
</div>
|
</div>
|
||||||
<div className={classes.section}>
|
<div className={classes.rowWrapper}>
|
||||||
<div className={classes.switchRow}>
|
|
||||||
<P>Info card enabled?</P>
|
<P>Info card enabled?</P>
|
||||||
<div className={classes.switch}>
|
<div className={classes.switch}>
|
||||||
<Switch
|
<Switch
|
||||||
|
|
@ -232,8 +224,9 @@ const ContactInfo = () => {
|
||||||
<Label2>{info.active ? 'Yes' : 'No'}</Label2>
|
<Label2>{info.active ? 'Yes' : 'No'}</Label2>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div className={classes.header}>
|
<div className={classes.section}>
|
||||||
<Info2>Info card</Info2>
|
<div className={classes.rowWrapper}>
|
||||||
|
<H4>Info card</H4>
|
||||||
{!editing && (
|
{!editing && (
|
||||||
<div className={classes.transparentButton}>
|
<div className={classes.transparentButton}>
|
||||||
<button onClick={() => setEditing(true)}>
|
<button onClick={() => setEditing(true)}>
|
||||||
|
|
|
||||||
|
|
@ -77,6 +77,22 @@ const contactInfoStyles = {
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
flexDirection: 'row',
|
flexDirection: 'row',
|
||||||
paddingLeft: 4
|
paddingLeft: 4
|
||||||
|
},
|
||||||
|
rowWrapper: {
|
||||||
|
display: 'flex',
|
||||||
|
alignItems: 'center',
|
||||||
|
position: 'relative',
|
||||||
|
flex: 'wrap'
|
||||||
|
},
|
||||||
|
transparentButton: {
|
||||||
|
'& > *': {
|
||||||
|
margin: 'auto 12px'
|
||||||
|
},
|
||||||
|
'& button': {
|
||||||
|
border: 'none',
|
||||||
|
backgroundColor: 'transparent',
|
||||||
|
cursor: 'pointer'
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,7 @@ import PromptWhenDirty from 'src/components/PromptWhenDirty'
|
||||||
import { Link } from 'src/components/buttons'
|
import { Link } from 'src/components/buttons'
|
||||||
import { Switch } from 'src/components/inputs'
|
import { Switch } from 'src/components/inputs'
|
||||||
import { TextInput } from 'src/components/inputs/formik'
|
import { TextInput } from 'src/components/inputs/formik'
|
||||||
import { Info2, Info3, Label2, Label3 } from 'src/components/typography'
|
import { H4, Info2, Info3, Label2, Label3 } from 'src/components/typography'
|
||||||
import { ReactComponent as EditIcon } from 'src/styling/icons/action/edit/enabled.svg'
|
import { ReactComponent as EditIcon } from 'src/styling/icons/action/edit/enabled.svg'
|
||||||
import { fromNamespace, toNamespace, namespaces } from 'src/utils/config'
|
import { fromNamespace, toNamespace, namespaces } from 'src/utils/config'
|
||||||
|
|
||||||
|
|
@ -191,8 +191,8 @@ const TermsConditions = () => {
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
<div className={classes.header}>
|
<div className={classes.rowWrapper}>
|
||||||
<Info2>Terms & Conditions</Info2>
|
<H4>Terms & Conditions</H4>
|
||||||
</div>
|
</div>
|
||||||
<div className={classes.section}>
|
<div className={classes.section}>
|
||||||
<div className={classes.enable}>
|
<div className={classes.enable}>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue