feat: add domain role translate

This commit is contained in:
Maël Gangloff 2024-07-28 21:35:38 +02:00
parent c3fe822f41
commit c78843a3d2
No known key found for this signature in database
GPG Key ID: 11FDC81C24A7F629
2 changed files with 79 additions and 20 deletions

View File

@ -40,6 +40,21 @@ type FieldType = {
ldhName: string ldhName: string
} }
const domainRole = {
registrant: () => t`Registrant`,
technical: () => t`Technical`,
administrative: () => t`Administrative`,
abuse: () => t`Abuse`,
billing: () => t`Billing`,
registrar: () => t`Registrar`,
reseller: () => t`Reseller`,
sponsor: () => t`Sponsor`,
proxy: () => t`Proxy`,
notifications: () => t`Notifications`,
noc: () => t`Noc`
}
export default function DomainSearchPage() { export default function DomainSearchPage() {
const [domain, setDomain] = useState<Domain | null>() const [domain, setDomain] = useState<Domain | null>()
@ -178,7 +193,7 @@ export default function DomainSearchPage() {
title={e.entity.handle} title={e.entity.handle}
description={name} description={name}
/> />
<div>{e.roles.join(', ')}</div> <div>{e.roles.map((r) => Object.keys(domainRole).includes(r) ? domainRole[r as keyof typeof domainRole]() : r).join(', ')}</div>
</List.Item> </List.Item>
}} }}
/> />

View File

@ -3,61 +3,105 @@ msgstr ""
"Content-Type: text/plain; charset=utf-8\n" "Content-Type: text/plain; charset=utf-8\n"
"Plural-Forms: nplurals=2; plural=(n!=1);\n" "Plural-Forms: nplurals=2; plural=(n!=1);\n"
#: assets/pages/search/DomainSearchPage.tsx:45
msgid "Registrant"
msgstr ""
#: assets/pages/search/DomainSearchPage.tsx:46
msgid "Technical"
msgstr ""
#: assets/pages/search/DomainSearchPage.tsx:47
msgid "Administrative"
msgstr ""
#: assets/pages/search/DomainSearchPage.tsx:48
msgid "Abuse"
msgstr ""
#: assets/pages/search/DomainSearchPage.tsx:49
msgid "Billing"
msgstr ""
#: assets/pages/search/DomainSearchPage.tsx:50
msgid "Registrar"
msgstr ""
#: assets/pages/search/DomainSearchPage.tsx:51
msgid "Reseller"
msgstr ""
#: assets/pages/search/DomainSearchPage.tsx:52 #: assets/pages/search/DomainSearchPage.tsx:52
msgid "Sponsor"
msgstr ""
#: assets/pages/search/DomainSearchPage.tsx:53
msgid "Proxy"
msgstr ""
#: assets/pages/search/DomainSearchPage.tsx:54
msgid "Notifications"
msgstr ""
#: assets/pages/search/DomainSearchPage.tsx:55
msgid "Noc"
msgstr ""
#: assets/pages/search/DomainSearchPage.tsx:67
msgid "Found !" msgid "Found !"
msgstr "" msgstr ""
#: assets/pages/search/DomainSearchPage.tsx:56 #: assets/pages/search/DomainSearchPage.tsx:71
#: assets/pages/tracking/WatchlistPage.tsx:89 #: assets/pages/tracking/WatchlistPage.tsx:89
msgid "An error occurred" msgid "An error occurred"
msgstr "" msgstr ""
#: assets/pages/search/DomainSearchPage.tsx:61 #: assets/pages/search/DomainSearchPage.tsx:76
msgid "Domain finder" msgid "Domain finder"
msgstr "" msgstr ""
#: assets/pages/LoginPage.tsx:53 #: assets/pages/LoginPage.tsx:53
#: assets/pages/LoginPage.tsx:61 #: assets/pages/LoginPage.tsx:61
#: assets/pages/search/DomainSearchPage.tsx:74 #: assets/pages/search/DomainSearchPage.tsx:89
#: assets/pages/tracking/WatchlistPage.tsx:135 #: assets/pages/tracking/WatchlistPage.tsx:135
#: assets/pages/tracking/WatchlistPage.tsx:195 #: assets/pages/tracking/WatchlistPage.tsx:195
#: assets/pages/tracking/WatchlistPage.tsx:205 #: assets/pages/tracking/WatchlistPage.tsx:205
msgid "Required" msgid "Required"
msgstr "" msgstr ""
#: assets/pages/search/DomainSearchPage.tsx:77 #: assets/pages/search/DomainSearchPage.tsx:92
#: assets/pages/tracking/WatchlistPage.tsx:138 #: assets/pages/tracking/WatchlistPage.tsx:138
msgid "This domain name does not appear to be valid" msgid "This domain name does not appear to be valid"
msgstr "" msgstr ""
#: assets/pages/search/DomainSearchPage.tsx:193 #: assets/pages/search/DomainSearchPage.tsx:208
msgid "" msgid ""
"Although the domain exists in my database, it has been deleted from the " "Although the domain exists in my database, it has been deleted from the "
"WHOIS by its registrar." "WHOIS by its registrar."
msgstr "" msgstr ""
#: assets/App.tsx:114 #: assets/App.tsx:114
#: assets/pages/info/TldPage.tsx:64 #: assets/pages/info/TldPage.tsx:65
msgid "TLD" msgid "TLD"
msgstr "" msgstr ""
#: assets/pages/info/TldPage.tsx:71 #: assets/pages/info/TldPage.tsx:72
msgid "Flag" msgid "Flag"
msgstr "" msgstr ""
#: assets/pages/info/TldPage.tsx:75 #: assets/pages/info/TldPage.tsx:76
msgid "Country" msgid "Country"
msgstr "" msgstr ""
#: assets/pages/info/TldPage.tsx:81 #: assets/pages/info/TldPage.tsx:82
msgid "Registry Operator" msgid "Registry Operator"
msgstr "" msgstr ""
#: assets/pages/info/TldPage.tsx:106 #: assets/pages/info/TldPage.tsx:107
msgid "This page presents all active TLDs in the root zone database." msgid "This page presents all active TLDs in the root zone database."
msgstr "" msgstr ""
#: assets/pages/info/TldPage.tsx:109 #: assets/pages/info/TldPage.tsx:110
msgid "" msgid ""
"IANA provides the list of currently active TLDs, regardless of their type, " "IANA provides the list of currently active TLDs, regardless of their type, "
"and ICANN provides the list of gTLDs.\n" "and ICANN provides the list of gTLDs.\n"
@ -69,42 +113,42 @@ msgid ""
"At the same time, the list of root RDAP servers is updated." "At the same time, the list of root RDAP servers is updated."
msgstr "" msgstr ""
#: assets/pages/info/TldPage.tsx:120 #: assets/pages/info/TldPage.tsx:121
msgid "Sponsored Top-Level-Domains" msgid "Sponsored Top-Level-Domains"
msgstr "" msgstr ""
#: assets/pages/info/TldPage.tsx:122 #: assets/pages/info/TldPage.tsx:123
msgid "" msgid ""
"Top-level domains sponsored by specific organizations that set rules for " "Top-level domains sponsored by specific organizations that set rules for "
"registration and use, often related to particular interest groups or " "registration and use, often related to particular interest groups or "
"industries." "industries."
msgstr "" msgstr ""
#: assets/pages/info/TldPage.tsx:129 #: assets/pages/info/TldPage.tsx:130
msgid "Generic Top-Level-Domains" msgid "Generic Top-Level-Domains"
msgstr "" msgstr ""
#: assets/pages/info/TldPage.tsx:131 #: assets/pages/info/TldPage.tsx:132
msgid "" msgid ""
"Generic top-level domains open to everyone, not restricted by specific " "Generic top-level domains open to everyone, not restricted by specific "
"criteria, representing various themes or industries." "criteria, representing various themes or industries."
msgstr "" msgstr ""
#: assets/pages/info/TldPage.tsx:138 #: assets/pages/info/TldPage.tsx:139
msgid "Brand Generic Top-Level-Domains" msgid "Brand Generic Top-Level-Domains"
msgstr "" msgstr ""
#: assets/pages/info/TldPage.tsx:140 #: assets/pages/info/TldPage.tsx:141
msgid "" msgid ""
"Generic top-level domains associated with specific brands, allowing " "Generic top-level domains associated with specific brands, allowing "
"companies to use their own brand names as domains." "companies to use their own brand names as domains."
msgstr "" msgstr ""
#: assets/pages/info/TldPage.tsx:147 #: assets/pages/info/TldPage.tsx:148
msgid "Country-Code Top-Level-Domains" msgid "Country-Code Top-Level-Domains"
msgstr "" msgstr ""
#: assets/pages/info/TldPage.tsx:149 #: assets/pages/info/TldPage.tsx:150
msgid "" msgid ""
"Top-level domains based on country codes, identifying websites according to " "Top-level domains based on country codes, identifying websites according to "
"their country of origin." "their country of origin."