mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-04-26 01:06:23 +02:00
refactor: update ApprovalCard to use state for wasAlreadyDecided across all HITL tools
- Changed the wasAlreadyDecided variable to use useState for better state management in ApprovalCard. - Updated multiple components including Gmail, Google Calendar, and Notion to reflect this change, ensuring consistency across the application.
This commit is contained in:
parent
b4309f13be
commit
4b54826d78
14 changed files with 14 additions and 14 deletions
|
|
@ -129,7 +129,7 @@ function ApprovalCard({
|
|||
const [decided, setDecided] = useState<"approve" | "reject" | "edit" | null>(
|
||||
interruptData.__decided__ ?? null
|
||||
);
|
||||
const wasAlreadyDecided = interruptData.__decided__ != null;
|
||||
const [wasAlreadyDecided] = useState(() => interruptData.__decided__ != null);
|
||||
const [isPanelOpen, setIsPanelOpen] = useState(false);
|
||||
const openHitlEditPanel = useSetAtom(openHitlEditPanelAtom);
|
||||
const [pendingEdits, setPendingEdits] = useState<{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue