Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

merge feature/20240918-2 into develop #92

Merged
merged 6 commits into from
Sep 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions src/layouts/main/footer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import { RouterLink } from 'src/routes/components'

import { useTranslate } from 'src/locales'
import { _socials } from 'src/app/api/_data/_mock'
import { BOT_WAPP_URL, CONTACT_EMAIL } from 'src/config-global'

import Logo from 'src/components/logo'
import Iconify from 'src/components/iconify'
Expand All @@ -22,18 +23,18 @@ import Iconify from 'src/components/iconify'

export default function Footer() {
const pathname = usePathname()

const { t } = useTranslate()

const homePage = pathname === '/'
const contactUsUrl = BOT_WAPP_URL.replaceAll('MESSAGE', t('home.common.contact-us-wapp-msg'))

const LINKS = [
{
headline: 'ChatterPay',
children: [
{ name: t('home.footer.links.about-us'), href: '#' },
{ name: t('home.footer.links.contact-us'), href: '#' },
{ name: t('home.footer.links.faqs'), href: '#' }
{ name: t('home.footer.links.contact-us'), href: contactUsUrl },
{ name: t('home.footer.links.faqs'), href: '/' }
]
},
{
Expand All @@ -45,7 +46,7 @@ export default function Footer() {
},
{
headline: t('home.footer.links.contact'),
children: [{ name: '[email protected]', href: '#' }]
children: [{ name: CONTACT_EMAIL, href: `mailto:${CONTACT_EMAIL}` }]
}
]

Expand Down
9 changes: 5 additions & 4 deletions src/locales/langs/br.json
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,7 @@
},
"contact": {
"title": "7. Contato",
"description": "Se você tiver dúvidas sobre esta Política de Privacidade, não hesite em nos contatar em",
"email": "[email protected]"
"description": "Se você tiver dúvidas sobre esta Política de Privacidade, não hesite em nos contatar em"
},
"last_updated": "Última atualização:",
"date": "Setembro 2024"
Expand All @@ -94,7 +93,8 @@
"need-help": "Precisa de ajuda?"
},
"common": {
"contact-us": "Contate-nos"
"contact-us": "Contate-nos",
"contact-us-wapp-msg": "Oi! Quero saber mais sobre o Chatterpay!"
},
"footer": {
"description": "Transfira criptomoedas facilmente pelo WhatsApp usando nossa plataforma Web3.",
Expand Down Expand Up @@ -270,7 +270,8 @@
"terms-of-service": "Termos de Serviço",
"privacy-policy": "Política de Privacidade",
"by-signing": "Ao me inscrever, concordo com os",
"and": "e"
"and": "e",
"wapp-msg": "Oi, quero me registrar no Chatterpay!"
},
"balances": {
"title": "Saldo Estimado",
Expand Down
9 changes: 5 additions & 4 deletions src/locales/langs/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@
"need-help": "Need help?"
},
"common": {
"contact-us": "Contact Us"
"contact-us": "Contact Us",
"contact-us-wapp-msg": "Hi! I want to know more about Chatterpay!"
},
"footer": {
"description": "Transfer crypto easily through WhatsApp using our Web3 platform.",
Expand Down Expand Up @@ -236,8 +237,7 @@
},
"contact": {
"title": "7. Contact",
"description": "If you have any questions about this Privacy Policy, feel free to contact us at",
"email": "[email protected]"
"description": "If you have any questions about this Privacy Policy, feel free to contact us at"
},
"last_updated": "Last updated:",
"date": "September 2024"
Expand Down Expand Up @@ -270,7 +270,8 @@
"terms-of-service": "Terms of Service",
"privacy-policy": "Privacy Policy",
"by-signing": "By signing up, I agree to",
"and": "and"
"and": "and",
"wapp-msg": "Hi, i want to register in chatterpay!"
},
"balances": {
"title": "Estimated Balance",
Expand Down
9 changes: 5 additions & 4 deletions src/locales/langs/es.json
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,7 @@
},
"contact": {
"title": "7. Contacto",
"description": "Si tienes preguntas sobre esta Política de Privacidad, no dudes en contactarnos en",
"email": "[email protected]"
"description": "Si tienes preguntas sobre esta Política de Privacidad, no dudes en contactarnos en"
},
"last_updated": "Última actualización:",
"date": "Septiembre 2024"
Expand All @@ -94,7 +93,8 @@
"need-help": "¿Necesita ayuda?"
},
"common": {
"contact-us": "Contáctanos"
"contact-us": "Contáctanos",
"contact-us-wapp-msg": "¡Hola! Quiero conocer más sobre Chatterpay!"
},
"footer": {
"description": "Transfiere criptomonedas fácilmente a través de WhatsApp utilizando nuestra plataforma Web3.",
Expand Down Expand Up @@ -270,7 +270,8 @@
"terms-of-service": "Términos de Servicio",
"privacy-policy": "Política de Privacidad",
"by-signing": "Al registrarme, acepto los",
"and": "y"
"and": "y",
"wapp-msg": "Hola, quiero registrarme en Chatterpay!"
},
"balances": {
"title": "Balance Estimado",
Expand Down
9 changes: 4 additions & 5 deletions src/sections/auth/jwt/jwt-register-view.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,8 @@ export default function JwtRegisterView() {

const onSubmit = handleSubmit(async (data) => {
try {
// await register?.(data.email, data.password, data.firstName, data.lastName)
// router.push(returnTo || PATH_AFTER_LOGIN)
router.push(BOT_WAPP_URL)
const registerUrl = BOT_WAPP_URL.replaceAll('MESSAGE', t('register.wapp-msg'))
router.push(registerUrl)
} catch (error) {
console.error(error)
reset()
Expand Down Expand Up @@ -98,13 +97,13 @@ export default function JwtRegisterView() {
}}
>
{t('register.by-signing')} {` `}
<Link underline='always' color='text.primary'>
<Link underline='always' color='text.primary' href={paths.terms}>
{t('register.terms-of-service')}
{` `}
</Link>
{t('register.and')}
{` `}
<Link underline='always' color='text.primary'>
<Link underline='always' color='text.primary' href={paths.policy}>
{t('register.privacy-policy')}
</Link>
.
Expand Down
6 changes: 3 additions & 3 deletions src/sections/banking/banking-balances.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ export default function BankingBalances({
const open = Boolean(anchorEl)
const id = open ? 'wallet-links-popover' : undefined

const sendReciveMsg = BOT_WAPP_URL.replaceAll('MESSAGE', t('balances.wapp-msg'))
const sendReciveUrl = BOT_WAPP_URL.replaceAll('MESSAGE', t('balances.wapp-msg'))

const handleCurrencyChange = (event: SelectChangeEvent<CurrencyKey>) => {
setSelectedCurrency(event.target.value as CurrencyKey)
Expand Down Expand Up @@ -124,7 +124,7 @@ export default function BankingBalances({
variant='contained'
color='primary'
startIcon={<Iconify icon='eva:diagonal-arrow-left-down-fill' />}
onClick={() => window.open(sendReciveMsg, '_blank')}
onClick={() => window.open(sendReciveUrl, '_blank')}
>
{t('balances.deposit')}
</Button>
Expand All @@ -135,7 +135,7 @@ export default function BankingBalances({
variant='outlined'
color='inherit'
startIcon={<Iconify icon='eva:diagonal-arrow-right-up-fill' />}
onClick={() => window.open(sendReciveMsg, '_blank')}
onClick={() => window.open(sendReciveUrl, '_blank')}
>
{t('balances.send')}
</Button>
Expand Down
106 changes: 3 additions & 103 deletions src/sections/home/home-all-features.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import Typography from '@mui/material/Typography'
import { useResponsive } from 'src/hooks/use-responsive'

import { useTranslate } from 'src/locales'
import { BOT_WAPP_URL } from 'src/config-global'

import { varFade } from 'src/components/animate'

Expand All @@ -19,109 +20,8 @@ import { varFade } from 'src/components/animate'
export default function HomeAllFeatures() {
const mdUp = useResponsive('up', 'md')
const { t } = useTranslate()
const contactUsUrl = BOT_WAPP_URL.replaceAll('MESSAGE', t('home.common.contact-us-wapp-msg'))

/*
const theme = useTheme()


const renderSection1 = (
<Box sx={{mt: 4, ml: 4}}>
<Stack direction="row" alignItems="center" spacing={2} sx={{ marginBottom: 2 }}>
<m.div variants={varFade().inUp}>
<Avatar src={_mock.image.avatar(2)} alt='Avatar 1' />
</m.div>
<m.div variants={varFade().inUp}>
<Iconify sx={{ mx: 'auto', width: 48, height: 48 }} icon='/assets/icons/home/ic_ethereum.svg' />
</m.div>
<m.div variants={varFade().inUp}>
<Avatar src={_mock.image.avatar(3)} alt='Avatar 2' />
</m.div>
</Stack>
</Box>
)

const renderSection2 = (
<Box sx={{mt: 4, ml: 4}}>
<Stack direction="row" alignItems="center" spacing={2} sx={{ marginBottom: 2 }}>
<m.div variants={varFade().inUp}>
<Avatar src={_mock.image.avatar(2)} alt='Avatar 1' />
</m.div>
<m.div variants={varFade().inUp}>
<Iconify sx={{ mx: 'auto', width: 48, height: 48 }} icon='/assets/icons/home/ic_ethereum.svg' />
</m.div>

</Stack>
</Box>
)

const renderCarouselSection = (index: number) => {
switch (index) {
case 0:
return renderSection1
case 1:
return renderSection2
default:
return renderSection1
}
}

const carousel = useCarousel({
fade: true,
arrows: true,
speed: 500,
...CarouselDots({
sx: {
right: 16,
bottom: 16,
position: 'absolute',
color: 'primary.light'
}
})
})

const renderContent = (
<Box
sx={{
...bgGradient({
color: alpha(theme.palette.grey[400], 0.3),
imgUrl: '/assets/background/overlay_2.jpg'
}),
height: '100%',
width: '100%',
borderRadius: 2,
position: 'relative',
color: 'common.white',
'.slick-slider, .slick-list, .slick-track, .slick-slide > div': {
height: 1
},
'&:before, &:after': {
left: 0,
mx: 2.5,
right: 0,
zIndex: -2,
height: 200,
bottom: -16,
content: "''",
opacity: 0.16,
borderRadius: 2,
bgcolor: 'grey.500',
position: 'absolute'
},
'&:after': {
mx: 1,
bottom: -8,
opacity: 0.24
}
}}
>
<Carousel {...carousel.carouselSettings}>
{[...Array(6)].map((_, index) => (
<div key={index}>{renderCarouselSection(index)}</div>
))}
</Carousel>
</Box>
)
*/
const renderContet = (
<Box
sx={{
Expand Down Expand Up @@ -158,7 +58,7 @@ export default function HomeAllFeatures() {
variant='contained'
target='_blank'
rel='noopener'
href='/'
href={contactUsUrl}
>
{t('home.common.contact-us')}
</Button>
Expand Down
4 changes: 3 additions & 1 deletion src/sections/home/home-faq.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import Typography from '@mui/material/Typography'
import { Button, Accordion, AccordionSummary, AccordionDetails } from '@mui/material'

import { useTranslate } from 'src/locales'
import { BOT_WAPP_URL } from 'src/config-global'

import Iconify from 'src/components/iconify'
import { varFade, MotionViewport } from 'src/components/animate'
Expand All @@ -15,6 +16,7 @@ import { varFade, MotionViewport } from 'src/components/animate'

export default function HomeFaQ() {
const { t } = useTranslate()
const contactUsUrl = BOT_WAPP_URL.replaceAll('MESSAGE', t('home.common.contact-us-wapp-msg'))

const _faqs = Array.from({ length: 10 }, (_, index) => {
const id = Math.random().toString(36).substr(2, 9)
Expand Down Expand Up @@ -84,7 +86,7 @@ export default function HomeFaQ() {
variant='contained'
target='_blank'
rel='noopener'
href='#'
href={contactUsUrl}
>
{t('home.common.contact-us')}
</Button>
Expand Down
4 changes: 3 additions & 1 deletion src/sections/home/home-request-demo.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import { alpha, useTheme } from '@mui/material/styles'
import { useResponsive } from 'src/hooks/use-responsive'

import { useTranslate } from 'src/locales'
import { BOT_WAPP_URL } from 'src/config-global'
import { bgGradient, textGradient } from 'src/theme/css'

import { varFade, MotionViewport } from 'src/components/animate'
Expand Down Expand Up @@ -53,6 +54,7 @@ export default function HomeRequestDemo() {
const theme = useTheme()
const mdUp = useResponsive('up', 'md')
const { t } = useTranslate()
const contactUsUrl = BOT_WAPP_URL.replaceAll('MESSAGE', t('home.common.contact-us-wapp-msg'))

const contactUsBtn = (
<m.div variants={varFade().inUp}>
Expand All @@ -62,7 +64,7 @@ export default function HomeRequestDemo() {
variant='contained'
target='_blank'
rel='noopener'
href='#'
href={contactUsUrl}
>
{t('home.common.contact-us')}
</Button>
Expand Down
Loading