mirror of
https://github.com/uetchy/namae.git
synced 2025-07-01 22:10:04 +09:00
31 lines
827 B
JavaScript
31 lines
827 B
JavaScript
import React from 'react'
|
|
import { useTranslation } from 'react-i18next'
|
|
import { FaJsSquare } from 'react-icons/fa'
|
|
|
|
import { Card, Repeater, DedicatedAvailability } from '../Cards'
|
|
|
|
export default function JsOrgCard({ query }) {
|
|
const { t } = useTranslation()
|
|
const lowerCase = query.toLowerCase()
|
|
|
|
const names = [lowerCase]
|
|
|
|
return (
|
|
<Card title={t('providers.jsorg')}>
|
|
<Repeater items={names}>
|
|
{(name) => (
|
|
<DedicatedAvailability
|
|
name={`${name}.js.org`}
|
|
service="dns"
|
|
message="Go to js.org repository"
|
|
link="https://github.com/js-org/js.org"
|
|
messageIfTaken={`Go to ${name}.js.org`}
|
|
linkIfTaken={`https://${name}.js.org`}
|
|
icon={<FaJsSquare />}
|
|
/>
|
|
)}
|
|
</Repeater>
|
|
</Card>
|
|
)
|
|
}
|