mirror of
https://github.com/purrgrammer/grimoire.git
synced 2026-04-12 08:27:27 +02:00
fix: import React namespace for type annotations
Add explicit React imports to fix React.* type references: - PowerTools: Import React for ChangeEvent and KeyboardEvent types - RelaySelector: Import React for ChangeEvent and KeyboardEvent types - Fix callback return types to explicitly return void
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
import React, { useState, useCallback } from "react";
|
||||
import { Button } from "@/components/ui/button";
|
||||
import {
|
||||
Popover,
|
||||
@@ -5,7 +6,6 @@ import {
|
||||
PopoverTrigger,
|
||||
} from "@/components/ui/popover";
|
||||
import { Input } from "@/components/ui/input";
|
||||
import { useState, useCallback } from "react";
|
||||
import { Hash, AtSign, Code, Link } from "lucide-react";
|
||||
import { useProfileSearch } from "@/hooks/useProfileSearch";
|
||||
import type { ProfileSearchResult } from "@/services/profile-search";
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { useState, useCallback } from "react";
|
||||
import React, { useState, useCallback } from "react";
|
||||
import { Button } from "@/components/ui/button";
|
||||
import { Input } from "@/components/ui/input";
|
||||
import { ScrollArea } from "@/components/ui/scroll-area";
|
||||
@@ -137,7 +137,9 @@ export function RelaySelector({
|
||||
relay={relay}
|
||||
status={getRelayStatus(relay)}
|
||||
selected={true}
|
||||
onToggle={() => handleRemoveRelay(relay)}
|
||||
onToggle={() => {
|
||||
handleRemoveRelay(relay);
|
||||
}}
|
||||
/>
|
||||
))}
|
||||
</div>
|
||||
@@ -158,7 +160,9 @@ export function RelaySelector({
|
||||
relay={relay}
|
||||
status={getRelayStatus(relay)}
|
||||
selected={false}
|
||||
onToggle={() => handleToggleRelay(relay)}
|
||||
onToggle={() => {
|
||||
handleToggleRelay(relay);
|
||||
}}
|
||||
/>
|
||||
))}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user