refactor: split CommandFooter, perf tweaks

- extracted drawer modal to CommandDrawer (~180 lines)
- CommandFooter now under 270 lines
- replaced transition-all with specific props (colors, transform, etc)
- should reduce repaints on hover states
This commit is contained in:
N1C4T
2025-12-31 22:11:19 +04:00
parent 4a70f293c1
commit c3b737f901
47 changed files with 363 additions and 712 deletions

View File

@@ -1,6 +1,4 @@
/**
* Shared utilities and types for script generation
*/
// Stuff shared across all distro script generators
import { apps, type DistroId, type AppData } from '../data';
@@ -9,10 +7,7 @@ export interface PackageInfo {
pkg: string;
}
/**
* Escape special characters for safe use in shell scripts
* Prevents injection attacks from malicious app/package names
*/
// Don't let anyone sneak shell commands through app names :)
export function escapeShellString(str: string): string {
return str
.replace(/\\/g, '\\\\') // Escape backslashes first