From d18b6673e6f81472bf4486d911f20562c3c7ef91 Mon Sep 17 00:00:00 2001 From: Frank Date: Wed, 8 Oct 2025 17:03:42 -0400 Subject: wip: zen --- .../app/src/routes/workspace/key-section.tsx | 50 ++++++++++++---------- 1 file changed, 27 insertions(+), 23 deletions(-) (limited to 'packages/console/app/src') diff --git a/packages/console/app/src/routes/workspace/key-section.tsx b/packages/console/app/src/routes/workspace/key-section.tsx index e94d2bf86..1c2316db7 100644 --- a/packages/console/app/src/routes/workspace/key-section.tsx +++ b/packages/console/app/src/routes/workspace/key-section.tsx @@ -7,6 +7,11 @@ import { createStore } from "solid-js/store" import { formatDateUTC, formatDateForTable } from "./common" import styles from "./key-section.module.css" import { Actor } from "@opencode-ai/console-core/actor.js" +import { and, Database, eq, isNull, sql } from "@opencode-ai/console-core/drizzle/index.js" +import { KeyTable } from "@opencode-ai/console-core/schema/key.sql.js" +import { UserTable } from "@opencode-ai/console-core/schema/user.sql.js" +import { AccountTable } from "@opencode-ai/console-core/schema/account.sql.js" +import { User } from "@opencode-ai/console-core/user.js" const removeKey = action(async (form: FormData) => { "use server" @@ -108,11 +113,6 @@ export function KeySection() { const params = useParams() const keys = createAsync(() => listKeys(params.id)) - function formatKey(key: string) { - if (key.length <= 11) return key - return `${key.slice(0, 7)}...${key.slice(-4)}` - } - return (
@@ -134,7 +134,8 @@ export function KeySection() { Name Key - Created + Created By + Last Used @@ -147,24 +148,27 @@ export function KeySection() { {key.name} - + {key.keyDisplay}}> + + - - {formatDateForTable(key.timeCreated)} + {key.email} + + {key.timeUsed ? formatDateForTable(key.timeUsed) : "-"}
-- cgit v1.2.3