[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.

Glow button design

Kasper (Jan 2, 2022, 11:05 PM +0100) 74a6def7 46c8206c

+118 -35
+22 -10
src-tauri/Cargo.lock
··· 2515 2515 [[package]] 2516 2516 name = "tauri" 2517 2517 version = "1.0.0-beta.8" 2518 - source = "git+https://github.com/tauri-apps/tauri?rev=543e6bd#543e6bdb913d827c6fa410769442194a409b02d0" 2518 + source = "git+https://github.com/probablykasper/tauri?rev=4c1be45#4c1be451066612862363bc481910bd6c3da1e185" 2519 2519 dependencies = [ 2520 2520 "attohttpc", 2521 2521 "bincode", ··· 2545 2545 "tauri-macros", 2546 2546 "tauri-runtime", 2547 2547 "tauri-runtime-wry", 2548 - "tauri-utils 1.0.0-beta.3 (git+https://github.com/tauri-apps/tauri?rev=543e6bd)", 2548 + "tauri-utils 1.0.0-beta.3 (git+https://github.com/probablykasper/tauri?rev=4c1be45)", 2549 2549 "tempfile", 2550 2550 "thiserror", 2551 2551 "tokio", ··· 2571 2571 [[package]] 2572 2572 name = "tauri-codegen" 2573 2573 version = "1.0.0-beta.4" 2574 - source = "git+https://github.com/tauri-apps/tauri?rev=543e6bd#543e6bdb913d827c6fa410769442194a409b02d0" 2574 + source = "git+https://github.com/probablykasper/tauri?rev=4c1be45#4c1be451066612862363bc481910bd6c3da1e185" 2575 2575 dependencies = [ 2576 2576 "blake3", 2577 2577 "kuchiki", ··· 2580 2580 "regex", 2581 2581 "serde", 2582 2582 "serde_json", 2583 - "tauri-utils 1.0.0-beta.3 (git+https://github.com/tauri-apps/tauri?rev=543e6bd)", 2583 + "tauri-utils 1.0.0-beta.3 (git+https://github.com/probablykasper/tauri?rev=4c1be45)", 2584 2584 "thiserror", 2585 2585 "walkdir", 2586 2586 "zstd", ··· 2589 2589 [[package]] 2590 2590 name = "tauri-macros" 2591 2591 version = "1.0.0-beta.5" 2592 - source = "git+https://github.com/tauri-apps/tauri?rev=543e6bd#543e6bdb913d827c6fa410769442194a409b02d0" 2592 + source = "git+https://github.com/probablykasper/tauri?rev=4c1be45#4c1be451066612862363bc481910bd6c3da1e185" 2593 2593 dependencies = [ 2594 2594 "proc-macro2", 2595 2595 "quote", ··· 2598 2598 ] 2599 2599 2600 2600 [[package]] 2601 + name = "tauri-plugin-vibrancy" 2602 + version = "0.0.0" 2603 + source = "git+https://github.com/tauri-apps/tauri-plugin-vibrancy#efa941599ea3f54c818aeb5bb0088064699db4be" 2604 + dependencies = [ 2605 + "cocoa", 2606 + "objc", 2607 + "tauri", 2608 + "windows", 2609 + ] 2610 + 2611 + [[package]] 2601 2612 name = "tauri-runtime" 2602 2613 version = "0.2.1" 2603 - source = "git+https://github.com/tauri-apps/tauri?rev=543e6bd#543e6bdb913d827c6fa410769442194a409b02d0" 2614 + source = "git+https://github.com/probablykasper/tauri?rev=4c1be45#4c1be451066612862363bc481910bd6c3da1e185" 2604 2615 dependencies = [ 2605 2616 "gtk", 2606 2617 "http", ··· 2608 2619 "infer", 2609 2620 "serde", 2610 2621 "serde_json", 2611 - "tauri-utils 1.0.0-beta.3 (git+https://github.com/tauri-apps/tauri?rev=543e6bd)", 2622 + "tauri-utils 1.0.0-beta.3 (git+https://github.com/probablykasper/tauri?rev=4c1be45)", 2612 2623 "thiserror", 2613 2624 "uuid", 2614 2625 "webview2-com", ··· 2618 2629 [[package]] 2619 2630 name = "tauri-runtime-wry" 2620 2631 version = "0.2.1" 2621 - source = "git+https://github.com/tauri-apps/tauri?rev=543e6bd#543e6bdb913d827c6fa410769442194a409b02d0" 2632 + source = "git+https://github.com/probablykasper/tauri?rev=4c1be45#4c1be451066612862363bc481910bd6c3da1e185" 2622 2633 dependencies = [ 2623 2634 "gtk", 2624 2635 "ico", 2625 2636 "infer", 2626 2637 "png 0.16.8", 2627 2638 "tauri-runtime", 2628 - "tauri-utils 1.0.0-beta.3 (git+https://github.com/tauri-apps/tauri?rev=543e6bd)", 2639 + "tauri-utils 1.0.0-beta.3 (git+https://github.com/probablykasper/tauri?rev=4c1be45)", 2629 2640 "uuid", 2630 2641 "webview2-com", 2631 2642 "windows", ··· 2653 2664 [[package]] 2654 2665 name = "tauri-utils" 2655 2666 version = "1.0.0-beta.3" 2656 - source = "git+https://github.com/tauri-apps/tauri?rev=543e6bd#543e6bdb913d827c6fa410769442194a409b02d0" 2667 + source = "git+https://github.com/probablykasper/tauri?rev=4c1be45#4c1be451066612862363bc481910bd6c3da1e185" 2657 2668 dependencies = [ 2658 2669 "heck 0.4.0", 2659 2670 "html5ever", ··· 2746 2757 "serde_json", 2747 2758 "tauri", 2748 2759 "tauri-build", 2760 + "tauri-plugin-vibrancy", 2749 2761 ] 2750 2762 2751 2763 [[package]]
+5 -2
src-tauri/Cargo.toml
··· 17 17 [dependencies] 18 18 serde_json = "1.0" 19 19 serde = { version = "1.0", features = ["derive"] } 20 - # tauri = { version = "1.0.0-beta.8", features = ["api-all"] } 21 - tauri = { git = "https://github.com/tauri-apps/tauri", rev = "543e6bd", features = ["dialog-open", "dialog-save", "shell-open"] } 20 + tauri = { git = "https://github.com/tauri-apps/tauri", branch = "next", features = ["dialog-open", "dialog-save", "shell-open"] } 21 + tauri-plugin-vibrancy = { git = "https://github.com/tauri-apps/tauri-plugin-vibrancy", features = ["tauri-impl"] } 22 + 23 + [patch."https://github.com/tauri-apps/tauri"] 24 + tauri = { git = "https://github.com/probablykasper/tauri", rev = "4c1be45" } 22 25 23 26 [features] 24 27 default = [ "custom-protocol" ]
+12 -1
src-tauri/src/main.rs
··· 6 6 use std::thread; 7 7 use tauri::api::{dialog, shell}; 8 8 use tauri::{ 9 - command, CustomMenuItem, Menu, MenuEntry, MenuItem, Submenu, Window, WindowBuilder, WindowUrl, 9 + command, CustomMenuItem, Manager, Menu, MenuEntry, MenuItem, Submenu, Window, WindowBuilder, 10 + WindowUrl, 10 11 }; 11 12 12 13 mod cmd; ··· 37 38 .resizable(true) 38 39 .transparent(false) 39 40 .decorations(true) 41 + // .transparent(true) 40 42 .always_on_top(false) 41 43 .inner_size(800.0, 550.0) 42 44 .min_inner_size(400.0, 200.0) 43 45 .skip_taskbar(false) 44 46 .fullscreen(false); 45 47 return (win, webview); 48 + }) 49 + .setup(|app| { 50 + let window: tauri::Window = app.handle().get_window("main").unwrap(); 51 + #[cfg(target_os = "macos")] 52 + { 53 + use tauri_plugin_vibrancy::Vibrancy; 54 + window.apply_vibrancy(tauri_plugin_vibrancy::MacOSVibrancy::WindowBackground); 55 + } 56 + Ok(()) 46 57 }) 47 58 .menu(Menu::with_items([ 48 59 #[cfg(target_os = "macos")]
+79 -22
src/App.svelte
··· 18 18 } 19 19 </script> 20 20 21 - <div class="button" on:click={loadBackups} class:disabled={loading} tabindex="0"> 22 - {#if loading} 23 - Loading... 24 - {:else} 25 - Load Backups 21 + <div class="border" /> 22 + <div class="sidebar"> 23 + <div class="button" on:click={loadBackups} class:disabled={loading} tabindex="0"> 24 + {#if loading} 25 + Loading... 26 + {:else} 27 + Load Backups 28 + {/if} 29 + </div> 30 + {#if backups !== null} 31 + {#each backups as backup} 32 + <div class="backup">{backup}</div> 33 + {/each} 26 34 {/if} 27 35 </div> 36 + <div class="page" /> 28 37 29 - {#if backups !== null} 30 - {#each backups as backup} 31 - <div class="backup">{backup}</div> 32 - {/each} 33 - {/if} 38 + <style lang="sass"> 39 + $c1: #822b38 40 + $c2: #ac209c 41 + $c3: #f19e8e 42 + 43 + $easing: cubic-bezier(0.4, 0.0, 0.2, 1) 34 44 35 - <style lang="sass"> 45 + $c1: hsl(242, 50%, 21%) 46 + $c2: hsl(234, 63%, 10%) 47 + $c1: hsl(195, 60%, 20%) 48 + $c2: hsl(207, 90%, 8%) 49 + $c1: hsl(0, 0%, 8%) 50 + $c2: hsl(0, 0%, 0%) 36 51 :global(html) 37 52 height: 100% 38 - background-color: #0f1114 39 - :global(body) 53 + background: radial-gradient(circle at 50% 0%, $c1, $c2) 54 + // background: $c2 40 55 font-family: Arial, Helvetica, sans-serif 41 56 font-size: 18px 42 57 color: #f2f2f2 58 + :global(body) 59 + height: 100% 60 + margin: 0px 61 + display: flex 62 + box-sizing: border-box 63 + border-top: 0px 64 + .sidebar 65 + width: 180px 66 + flex-shrink: 0 67 + height: 100% 68 + box-sizing: border-box 69 + overflow: auto 70 + padding: 15px 71 + background-color: hsla(0, 0%, 100%, 0.05) 72 + border-right: 1px solid hsla(0, 0%, 100%, 0.05) 73 + display: flex 74 + flex-direction: column 75 + align-items: center 76 + .button 77 + margin-bottom: 15px 78 + .page 79 + width: 100% 80 + height: 100% 43 81 .button 44 82 display: inline-block 45 83 position: relative ··· 47 85 -webkit-user-select: none 48 86 cursor: default 49 87 outline: none 50 - width: 90px 51 - padding: 5px 12px 52 - margin: 10px 53 - color: #f2f2f2 54 - border-radius: 3px 55 - font-size: 14px 56 - background-color: rgba(255,255,255,0.15) 57 - box-shadow: 0px 0px 0px 1px hsla(0, 0%, 100%, 0.3) 58 - transition: all 0.2s ease-in-out 88 + width: 100% 89 + box-sizing: border-box 90 + padding: 7px 14px 91 + color: #ffffff 92 + text-align: center 93 + font-size: 13px 94 + background-image: radial-gradient(circle at 50% 0%, hsla(165, 100%, 35%, 0.5), hsla(165, 100%, 28%, 0.5)) 95 + border: 1px solid hsla(0, 0%, 100%, 0.08) 96 + border-radius: 4px 97 + box-shadow: 0px 0px 10px hsla(165, 80%, 35%, 0.5) 98 + transition: all 120ms $easing 99 + &::before 100 + content: '' 101 + z-index: -1 102 + position: absolute 103 + top: 0px 104 + left: 0px 105 + width: 100% 106 + height: 100% 107 + background-image: radial-gradient(circle at 50% 0%, hsla(165, 100%, 35%, 1), transparent) 108 + border-radius: 4px 109 + opacity: 0 110 + transition: all 180ms $easing 111 + &:hover 112 + box-shadow: 0px 0px 10px 2px hsla(165, 80%, 30%, 0.8) 113 + border: 1px solid hsla(0, 0%, 100%, 0.1) 114 + &::before 115 + opacity: 0.5 59 116 &.disabled 60 117 opacity: 0.75 61 118 .backup