diff --git a/frontend/package.json b/frontend/package.json index 7ee82ab..c5d9de8 100644 --- a/frontend/package.json +++ b/frontend/package.json @@ -1,7 +1,7 @@ { "name": "gnexus-creds-frontend", "private": true, - "version": "0.1.0", + "version": "0.2.0", "type": "module", "scripts": { "dev": "vite --host 0.0.0.0", diff --git a/frontend/src/App.vue b/frontend/src/App.vue index 356811d..5f70419 100644 --- a/frontend/src/App.vue +++ b/frontend/src/App.vue @@ -86,6 +86,8 @@ const editing = ref(false); const editFields = ref(false); const pendingDeleteSecret = ref(null); +const pendingRevokeToken = ref(null); +const showRevokeConfirm = ref(false); const importFiles = ref([]); const importFile = ref(null); const importPreview = ref(null); @@ -762,13 +764,17 @@ } } -async function revokeToken(token) { - await api.revokeToken(token.id); - await loadTokens(); +function confirmRevokeToken(token) { + pendingRevokeToken.value = token; + showRevokeConfirm.value = true; } -async function copyText(value) { - await copyValue(value); +async function doRevokeToken() { + if (!pendingRevokeToken.value) return; + await api.revokeToken(pendingRevokeToken.value.id); + pendingRevokeToken.value = null; + showRevokeConfirm.value = false; + await loadTokens(); } async function exportData() { @@ -1016,6 +1022,7 @@
@@ -1210,7 +1217,7 @@ @@ -1243,22 +1250,23 @@ :multiple="false" accept="application/json,.json" @change="handleImportFiles" - /> + > + + {{ importError }}
{{ importPreview.secrets?.length || 0 }} secrets ready {{ importFile?.name }}
-
- - Import selected file - -
@@ -1382,12 +1390,20 @@ icon="ph ph-target" help="Target service, server, account, or other secret destination." /> - +
+ + +
-
@@ -1483,16 +1495,26 @@
- +
+ + +
- - +