initial commit

This commit is contained in:
terraputix
2026-01-07 22:24:02 +01:00
commit 9b39255e64
315 changed files with 14484 additions and 0 deletions
+23
View File
@@ -0,0 +1,23 @@
import { writable } from 'svelte/store';
// Placeholder function for urlHashStore
// In a real application, this would handle URL hash parameters
// and return a Svelte store that reflects those parameters.
export function urlHashStore(initialValue: Record<string, any>) {
const { subscribe, set, update } = writable(initialValue);
// In a full implementation, you would add logic here to:
// 1. Read the URL hash on initialization
// 2. Parse the hash into an object
// 3. Update the store with these values
// 4. Listen for changes to the store and update the URL hash accordingly
// 5. Listen for URL hash changes (e.g., back/forward buttons) and update the store
return {
subscribe,
set,
update,
// You might want to add methods to easily update specific hash parameters
updateParam: (key: string, value: any) => update((current) => ({ ...current, [key]: value }))
};
}