Skip to content

Commit

Permalink
rm nostr:// in search text input
Browse files Browse the repository at this point in the history
  • Loading branch information
mroxso committed Aug 25, 2024
1 parent c707015 commit dbac84d
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lumina/components/Search.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,14 @@ import { useRouter } from 'next/navigation';
export function Search() {
const router = useRouter();

const [inputValue, setInputValue] = useState('');
let [inputValue, setInputValue] = useState('');
const [isLoading, setIsLoading] = useState(false); // Neuer Zustand für das Laden

const calculateAndRedirect = async () => {
setIsLoading(true);

inputValue = inputValue.replace('nostr://','');

if (inputValue.startsWith('npub')) { // npub Search
// window.location.href = `/profile/${inputValue}`;
router.push(`/profile/${inputValue}`);
Expand Down

0 comments on commit dbac84d

Please sign in to comment.