-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'origin/main' into 18-parsing-csv-file-w…
…ith-only-one-column-fails
- Loading branch information
Showing
20 changed files
with
331 additions
and
236 deletions.
There are no files selected for viewing
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<script> | ||
import { base } from "$app/paths"; | ||
export let parentRoute = ""; | ||
</script> | ||
|
||
<a href="{base}/{parentRoute}" type="button" class="btn variant-filled-secondary mb-6 print:hidden ml-[10mm] mt-[10mm]"> | ||
<span class="material-symbols-outlined">arrow_back</span> | ||
<span>Go Back</span> | ||
</a> |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
<script> | ||
export let downloadEnabled = false; | ||
export let csvData = ""; | ||
function downloadCsv(){ | ||
const filename = 'study_results.csv'; | ||
const blob = new Blob([csvData], { type: 'text/csv' }); | ||
const url = URL.createObjectURL(blob); | ||
const a = document.createElement('a'); | ||
a.href = url; | ||
a.download = filename; | ||
document.body.appendChild(a); | ||
a.click(); | ||
document.body.removeChild(a); | ||
URL.revokeObjectURL(url); | ||
} | ||
</script> | ||
|
||
<div class="container h-full mx-auto flex justify-center items-center text-center"> | ||
<div class="w-1/2 space-y-6 my-6"> | ||
<section class="w-full p-4 space-y-4"> | ||
{#if downloadEnabled} | ||
<p>Processing finished!</p> | ||
{:else} | ||
<p>Files are being processed...</p> | ||
{/if} | ||
</section> | ||
<section class="w-full flex justify-center items-center"> | ||
<button on:click={downloadCsv} type="button" class="btn variant-filled-primary p-6 mt-6" disabled={!downloadEnabled}> | ||
<span class="material-symbols-outlined">download</span> | ||
<span>Download CSV</span> | ||
</button> | ||
</section> | ||
</div> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
<script lang="ts"> | ||
export let files: FileList = <FileList>{}; | ||
</script> | ||
|
||
<section class="w-full text-token card p-4 space-y-4"> | ||
{#if files.length > 0} | ||
<p class="font-bold">Selected files</p> | ||
<ul class="list"> | ||
{#each { length: files.length } as _, i} | ||
<li> | ||
<span class="badge-icon p-4 variant-soft-tertiary"> | ||
<span class="material-symbols-outlined"> contact_page </span> | ||
</span> | ||
<span class="flex-auto">{files[i].name}</span> | ||
</li> | ||
{/each} | ||
</ul> | ||
{:else} | ||
<p class="font-bold text-center">No files selected.</p> | ||
{/if} | ||
</section> |
2 changes: 1 addition & 1 deletion
2
src/lib/forms/BarcodeForm.svelte → ...components/preparation/BarcodeForm.svelte
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/lib/forms/QrCodeForm.svelte → .../components/preparation/QrCodeForm.svelte
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.