feat: enhance osu! configuration management with batch updates and previous release stream retrieval

This commit is contained in:
2025-07-04 00:21:21 +02:00
parent 239009decb
commit 40795ad6d9
6 changed files with 152 additions and 65 deletions

View File

@@ -1,15 +1,24 @@
import { invoke } from '@tauri-apps/api/core';
export const setUserConfigValue = async (osuFolderPath: string, key: string, value: string) =>
await invoke('set_osu_user_config_value', {
export const setUserConfigValues = async (
osuFolderPath: string,
entries: { key: string; value: string }[]
) =>
await invoke('set_osu_user_config_values', {
osuFolderPath,
key,
value,
entries,
});
export const setConfigValue = async (osuFolderPath: string, key: string, value: string) =>
await invoke('set_osu_config_value', {
export const setConfigValues = async (
osuFolderPath: string,
entries: { key: string; value: string }[]
) =>
await invoke('set_osu_config_values', {
osuFolderPath,
key,
value,
entries,
});
export const getPreviousReleaseStream = async (folder: string) => {
const result = await invoke('get_osu_previous_release_stream', { folder });
return typeof result === 'string' ? result : undefined;
};