mirror of
https://github.com/Xevion/rdap.git
synced 2026-01-31 02:25:22 -06:00
fix entity placeholder, pulse animate autodetected target, remove completed todo
This commit is contained in:
@@ -193,7 +193,7 @@ const LookupInput: FunctionComponent<LookupInputProps> = ({
|
|||||||
{selected == "auto" ? (
|
{selected == "auto" ? (
|
||||||
// If the detected type was provided, then notate which in parentheses. Compact object naming might be better in the future.
|
// If the detected type was provided, then notate which in parentheses. Compact object naming might be better in the future.
|
||||||
detectedType.isJust ? (
|
detectedType.isJust ? (
|
||||||
`Auto (${targetShortNames[detectedType.value]})`
|
<>Auto (<span className="animate-pulse">{targetShortNames[detectedType.value]}</span>)</>
|
||||||
) : (
|
) : (
|
||||||
objectNames["auto"]
|
objectNames["auto"]
|
||||||
)
|
)
|
||||||
|
|||||||
+1
-1
@@ -83,7 +83,7 @@ export const placeholders: Record<SimplifiedTargetType | "auto", string> = {
|
|||||||
auto: "A domain, an IP address, a TLD, an RDAP URL...",
|
auto: "A domain, an IP address, a TLD, an RDAP URL...",
|
||||||
ip: "192.168.0.1/16 or 2001:db8::/32",
|
ip: "192.168.0.1/16 or 2001:db8::/32",
|
||||||
autnum: "AS27594",
|
autnum: "AS27594",
|
||||||
entity: "ABC123-EXAMPLE",
|
entity: "OPS4-RIPE",
|
||||||
url: "https://rdap.org/domain/example.com",
|
url: "https://rdap.org/domain/example.com",
|
||||||
tld: ".dev",
|
tld: ".dev",
|
||||||
registrar: "9999",
|
registrar: "9999",
|
||||||
|
|||||||
@@ -757,7 +757,6 @@ export function createRDAPLink(url, title) {
|
|||||||
}
|
}
|
||||||
*/
|
*/
|
||||||
|
|
||||||
// TODO: Provide full domain, TLD, Ipv4 & Ipv6 validators
|
|
||||||
const TypeValidators: Record<TargetType, (value: string) => boolean> = {
|
const TypeValidators: Record<TargetType, (value: string) => boolean> = {
|
||||||
autnum: (value) => /^AS\d+$/.test(value),
|
autnum: (value) => /^AS\d+$/.test(value),
|
||||||
ip4: (value) => /^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}\/?\d*$/.test(value),
|
ip4: (value) => /^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}\/?\d*$/.test(value),
|
||||||
|
|||||||
Reference in New Issue
Block a user