mirror of
https://github.com/Xevion/rdap.git
synced 2025-12-06 01:16:00 -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" ? (
|
||||
// If the detected type was provided, then notate which in parentheses. Compact object naming might be better in the future.
|
||||
detectedType.isJust ? (
|
||||
`Auto (${targetShortNames[detectedType.value]})`
|
||||
<>Auto (<span className="animate-pulse">{targetShortNames[detectedType.value]}</span>)</>
|
||||
) : (
|
||||
objectNames["auto"]
|
||||
)
|
||||
|
||||
@@ -83,7 +83,7 @@ export const placeholders: Record<SimplifiedTargetType | "auto", string> = {
|
||||
auto: "A domain, an IP address, a TLD, an RDAP URL...",
|
||||
ip: "192.168.0.1/16 or 2001:db8::/32",
|
||||
autnum: "AS27594",
|
||||
entity: "ABC123-EXAMPLE",
|
||||
entity: "OPS4-RIPE",
|
||||
url: "https://rdap.org/domain/example.com",
|
||||
tld: ".dev",
|
||||
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> = {
|
||||
autnum: (value) => /^AS\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