mirror of
https://github.com/i701/sarlink-portal.git
synced 2025-07-03 19:08:23 +00:00
refactor: reorganize imports and improve session handling in various components 🔨
Some checks are pending
Build and Push Docker Images / Build and Push Docker Images (push) Has started running
Some checks are pending
Build and Push Docker Images / Build and Push Docker Images (push) Has started running
This commit is contained in:
@ -1,15 +1,14 @@
|
||||
"use client";
|
||||
|
||||
import { Loader2, Plus } from "lucide-react";
|
||||
import { useActionState, useEffect, useState } from "react"; // Import useActionState
|
||||
import { toast } from "sonner";
|
||||
import { Button } from "@/components/ui/button";
|
||||
import { Dialog, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogTitle, DialogTrigger } from "@/components/ui/dialog";
|
||||
import { Input } from "@/components/ui/input";
|
||||
import { Label } from "@/components/ui/label";
|
||||
import { Loader2, Plus } from "lucide-react";
|
||||
import { useActionState, useEffect, useState } from "react"; // Import useActionState
|
||||
import { toast } from "sonner";
|
||||
import { GetMacAccordion } from "../how-to-get-mac";
|
||||
|
||||
import { addDeviceAction } from "@/queries/devices";
|
||||
import { GetMacAccordion } from "../how-to-get-mac";
|
||||
|
||||
export type AddDeviceFormState = {
|
||||
message: string;
|
||||
@ -72,7 +71,7 @@ export default function AddDeviceDialogForm({ user_id }: { user_id?: string }) {
|
||||
<div className="grid gap-4 py-4">
|
||||
<div className="flex flex-col gap-2">
|
||||
<div>
|
||||
<Label htmlFor="device_name" className="text-right">
|
||||
<Label htmlFor="device_name">
|
||||
Device Name
|
||||
</Label>
|
||||
<Input
|
||||
@ -91,7 +90,7 @@ export default function AddDeviceDialogForm({ user_id }: { user_id?: string }) {
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<Label htmlFor="mac_address" className="text-right">
|
||||
<Label htmlFor="mac_address">
|
||||
Mac Address
|
||||
</Label>
|
||||
<Input
|
||||
|
Reference in New Issue
Block a user