Skip to content

Commit

Permalink
Feature: PIN-4104 - Useful links section added in eservice details (P…
Browse files Browse the repository at this point in the history
…roviderEServiceTechnicalInfoDrawer) (#617)

* Added constants link

* Added new useful links strings

* Added useful links in ProviderEServiceTechnicalInfoDrawer
  • Loading branch information
alten-dturus authored Oct 23, 2023
1 parent cfa7115 commit 158136e
Show file tree
Hide file tree
Showing 4 changed files with 47 additions and 2 deletions.
2 changes: 2 additions & 0 deletions src/config/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ export const assistanceLink = 'mailto:[email protected]'
export const attributesHelpLink = `${documentationLink}/manuale-operativo/attributi`
export const verifyVoucherGuideLink = `${documentationLink}/manuale-operativo/utilizzare-i-voucher`
export const manageEServiceGuideLink = `${documentationLink}/manuale-operativo/e-service`
export const implementAndManageEServiceGuideLink = `${documentationLink}/come-integrare-i-propri-servizi-su-pdnd-interoperabilita`
export const voucherVerificationGuideLink = `${documentationLink}/manuale-operativo/utilizzare-i-voucher#verifica-di-un-voucher-da-parte-di-un-erogatore-di-e-service`
export const purposeUpgradeGuideLink = `${documentationLink}/manuale-operativo/finalita`
export const agreementUpgradeGuideLink = `${documentationLink}/manuale-operativo/richieste-di-fruizione#fruitore-aggiornare-una-richiesta-di-fruizione`
export const clientKeyGuideLink = `${documentationLink}/manuale-operativo/client-e-materiale-crittografico`
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,13 @@ import { Drawer } from '@/components/shared/Drawer'
import { Stack } from '@mui/material'
import { InformationContainer } from '@pagopa/interop-fe-commons'
import { useTranslation } from 'react-i18next'
import { IconLink } from '@/components/shared/IconLink'
import {
implementAndManageEServiceGuideLink,
voucherVerificationGuideLink,
} from '@/config/constants'
import { WELL_KNOWN_URLS } from '@/config/env'
import LaunchIcon from '@mui/icons-material/Launch'

type ProviderEServiceTechnicalInfoDrawerProps = {
isOpen: boolean
Expand Down Expand Up @@ -57,6 +64,36 @@ export const ProviderEServiceTechnicalInfoDrawer: React.FC<
content={t(`mode.value.${descriptor.eservice.mode}`)}
direction="column"
/>

<InformationContainer
label={t('usefulLinks.title')}
content={
<Stack alignItems="start" mt={1} spacing={0.5}>
<IconLink
href={implementAndManageEServiceGuideLink}
target="_blank"
startIcon={<LaunchIcon fontSize="small" />}
>
{t('usefulLinks.implementAndManageEService')}
</IconLink>
<IconLink
href={voucherVerificationGuideLink}
target="_blank"
startIcon={<LaunchIcon fontSize="small" />}
>
{t('usefulLinks.verifyVoucher')}
</IconLink>
<IconLink
href={WELL_KNOWN_URLS[0]}
target="_blank"
startIcon={<LaunchIcon fontSize="small" />}
>
{t('usefulLinks.wellKnown')}
</IconLink>
</Stack>
}
direction="column"
/>
</Stack>
</Drawer>
)
Expand Down
5 changes: 4 additions & 1 deletion src/static/locales/en/eservice.json
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,10 @@
"documentation": "Documentation",
"usefulLinks": {
"title": "Useful links",
"integrateEService": "How do I integrate an e-service?"
"integrateEService": "How do I integrate an e-service?",
"implementAndManageEService": "How do I implement and manage an e-service?",
"verifyVoucher": "How do I verify a consumer's voucher?",
"wellKnown": "URL .well-known"
}
},
"producerContactsInfoDrawer": {
Expand Down
5 changes: 4 additions & 1 deletion src/static/locales/it/eservice.json
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,10 @@
"documentation": "Documentazione",
"usefulLinks": {
"title": "Link utili",
"integrateEService": "Come faccio a integrare un e-service?"
"integrateEService": "Come faccio a integrare un e-service?",
"implementAndManageEService": "Come implemento e gestisco un e-service?",
"verifyVoucher": "Come faccio a verificare il voucher di un fruitore?",
"wellKnown": "URL .well-known"
}
},
"producerContactsInfoDrawer": {
Expand Down

0 comments on commit 158136e

Please sign in to comment.