[READ-ONLY] Mirror of https://github.com/probablykasper/time-machine-inspector. Time Machine backup size inspector app
backup macos tauri time-machine
0

Configure Feed

Select the types of activity you want to include in your feed.

Only show backup contents in page

Kasper (Jan 9, 2022, 11:28 PM +0100) 3a490f9d 8416b894

+5 -3
+5 -3
src/Page.svelte
··· 37 37 } 38 38 selectedPath = e.detail.fullPath + '/' + e.detail.name 39 39 } 40 + 41 + $: rootPath = $page.fullPath 40 42 </script> 41 43 42 44 {#if $page.fullPath === ''} ··· 47 49 {:else} 48 50 <main> 49 51 <div class="bar">{$page.fullPath}</div> 50 - {#if dirMap === null} 52 + {#if dirMap === null || dirMap[rootPath] === undefined} 51 53 <button on:click={compare} class:disabled={loading}> 52 54 {#if loading} 53 55 Loading... ··· 56 58 {/if} 57 59 </button> 58 60 {:else} 59 - {#each Object.entries(dirMap['/']) as [childName, size]} 61 + {#each Object.entries(dirMap[rootPath]) as [childName, size]} 60 62 <PageItem 61 63 map={dirMap} 62 64 {selectedPath} 63 65 name={childName} 64 66 {size} 65 - fullPath={'/' + childName} 67 + fullPath={rootPath + '/' + childName} 66 68 on:click={itemClick} /> 67 69 {/each} 68 70 {/if}