From eb9c4e6d14b10dcb51f9c4d97b2d2a075022374f Mon Sep 17 00:00:00 2001 From: dawoodkhan82 Date: Thu, 20 Jan 2022 18:25:24 -0500 Subject: [PATCH] Ui feedback changes --- frontend-svelte/src/components/input/File.svelte | 7 +++++-- frontend-svelte/src/components/output/File.svelte | 7 +++++-- .../src/components/output/HighlightedText.svelte | 4 ++-- frontend-svelte/src/components/output/Label.svelte | 4 ++-- frontend-svelte/src/components/utils/Upload.svelte | 6 +++++- 5 files changed, 19 insertions(+), 9 deletions(-) diff --git a/frontend-svelte/src/components/input/File.svelte b/frontend-svelte/src/components/input/File.svelte index ae7d38bd08..2773a7d84f 100644 --- a/frontend-svelte/src/components/input/File.svelte +++ b/frontend-svelte/src/components/input/File.svelte @@ -14,9 +14,12 @@ Click to Upload {:else} -
+
setValue(null)} {theme} /> -
{value.name}
+ + + +
{value.name}
{prettyBytes(value.size)}
diff --git a/frontend-svelte/src/components/output/File.svelte b/frontend-svelte/src/components/output/File.svelte index 77a326717f..12e5f01ba2 100644 --- a/frontend-svelte/src/components/output/File.svelte +++ b/frontend-svelte/src/components/output/File.svelte @@ -5,12 +5,15 @@ -
{value.name}
+ + + +
{value.name}
{isNaN(value.size) ? "" : prettyBytes(value.size)}
diff --git a/frontend-svelte/src/components/output/HighlightedText.svelte b/frontend-svelte/src/components/output/HighlightedText.svelte index 628811a339..f87570a46b 100644 --- a/frontend-svelte/src/components/output/HighlightedText.svelte +++ b/frontend-svelte/src/components/output/HighlightedText.svelte @@ -40,7 +40,7 @@
{/if}
{#each value as [text, category], i} {/if}
{#each value as [text, score], i} .output-label[theme="default"] { .label { - @apply text-sm h-5; + @apply text-base h-7; } .confidence { - @apply font-mono box-border border-b-2 border-gray-300 bg-gray-200 dark:bg-gray-500 dark:border-gray-600 text-sm h-5 font-semibold rounded; + @apply font-mono box-border border-b-2 border-gray-300 bg-gray-200 dark:bg-gray-500 dark:border-gray-600 text-sm h-7 font-semibold rounded; } .confidence:first-child { @apply border-yellow-600 bg-yellow-500 dark:bg-red-600 border-red-700 text-white; diff --git a/frontend-svelte/src/components/utils/Upload.svelte b/frontend-svelte/src/components/utils/Upload.svelte index fd93e7a366..27b0f7ca3e 100644 --- a/frontend-svelte/src/components/utils/Upload.svelte +++ b/frontend-svelte/src/components/utils/Upload.svelte @@ -3,7 +3,9 @@ export let single_file = true; export let include_file_metadata = true; let hidden_upload; + let dragging = false; + const updateDragging = () => {dragging = !dragging} const openFileUpload = () => { hidden_upload.click(); }; @@ -42,7 +44,7 @@