From 8e662e65f6ea595016db21b99328cc7822d0b92e Mon Sep 17 00:00:00 2001 From: Cristhian Zanforlin Lousa Date: Thu, 17 Aug 2023 19:51:40 -0300 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20fix(ApiKeysPage):=20add=20missin?= =?UTF-8?q?g=20TableHead=20for=20'Id'=20column=20to=20improve=20table=20st?= =?UTF-8?q?ructure=20=E2=9C=A8=20feat(ApiKeysPage):=20add=20tooltip=20and?= =?UTF-8?q?=20cursor-default=20to=20display=20the=20full=20'Id'=20value=20?= =?UTF-8?q?in=20the=20table=20=F0=9F=90=9B=20fix(ApiKeysPage):=20fix=20typ?= =?UTF-8?q?o=20in=20ConfirmationModal=20titleHeader=20from=20'Delete=20Use?= =?UTF-8?q?r'=20to=20'Delete=20Key'=20=E2=9C=A8=20feat(ApiKeysPage):=20add?= =?UTF-8?q?=20onCloseModal=20callback=20to=20refresh=20keys=20after=20crea?= =?UTF-8?q?ting=20a=20new=20secret=20key?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/frontend/src/pages/ApiKeysPage/index.tsx | 112 ++++++++++--------- 1 file changed, 62 insertions(+), 50 deletions(-) diff --git a/src/frontend/src/pages/ApiKeysPage/index.tsx b/src/frontend/src/pages/ApiKeysPage/index.tsx index d91005191..37e148caa 100644 --- a/src/frontend/src/pages/ApiKeysPage/index.tsx +++ b/src/frontend/src/pages/ApiKeysPage/index.tsx @@ -129,6 +129,7 @@ export default function ApiKeysPage() { } > + Id Name Key Created @@ -148,57 +149,66 @@ export default function ApiKeysPage() { {!loadingKeys && ( - {keysList.current.map((api_keys: ApiKey, index: number) => ( - - - + {keysList.current.map( + (api_keys: ApiKey, index: number) => ( + + + + + {api_keys.id} + + + + + + + {api_keys.name} + + + + - {api_keys.name} + {api_keys.api_key} - - - - - {api_keys.api_key} - - - - {moment(api_keys.created_at).format( - "YYYY-MM-DD HH:mm" - )} - - - {moment(api_keys.last_used_at).format( - "YYYY-MM-DD HH:mm" - )} - - -
- { - handleDeleteKey(keys); - }} - > - - - - -
-
-
- ))} + + + {moment(api_keys.created_at).format( + "YYYY-MM-DD HH:mm" + )} + + + {moment(api_keys.last_used_at).format( + "YYYY-MM-DD HH:mm" + )} + + +
+ { + handleDeleteKey(keys); + }} + > + + + + +
+
+
+ ) + )} )} @@ -212,7 +222,9 @@ export default function ApiKeysPage() { confirmationText="Create secret key" icon={"Key"} data={userId} - onCloseModal={() => {getKeys()}} + onCloseModal={() => { + getKeys(); + }} >