Working profile system

This commit is contained in:
2025-10-12 14:56:56 +02:00
parent ab84de8b03
commit 5f9bb4c877
8 changed files with 115 additions and 27 deletions
+10 -4
View File
@@ -4,16 +4,22 @@ export interface ClientSettings {
theme: "light" | "dark";
}
export interface AccountSettings {
node_ip: string;
export interface ProfileSettings {
username: string;
display_name: string;
avatar_url: string;
node_address: string;
}
export const CLIENT_SCHEMA: SettingsSchema = {
theme: ["light", "dark"],
};
export const ACCOUNT_SCHEMA: SettingsSchema = {
node_ip: new RegexSetting(
export const PROFILE_SCHEMA: SettingsSchema = {
username: "string",
display_name: "string",
avatar_url: "string",
node_address: new RegexSetting(
"node2.voxa.org",
/^(?:(?:[a-zA-Z0-9-]+\.)+[a-zA-Z]{2,}|(?:\d{1,3}\.){3}\d{1,3})$/
),