feat: add profile fields for local users
DB→domain→API→AP→frontend end-to-end. Fields stored as JSONB, exposed via PATCH /users/me, serialized as AP PropertyValue attachment. Editor in federation settings, display on profile card.
This commit is contained in:
@@ -8,6 +8,7 @@ pub struct UpdateProfileInput {
|
||||
pub avatar_url: Option<String>,
|
||||
pub header_url: Option<String>,
|
||||
pub custom_css: Option<String>,
|
||||
pub profile_fields: Option<Vec<(String, String)>>,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone)]
|
||||
@@ -21,6 +22,7 @@ pub struct User {
|
||||
pub avatar_url: Option<String>,
|
||||
pub header_url: Option<String>,
|
||||
pub custom_css: Option<String>,
|
||||
pub profile_fields: Vec<(String, String)>,
|
||||
pub local: bool,
|
||||
pub created_at: DateTime<Utc>,
|
||||
pub updated_at: DateTime<Utc>,
|
||||
@@ -44,6 +46,7 @@ impl User {
|
||||
avatar_url: None,
|
||||
header_url: None,
|
||||
custom_css: None,
|
||||
profile_fields: vec![],
|
||||
local: true,
|
||||
created_at: now,
|
||||
updated_at: now,
|
||||
|
||||
Reference in New Issue
Block a user