Infos
Fichiers
{#each files ? [...files] : [] as file}
{file.name}
{ files = fileListOf([...(files ?? [])].filter((f) => f.name !== file.name)); }} danger help="Supprimer">
{/each} {#each [...data.paperPaths, ...data.solutionPaths].sort() as filepath}
{filepath.split('/').at(-1)}
{ if (!(e?.target instanceof HTMLInputElement)) return; if (e.target.checked) { // Move to solutionPaths data.solutionPaths = [...data.solutionPaths, filepath]; data.paperPaths = data.paperPaths.filter((path) => path !== filepath); } else { // Move to paperPaths data.paperPaths = [...data.paperPaths, filepath]; data.solutionPaths = data.solutionPaths.filter((path) => path !== filepath); } }} value={data.solutionPaths.includes(filepath)} >
{ filesToDelete.add(filepath); data.paperPaths = data.paperPaths.filter((path) => path !== filepath); data.solutionPaths = data.solutionPaths.filter((path) => path !== filepath); }} danger help="Supprimer">
{/each}
Enregistrer
{#if serverError}
{serverError}
{/if}