remove usememo return in add system dialog

- forgot to remove this before last commit. interferes with token display.
This commit is contained in:
henrygd
2025-08-22 20:27:12 -04:00
parent c158b1aeeb
commit 3c4ae46f50

View File

@@ -17,7 +17,7 @@ import { $publicKey, pb } from "@/lib/stores"
import { cn, generateToken, isReadOnlyUser, tokenMap, useLocalStorage } from "@/lib/utils"
import { useStore } from "@nanostores/react"
import { ChevronDownIcon, ExternalLinkIcon, PlusIcon } from "lucide-react"
import { memo, useEffect, useMemo, useRef, useState } from "react"
import { memo, useEffect, useRef, useState } from "react"
import { $router, basePath, Link, navigate } from "./router"
import { SystemRecord } from "@/types"
import { AppleIcon, DockerIcon, TuxIcon, WindowsIcon } from "./ui/icons"
@@ -122,8 +122,7 @@ export const SystemDialog = ({ setOpen, system }: { setOpen: (open: boolean) =>
}
}
return useMemo(
() => (
return (
<DialogContent
className="w-[90%] sm:w-auto sm:ns-dialog max-w-full rounded-lg"
onCloseAutoFocus={() => {
@@ -238,9 +237,7 @@ export const SystemDialog = ({ setOpen, system }: { setOpen: (open: boolean) =>
<CopyButton
text={t`Copy Linux command`}
icon={<TuxIcon className="size-4" />}
onClick={async () =>
copyLinuxCommand(isUnixSocket ? hostValue : port.current?.value, publicKey, token)
}
onClick={async () => copyLinuxCommand(isUnixSocket ? hostValue : port.current?.value, publicKey, token)}
dropdownItems={[
{
text: t({ message: "Homebrew command", context: "Button to copy install command" }),
@@ -268,8 +265,6 @@ export const SystemDialog = ({ setOpen, system }: { setOpen: (open: boolean) =>
</form>
</Tabs>
</DialogContent>
),
[]
)
}