Struct UserSettings

Source
pub struct UserSettings {
Show 66 fields pub display_name: String, pub biography: String, pub warning: String, pub private_profile: bool, pub private_communities: bool, pub theme_preference: ThemePreference, pub profile_theme: ThemePreference, pub private_last_seen: bool, pub theme_hue: String, pub theme_sat: String, pub theme_lit: String, pub theme_color_surface: String, pub theme_color_text: String, pub theme_color_text_link: String, pub theme_color_lowered: String, pub theme_color_text_lowered: String, pub theme_color_super_lowered: String, pub theme_color_raised: String, pub theme_color_text_raised: String, pub theme_color_super_raised: String, pub theme_color_primary: String, pub theme_color_text_primary: String, pub theme_color_primary_lowered: String, pub theme_color_secondary: String, pub theme_color_text_secondary: String, pub theme_color_secondary_lowered: String, pub theme_custom_css: String, pub theme_color_online: String, pub theme_color_idle: String, pub theme_color_offline: String, pub disable_other_themes: bool, pub disable_other_theme_css: bool, pub enable_questions: bool, pub motivational_header: String, pub allow_anonymous_questions: bool, pub anonymous_username: String, pub anonymous_avatar_url: String, pub hide_dislikes: bool, pub default_timeline: DefaultTimelineChoice, pub private_chats: bool, pub private_mails: bool, pub status: String, pub avatar_mime: String, pub banner_mime: String, pub require_account: bool, pub show_nsfw: bool, pub hide_extra_post_tabs: bool, pub muted: Vec<String>, pub paged_timelines: bool, pub enable_drawings: bool, pub auto_unlist: bool, pub all_timeline_hide_answers: bool, pub auto_clear_notifs: bool, pub large_text: bool, pub disable_achievements: bool, pub hide_associated_blocked_users: bool, pub default_profile_tab: DefaultProfileTabChoice, pub hide_from_social_lists: bool, pub auto_full_unlist: bool, pub private_biography: String, pub hide_social_follows: bool, pub mail_signature: String, pub forum_signature: String, pub no_transfers: bool, pub enable_shop: bool, pub hide_username_badges: bool,
}

Fields§

§display_name: String§biography: String§warning: String§private_profile: bool§private_communities: bool§theme_preference: ThemePreference

The theme shown to the user.

§profile_theme: ThemePreference

The theme used on the user’s profile. Setting this to Auto will use the viewing user’s theme_preference setting.

§private_last_seen: bool§theme_hue: String§theme_sat: String§theme_lit: String§theme_color_surface: String

Page background.

§theme_color_text: String

Text on elements with the surface backgrounds.

§theme_color_text_link: String

Links on all elements.

§theme_color_lowered: String

Some cards, buttons, or anything else with a darker background color than the surface.

§theme_color_text_lowered: String

Text on elements with the lowered backgrounds.

§theme_color_super_lowered: String

Borders.

§theme_color_raised: String

Some cards, buttons, or anything else with a lighter background color than the surface.

§theme_color_text_raised: String

Text on elements with the raised backgrounds.

§theme_color_super_raised: String

Some borders.

§theme_color_primary: String

Primary color; navigation bar, some buttons, etc.

§theme_color_text_primary: String

Text on elements with the primary backgrounds.

§theme_color_primary_lowered: String

Hover state for primary buttons.

§theme_color_secondary: String

Secondary color.

§theme_color_text_secondary: String

Text on elements with the secondary backgrounds.

§theme_color_secondary_lowered: String

Hover state for secondary buttons.

§theme_custom_css: String

Custom CSS input.

§theme_color_online: String

The color of an online online indicator.

§theme_color_idle: String

The color of an idle online indicator.

§theme_color_offline: String

The color of an offline online indicator.

§disable_other_themes: bool§disable_other_theme_css: bool§enable_questions: bool§motivational_header: String

A header shown in the place of “Ask question” if enable_questions is true.

§allow_anonymous_questions: bool

If questions from anonymous users are allowed. Requires enable_questions.

§anonymous_username: String

The username used for anonymous users.

§anonymous_avatar_url: String

The URL of the avatar used for anonymous users.

§hide_dislikes: bool

If dislikes are hidden for the user.

§default_timeline: DefaultTimelineChoice

The timeline that the “Home” button takes you to.

§private_chats: bool

If other users that you aren’t following can add you to chats.

§private_mails: bool

If other users that you aren’t following can send you letters.

§status: String

The user’s status. Shows over connection info.

§avatar_mime: String

The mime type of the user’s avatar.

§banner_mime: String

The mime type of the user’s banner.

§require_account: bool

Require an account to view the user’s profile.

§show_nsfw: bool

If NSFW content should be shown.

§hide_extra_post_tabs: bool

If extra post tabs are hidden (replies, media).

§muted: Vec<String>

A list of strings the user has muted.

§paged_timelines: bool

If timelines are paged instead of infinitely scrolled.

§enable_drawings: bool

If drawings are enabled for questions sent to the user.

§auto_unlist: bool

Automatically unlist posts from timelines.

§all_timeline_hide_answers: bool

Hide posts that are answering a question on the “All” timeline.

§auto_clear_notifs: bool

Automatically clear all notifications when notifications are viewed.

§large_text: bool

Increase the text size of buttons and paragraphs.

§disable_achievements: bool

Disable achievements.

§hide_associated_blocked_users: bool

Automatically hide users that you’ve blocked on your other accounts from your timelines.

§default_profile_tab: DefaultProfileTabChoice

Which tab is shown by default on the user’s profile.

§hide_from_social_lists: bool

If the user is hidden from followers/following tabs.

The user will still impact the followers/following numbers, but will not be shown in the UI (or API).

§auto_full_unlist: bool

Automatically hide your posts from all timelines except your profile and the following timeline.

§private_biography: String

Biography shown on profile/private.lisp page.

§hide_social_follows: bool

If the followers/following links are hidden from the user’s profile. Will also revoke access to their respective pages.

§mail_signature: String

The signature automatically attached to new mail letters.

§forum_signature: String

The signature automatically attached to new forum posts.

§no_transfers: bool

If coin transfer requests are disabled.

§enable_shop: bool

If your profile has the “Shop” tab enabled.

§hide_username_badges: bool

Hide all badges from your username (everywhere but on profile).

Trait Implementations§

Source§

impl Clone for UserSettings

Source§

fn clone(&self) -> UserSettings

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for UserSettings

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for UserSettings

Source§

fn default() -> UserSettings

Returns the “default value” for a type. Read more
Source§

impl<'de> Deserialize<'de> for UserSettings

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl Serialize for UserSettings

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> PolicyExt for T
where T: ?Sized,

Source§

fn and<P, B, E>(self, other: P) -> And<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow only if self and other return Action::Follow. Read more
Source§

fn or<P, B, E>(self, other: P) -> Or<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow if either self or other returns Action::Follow. Read more
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<T> ErasedDestructor for T
where T: 'static,