rewrite frontend with DaisyUI
This commit is contained in:
@ -33,25 +33,43 @@
|
||||
deny();
|
||||
}
|
||||
}
|
||||
|
||||
var appName = null;
|
||||
console.log(appName);
|
||||
if (appState.currentRequest.clients.length === 1) {
|
||||
let path = appState.currentRequest.clients[0].exe;
|
||||
let m = path.match(/\/([^/]+?$)|\\([^\\]+?$)/);
|
||||
appName = m[1] || m[2];
|
||||
}
|
||||
</script>
|
||||
|
||||
|
||||
<svelte:window on:keydown={handleHotkey} />
|
||||
|
||||
<h2 class="text-3xl text-gray-200">An application would like to access your AWS credentials.</h2>
|
||||
<div class="flex flex-col space-y-4 p-4 m-auto max-w-max h-screen justify-center">
|
||||
<!-- <div class="p-4 rounded-box border-2 border-neutral-content"> -->
|
||||
<div class="space-y-1 mb-4">
|
||||
<h2 class="text-xl font-bold">{appName ? `"${appName}"` : 'An appplication'} would like to access your AWS credentials.</h2>
|
||||
{#each appState.currentRequest.clients as client}
|
||||
<p>Path: {client ? client.exe : 'Unknown'}</p>
|
||||
<p>PID: {client ? client.pid : 'Unknown'}</p>
|
||||
{/each}
|
||||
</div>
|
||||
|
||||
<div class="text-center">
|
||||
<ul class="text-gray-200">
|
||||
{#each appState.currentRequest.clients as client}
|
||||
<li>PID: {client ? client.pid : 'Unknown'}</li>
|
||||
<li>Path: {client ? client.exe : 'Unknown'}</li>
|
||||
{/each}
|
||||
</ul>
|
||||
|
||||
<button on:click={approve}>
|
||||
<Icon name="check-circle" class="w-32 stroke-green-500" />
|
||||
</button>
|
||||
|
||||
<button on:click={deny}>
|
||||
<Icon name="x-circle" class="w-32 stroke-red-600" />
|
||||
</button>
|
||||
<div class="grid grid-cols-2">
|
||||
<button class="btn btn-error justify-self-start" on:click={deny}>
|
||||
Deny
|
||||
|
||||
<!-- <kbd class="kbd kbd-xs bg-error border-base-100">Esc</kbd> -->
|
||||
<kbd class="normal-case px-1 py-0.5 rounded border border-neutral">Esc</kbd>
|
||||
</button>
|
||||
<button class="btn btn-success justify-self-end" on:click={approve}>
|
||||
Approve
|
||||
|
||||
<kbd class="normal-case px-1 py-0.5 rounded border border-neutral">Shift</kbd>
|
||||
<span class="mx-0.5">+</span>
|
||||
<kbd class="normal-case px-1 py-0.5 rounded border border-neutral">Enter</kbd>
|
||||
</button>
|
||||
</div>
|
||||
<!-- </div> -->
|
||||
</div>
|
Reference in New Issue
Block a user