feat: enhance locale handling and improve cookie management in Header component
Gitea Auto Deploy / Deploy-Container (push) Successful in 50s

fix: update CopyImport component to handle profile selection and data validation

feat: refactor EnkaImport component for better data parsing and error handling

fix: improve FreeSRImport component with enhanced data validation and error management

fix: update calcData helper functions to handle edge cases and improve robustness

refactor: enhance converter functions for better data handling and validation

feat: add validation to persisted stores using Zod schemas

fix: update Zustand stores to use validated JSON storage for improved data integrity

chore: add new Zod schemas for locale and connection persistence

fix: ensure proper handling of optional fields in various data structures
This commit is contained in:
2026-05-15 20:34:15 +07:00
parent 93a8d8f1ac
commit ca61ddfd5f
26 changed files with 556 additions and 304 deletions
+3 -2
View File
@@ -13,7 +13,8 @@ const formatValue = (value: number, format: string, floatDigits?: string, hasPer
return String(value);
};
export function replaceByParam(desc: string, params: number[]): string {
export function replaceByParam(desc?: string, params: number[] = []): string {
if (!desc) return "";
const PARAM_REGEX = /#(\d+)\[(f(\d+)|i)\](%)?/g;
@@ -35,4 +36,4 @@ export function replaceByParam(desc: string, params: number[]): string {
result = result.replace(PARAM_REGEX, processor);
return result.split("\\n").join("<br/>");
}
}