Skip to content
This repository has been archived by the owner on Apr 16, 2024. It is now read-only.

Commit

Permalink
Merge pull request #44 from FalkorDB/staging
Browse files Browse the repository at this point in the history
fix C&P
  • Loading branch information
gkorland authored Oct 9, 2023
2 parents 56cad46 + 02aa54c commit 71bd3f3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/sandbox/DatabaseLine.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ export function DatabaseLine(props: { label: string, value: string, masked?: str
const [showPassword, setShowPassword] = useState(false);

function copyToClipboard(event: any) {
navigator.clipboard.writeText(event.target.innerText)
navigator.clipboard.writeText(event.target.getAttribute("aria-label"))
toast({
title: "Copied to clipboard",
description: "The value has been copied to your clipboard.",
Expand All @@ -20,7 +20,7 @@ export function DatabaseLine(props: { label: string, value: string, masked?: str
}

return (
<div>{props.label}: <Button className="bg-transparent text-blue-600 p-2 hover:text-slate-50" onClick={copyToClipboard}>
<div>{props.label}: <Button className="bg-transparent text-blue-600 p-2 hover:text-slate-50" onClick={copyToClipboard} aria-label={props.value.toString()}>
{(showPassword || !props.masked) ? props.value : props.masked}&ensp;
<svg
className=" h-4 w-4"
Expand Down

0 comments on commit 71bd3f3

Please sign in to comment.