feat: run Velum project jobs in the background and process DOCX locally

This commit is contained in:
muena
2026-11-30 16:12:11 +01:00
parent 11ddd6d70f
commit d2ed7130f0
32 changed files with 2325 additions and 462 deletions

21
src/lib/worker-runtime.ts Normal file
View File

@@ -0,0 +1,21 @@
import type { NormalizedPreferences } from "../preferences";
// Only these Raycast services are used by the shared Node project code.
export const environment = { assetsPath: "", supportPath: "" };
let preferences: NormalizedPreferences;
export function getPreferenceValues<T>(): T {
return preferences as T;
}
const tokenStore = new Map<string, string>();
export const LocalStorage = {
async getItem<T>(key: string) { return tokenStore.get(key) as T | undefined; },
async setItem(key: string, value: string) { tokenStore.set(key, value); },
async removeItem(key: string) { tokenStore.delete(key); },
};
export function configureWorker(config: { assets: string; support: string; preferences: NormalizedPreferences }) {
environment.assetsPath = config.assets;
environment.supportPath = config.support;
preferences = config.preferences;
}