// @generated by jacquard-lexicon. DO NOT EDIT.
//
// Lexicon: net.anisota.settings
//
// This file was automatically generated from Lexicon schemas.
// Any manual changes will be overwritten on the next regeneration.

#[allow(unused_imports)]
use alloc::collections::BTreeMap;

#[allow(unused_imports)]
use core::marker::PhantomData;
use jacquard_common::{CowStr, BosStr, DefaultStr, FromStaticStr};

#[allow(unused_imports)]
use jacquard_common::deps::codegen::unicode_segmentation::UnicodeSegmentation;
use jacquard_common::deps::smol_str::SmolStr;
use jacquard_common::types::collection::{Collection, RecordError};
use jacquard_common::types::string::{AtUri, Cid, Datetime};
use jacquard_common::types::uri::{RecordUri, UriError};
use jacquard_common::types::value::Data;
use jacquard_common::xrpc::XrpcResp;
use jacquard_derive::{IntoStatic, lexicon};
use jacquard_lexicon::lexicon::LexiconDoc;
use jacquard_lexicon::schema::LexiconSchema;

#[allow(unused_imports)]
use jacquard_lexicon::validation::{ConstraintError, ValidationPath};
use serde::{Serialize, Deserialize};
use crate::net_anisota::settings;
/// Animation timing and speed settings for various UI animations

#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic, Default)]
#[serde(rename_all = "camelCase", bound(deserialize = "S: Deserialize<'de> + BosStr"))]
pub struct AnimationTiming<S: BosStr = DefaultStr> {
    ///Card advance exit to right and entrance back in from right (stored as string)
    #[serde(skip_serializing_if = "Option::is_none")]
    pub card_advance: Option<S>,
    ///Card flip animation between front and back (stored as string)
    #[serde(skip_serializing_if = "Option::is_none")]
    pub card_flip: Option<S>,
    ///Card stack animate in entrance from the top of screen (stored as string)
    #[serde(skip_serializing_if = "Option::is_none")]
    pub card_stack_entrance: Option<S>,
    ///Staggered interactive corner element entrance animation (stored as string)
    #[serde(skip_serializing_if = "Option::is_none")]
    pub corner_elements: Option<S>,
    ///Card stack height expansion and shrinking when entering/exiting fullscreen (stored as string)
    #[serde(skip_serializing_if = "Option::is_none")]
    pub fullscreen_transitions: Option<S>,
    ///Modal entrance and exit animations (stored as string)
    #[serde(skip_serializing_if = "Option::is_none")]
    pub modals: Option<S>,
    ///Master speed multiplier that affects all animations (stored as string, e.g. '1.0' = normal speed)
    #[serde(skip_serializing_if = "Option::is_none")]
    pub overall: Option<S>,
    ///Page transitions and navigation animations (stored as string)
    #[serde(skip_serializing_if = "Option::is_none")]
    pub page_transitions: Option<S>,
    ///Thread train sliding, entering, and exiting animations (stored as string)
    #[serde(skip_serializing_if = "Option::is_none")]
    pub thread_transitions: Option<S>,
    ///Control row and feed subtitle fade in/out animations (stored as string)
    #[serde(skip_serializing_if = "Option::is_none")]
    pub ui_transitions: Option<S>,
    #[serde(flatten, default, skip_serializing_if = "Option::is_none")]
    pub extra_data: Option<BTreeMap<SmolStr, Data<S>>>,
}


#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic, Default)]
#[serde(rename_all = "camelCase", bound(deserialize = "S: Deserialize<'de> + BosStr"))]
pub struct BatchNotificationTypes<S: BosStr = DefaultStr> {
    ///Batch follow notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub follows: Option<bool>,
    ///Batch like notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub likes: Option<bool>,
    ///Batch mention notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub mentions: Option<bool>,
    ///Batch quote notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub quotes: Option<bool>,
    ///Batch reply notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub replies: Option<bool>,
    ///Batch repost notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub reposts: Option<bool>,
    #[serde(flatten, default, skip_serializing_if = "Option::is_none")]
    pub extra_data: Option<BTreeMap<SmolStr, Data<S>>>,
}

/// App behavior and functionality settings

#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic, Default)]
#[serde(rename_all = "camelCase", bound(deserialize = "S: Deserialize<'de> + BosStr"))]
pub struct BehaviorSettings<S: BosStr = DefaultStr> {
    #[serde(skip_serializing_if = "Option::is_none")]
    pub animation_timing: Option<settings::AnimationTiming<S>>,
    ///Show only Anisota posts in profiles instead of regular Bluesky posts
    #[serde(skip_serializing_if = "Option::is_none")]
    pub anisota_only_mode: Option<bool>,
    ///Whether background audio/soundscapes are enabled by default
    #[serde(skip_serializing_if = "Option::is_none")]
    pub audio_enabled: Option<bool>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub batch_notification_types: Option<settings::BatchNotificationTypes<S>>,
    ///Group similar notifications together
    #[serde(skip_serializing_if = "Option::is_none")]
    pub batch_notifications: Option<bool>,
    ///Bypass detached quotes to see the full content that was removed by the author
    #[serde(skip_serializing_if = "Option::is_none")]
    pub bypass_detached_quotes: Option<bool>,
    ///When enabled, show notifications that match either relationship OR follower count filters
    #[serde(skip_serializing_if = "Option::is_none")]
    pub combine_relationship_and_follower_filters: Option<bool>,
    ///Show confirmation before deleting
    #[serde(skip_serializing_if = "Option::is_none")]
    pub confirm_deletes: Option<bool>,
    ///Show warning before saving drafts
    #[serde(skip_serializing_if = "Option::is_none")]
    pub confirm_draft_saves: Option<bool>,
    ///Default page to show on app load
    #[serde(skip_serializing_if = "Option::is_none")]
    pub default_home_page: Option<S>,
    ///Default publishing target for new posts
    #[serde(skip_serializing_if = "Option::is_none")]
    pub default_post_target: Option<S>,
    ///How long to cache feed position in minutes (30, 60, 360, 720, 1440, 10080)
    #[serde(skip_serializing_if = "Option::is_none")]
    pub feed_cache_length: Option<i64>,
    ///Filter by follower to following ratio
    #[serde(skip_serializing_if = "Option::is_none")]
    pub filter_by_follower_ratio: Option<bool>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub filter_notification_types: Option<settings::FilterNotificationTypes<S>>,
    ///Filter notifications by follower count
    #[serde(skip_serializing_if = "Option::is_none")]
    pub filter_notifications_by_followers: Option<bool>,
    ///Filter notifications based on relationship with the author
    #[serde(skip_serializing_if = "Option::is_none")]
    pub filter_notifications_by_relationship: Option<bool>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub filter_relationship_types: Option<settings::FilterRelationshipTypes<S>>,
    ///Force chronological sorting of posts
    #[serde(skip_serializing_if = "Option::is_none")]
    pub force_chronological_sort: Option<bool>,
    ///Fullscreen behavior mode: fullscreen (show control row), immersive (hide all UI), or cycle (cycle through states)
    #[serde(skip_serializing_if = "Option::is_none")]
    pub fullscreen_behavior: Option<S>,
    ///Hide posts that have been liked or reposted to focus on new content
    #[serde(skip_serializing_if = "Option::is_none")]
    pub hide_interacted_posts: Option<bool>,
    ///Hide the exact notification count in the corner element, always showing 'notifications' instead
    #[serde(skip_serializing_if = "Option::is_none")]
    pub hide_notification_count: Option<bool>,
    ///Hide posts that have been read
    #[serde(skip_serializing_if = "Option::is_none")]
    pub hide_read_posts: Option<bool>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub hide_reposts: Option<settings::HideReposts<S>>,
    ///Also require a minimum follower-to-following ratio for highlighting
    #[serde(skip_serializing_if = "Option::is_none")]
    pub highlight_by_follower_ratio: Option<bool>,
    ///Maximum follower count for notification highlighting
    #[serde(skip_serializing_if = "Option::is_none")]
    pub highlight_max_follower_count: Option<i64>,
    ///Minimum follower count for notification highlighting (stored as string or integer)
    #[serde(skip_serializing_if = "Option::is_none")]
    pub highlight_min_follower_count: Option<S>,
    ///Minimum follower-to-following ratio for highlighting (stored as string)
    #[serde(skip_serializing_if = "Option::is_none")]
    pub highlight_min_follower_ratio: Option<S>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub highlight_notification_types: Option<settings::HighlightNotificationTypes<S>>,
    ///Enable notification highlighting to surface important notifications from notable accounts
    #[serde(skip_serializing_if = "Option::is_none")]
    pub highlight_notifications: Option<bool>,
    ///Include engagement metrics from reply posts in stats calculations
    #[serde(skip_serializing_if = "Option::is_none")]
    pub include_reply_engagement: Option<bool>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub keyboard_shortcuts: Option<settings::KeyboardShortcuts<S>>,
    ///Maximum follower count for notification filtering
    #[serde(skip_serializing_if = "Option::is_none")]
    pub max_follower_count: Option<i64>,
    ///Minimum follower count for notification filtering (stored as string)
    #[serde(skip_serializing_if = "Option::is_none")]
    pub min_follower_count: Option<S>,
    ///Minimum follower ratio for filtering (stored as string)
    #[serde(skip_serializing_if = "Option::is_none")]
    pub min_follower_ratio: Option<S>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub moderation_settings: Option<settings::ModerationSettings<S>>,
    ///Enable post drafts feature
    #[serde(skip_serializing_if = "Option::is_none")]
    pub post_drafts: Option<bool>,
    ///Show newest posts first
    #[serde(skip_serializing_if = "Option::is_none")]
    pub reverse_feed_order: Option<bool>,
    ///Show content from users you have blocked
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_blocked_posts: Option<bool>,
    ///Show New Highlights section in notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_new_highlights_section: Option<bool>,
    ///Enable notification sections (New Highlights, Unread, Recently Read, Older)
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_notification_sections: Option<bool>,
    ///Show Older section in notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_older_section: Option<bool>,
    ///Display rarity indicator and rate in the stats modal header
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_rarity_in_header: Option<bool>,
    ///Show Recently Read section in notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_recently_read_section: Option<bool>,
    ///Show thread suggestion when typing beyond character limit in post composer
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_thread_suggestion: Option<bool>,
    ///Show Unread section in notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_unread_section: Option<bool>,
    ///Selected background audio soundscape
    #[serde(skip_serializing_if = "Option::is_none")]
    pub soundscape: Option<S>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub stats_visible_sections: Option<settings::StatsVisibleSections<S>>,
    ///Filter out posts with images and videos for distraction-free reading
    #[serde(skip_serializing_if = "Option::is_none")]
    pub text_only_mode: Option<bool>,
    ///Track which posts have been read
    #[serde(skip_serializing_if = "Option::is_none")]
    pub track_read_posts: Option<bool>,
    #[serde(flatten, default, skip_serializing_if = "Option::is_none")]
    pub extra_data: Option<BTreeMap<SmolStr, Data<S>>>,
}

/// Control button visibility settings

#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic, Default)]
#[serde(rename_all = "camelCase", bound(deserialize = "S: Deserialize<'de> + BosStr"))]
pub struct ControlSettings<S: BosStr = DefaultStr> {
    ///Show account list button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub account_list: Option<bool>,
    ///Show back button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub back: Option<bool>,
    ///Show expandable comment button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub comment_button: Option<bool>,
    ///Show copy author DID button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub copy_author_did: Option<bool>,
    ///Show expandable copy button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub copy_button: Option<bool>,
    ///Show copy post link button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub copy_post_link: Option<bool>,
    ///Show copy post text button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub copy_post_text: Option<bool>,
    ///Show delete button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub delete: Option<bool>,
    ///Show expandable engage button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub engage_button: Option<bool>,
    ///Show feed switcher button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub feed_switcher: Option<bool>,
    ///Show fetch button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub fetch: Option<bool>,
    ///Show flip button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub flip: Option<bool>,
    ///Show forward button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub forward: Option<bool>,
    ///Show fullscreen button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub fullscreen: Option<bool>,
    ///Show leaflet publications button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub leaflet_publications: Option<bool>,
    ///Show like button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub like: Option<bool>,
    ///Show list button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub list: Option<bool>,
    ///Show expandable multi-engage button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub multi_engage_button: Option<bool>,
    ///Show expandable multi-repost button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub multi_repost_button: Option<bool>,
    ///Show position button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub position_button: Option<bool>,
    ///Show post list button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub post_list: Option<bool>,
    ///Show quick access button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub quick_access: Option<bool>,
    ///Show quote button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub quote: Option<bool>,
    ///Show relationship button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub relationship_button: Option<bool>,
    ///Show reply button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub reply: Option<bool>,
    ///Show repost button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub repost: Option<bool>,
    ///Show shuffle button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub shuffle: Option<bool>,
    ///Show text only mode button
    #[serde(skip_serializing_if = "Option::is_none")]
    pub text_only_mode: Option<bool>,
    #[serde(flatten, default, skip_serializing_if = "Option::is_none")]
    pub extra_data: Option<BTreeMap<SmolStr, Data<S>>>,
}

/// Corner element positioning settings

#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic, Default)]
#[serde(rename_all = "camelCase", bound(deserialize = "S: Deserialize<'de> + BosStr"))]
pub struct CornerElements<S: BosStr = DefaultStr> {
    ///Element to show in bottom left corner
    #[serde(skip_serializing_if = "Option::is_none")]
    pub bottom_left: Option<S>,
    ///Element to show in bottom right corner
    #[serde(skip_serializing_if = "Option::is_none")]
    pub bottom_right: Option<S>,
    ///Element to show in top left corner
    #[serde(skip_serializing_if = "Option::is_none")]
    pub top_left: Option<S>,
    ///Element to show in top right corner
    #[serde(skip_serializing_if = "Option::is_none")]
    pub top_right: Option<S>,
    #[serde(flatten, default, skip_serializing_if = "Option::is_none")]
    pub extra_data: Option<BTreeMap<SmolStr, Data<S>>>,
}


#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic, Default)]
#[serde(rename_all = "camelCase", bound(deserialize = "S: Deserialize<'de> + BosStr"))]
pub struct FilterNotificationTypes<S: BosStr = DefaultStr> {
    ///Show follow notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub follows: Option<bool>,
    ///Show like notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub likes: Option<bool>,
    ///Show mention notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub mentions: Option<bool>,
    ///Show quote notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub quotes: Option<bool>,
    ///Show reply notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub replies: Option<bool>,
    ///Show repost notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub reposts: Option<bool>,
    #[serde(flatten, default, skip_serializing_if = "Option::is_none")]
    pub extra_data: Option<BTreeMap<SmolStr, Data<S>>>,
}


#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic, Default)]
#[serde(rename_all = "camelCase", bound(deserialize = "S: Deserialize<'de> + BosStr"))]
pub struct FilterRelationshipTypes<S: BosStr = DefaultStr> {
    ///Show notifications from followers
    #[serde(skip_serializing_if = "Option::is_none")]
    pub followers: Option<bool>,
    ///Show notifications from accounts you follow
    #[serde(skip_serializing_if = "Option::is_none")]
    pub following: Option<bool>,
    ///Show notifications from mutual connections
    #[serde(skip_serializing_if = "Option::is_none")]
    pub mutuals: Option<bool>,
    ///Show notifications from followers you don't follow back
    #[serde(skip_serializing_if = "Option::is_none")]
    pub non_mutuals: Option<bool>,
    #[serde(flatten, default, skip_serializing_if = "Option::is_none")]
    pub extra_data: Option<BTreeMap<SmolStr, Data<S>>>,
}


#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic, Default)]
#[serde(rename_all = "camelCase", bound(deserialize = "S: Deserialize<'de> + BosStr"))]
pub struct HideReposts<S: BosStr = DefaultStr> {
    ///Hide reposts in feed
    #[serde(skip_serializing_if = "Option::is_none")]
    pub feed: Option<bool>,
    ///Hide reposts in profile
    #[serde(skip_serializing_if = "Option::is_none")]
    pub profile: Option<bool>,
    #[serde(flatten, default, skip_serializing_if = "Option::is_none")]
    pub extra_data: Option<BTreeMap<SmolStr, Data<S>>>,
}


#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic, Default)]
#[serde(rename_all = "camelCase", bound(deserialize = "S: Deserialize<'de> + BosStr"))]
pub struct HighlightNotificationTypes<S: BosStr = DefaultStr> {
    ///Highlight follow notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub follows: Option<bool>,
    ///Highlight like notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub likes: Option<bool>,
    ///Highlight mention notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub mentions: Option<bool>,
    ///Highlight quote notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub quotes: Option<bool>,
    ///Highlight reply notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub replies: Option<bool>,
    ///Highlight repost notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub reposts: Option<bool>,
    #[serde(flatten, default, skip_serializing_if = "Option::is_none")]
    pub extra_data: Option<BTreeMap<SmolStr, Data<S>>>,
}

/// Keyboard shortcut configuration

#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic, Default)]
#[serde(rename_all = "camelCase", bound(deserialize = "S: Deserialize<'de> + BosStr"))]
pub struct KeyboardShortcuts<S: BosStr = DefaultStr> {
    #[serde(skip_serializing_if = "Option::is_none")]
    pub composer: Option<settings::KeyboardShortcutsComposer<S>>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub global: Option<settings::KeyboardShortcutsGlobal<S>>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub modals: Option<settings::KeyboardShortcutsModals<S>>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub navigation: Option<settings::KeyboardShortcutsNavigation<S>>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub post_interactions: Option<settings::KeyboardShortcutsPostInteractions<S>>,
    #[serde(flatten, default, skip_serializing_if = "Option::is_none")]
    pub extra_data: Option<BTreeMap<SmolStr, Data<S>>>,
}

/// Post composer keyboard shortcuts

#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic, Default)]
#[serde(rename_all = "camelCase", bound(deserialize = "S: Deserialize<'de> + BosStr"))]
pub struct KeyboardShortcutsComposer<S: BosStr = DefaultStr> {
    ///Publish post (e.g., ctrl+enter)
    #[serde(skip_serializing_if = "Option::is_none")]
    pub publish: Option<S>,
    #[serde(flatten, default, skip_serializing_if = "Option::is_none")]
    pub extra_data: Option<BTreeMap<SmolStr, Data<S>>>,
}

/// Global navigation keyboard shortcuts

#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic, Default)]
#[serde(rename_all = "camelCase", bound(deserialize = "S: Deserialize<'de> + BosStr"))]
pub struct KeyboardShortcutsGlobal<S: BosStr = DefaultStr> {
    ///Navigate to collection
    #[serde(skip_serializing_if = "Option::is_none")]
    pub collection: Option<S>,
    ///Navigate to feed
    #[serde(skip_serializing_if = "Option::is_none")]
    pub feed: Option<S>,
    ///Navigate to inventory
    #[serde(skip_serializing_if = "Option::is_none")]
    pub inventory: Option<S>,
    ///Navigate to profile
    #[serde(skip_serializing_if = "Option::is_none")]
    pub profile: Option<S>,
    #[serde(flatten, default, skip_serializing_if = "Option::is_none")]
    pub extra_data: Option<BTreeMap<SmolStr, Data<S>>>,
}

/// Modal keyboard shortcuts

#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic, Default)]
#[serde(rename_all = "camelCase", bound(deserialize = "S: Deserialize<'de> + BosStr"))]
pub struct KeyboardShortcutsModals<S: BosStr = DefaultStr> {
    ///Show keyboard shortcuts help
    #[serde(skip_serializing_if = "Option::is_none")]
    pub keyboard_help: Option<S>,
    ///Open notifications
    #[serde(skip_serializing_if = "Option::is_none")]
    pub notifications: Option<S>,
    ///Open post composer
    #[serde(skip_serializing_if = "Option::is_none")]
    pub post_composer: Option<S>,
    ///Open stats modal
    #[serde(skip_serializing_if = "Option::is_none")]
    pub stats: Option<S>,
    ///Open touch menu
    #[serde(skip_serializing_if = "Option::is_none")]
    pub touch_menu: Option<S>,
    #[serde(flatten, default, skip_serializing_if = "Option::is_none")]
    pub extra_data: Option<BTreeMap<SmolStr, Data<S>>>,
}

/// Navigation keyboard shortcuts

#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic, Default)]
#[serde(rename_all = "camelCase", bound(deserialize = "S: Deserialize<'de> + BosStr"))]
pub struct KeyboardShortcutsNavigation<S: BosStr = DefaultStr> {
    ///Scroll down or next item
    #[serde(skip_serializing_if = "Option::is_none")]
    pub arrow_down: Option<S>,
    ///Go back to previous card
    #[serde(skip_serializing_if = "Option::is_none")]
    pub arrow_left: Option<S>,
    ///Advance to next card
    #[serde(skip_serializing_if = "Option::is_none")]
    pub arrow_right: Option<S>,
    ///Scroll up or previous item
    #[serde(skip_serializing_if = "Option::is_none")]
    pub arrow_up: Option<S>,
    ///Exit fullscreen or close modals
    #[serde(skip_serializing_if = "Option::is_none")]
    pub escape: Option<S>,
    #[serde(flatten, default, skip_serializing_if = "Option::is_none")]
    pub extra_data: Option<BTreeMap<SmolStr, Data<S>>>,
}

/// Post interaction keyboard shortcuts

#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic, Default)]
#[serde(rename_all = "camelCase", bound(deserialize = "S: Deserialize<'de> + BosStr"))]
pub struct KeyboardShortcutsPostInteractions<S: BosStr = DefaultStr> {
    ///Like current post
    #[serde(skip_serializing_if = "Option::is_none")]
    pub like: Option<S>,
    ///Quote current post
    #[serde(skip_serializing_if = "Option::is_none")]
    pub quote: Option<S>,
    ///Reply to current post
    #[serde(skip_serializing_if = "Option::is_none")]
    pub reply: Option<S>,
    ///Repost current post
    #[serde(skip_serializing_if = "Option::is_none")]
    pub repost: Option<S>,
    #[serde(flatten, default, skip_serializing_if = "Option::is_none")]
    pub extra_data: Option<BTreeMap<SmolStr, Data<S>>>,
}

/// User settings for the Anisota app, synchronized across devices via ATProto

#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic)]
#[serde(
    rename_all = "camelCase",
    rename = "net.anisota.settings",
    tag = "$type",
    bound(deserialize = "S: Deserialize<'de> + BosStr")
)]
pub struct Settings<S: BosStr = DefaultStr> {
    #[serde(skip_serializing_if = "Option::is_none")]
    pub behavior_settings: Option<settings::BehaviorSettings<S>>,
    ///Order of control buttons
    #[serde(skip_serializing_if = "Option::is_none")]
    pub control_order: Option<Vec<S>>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub control_settings: Option<settings::ControlSettings<S>>,
    ///When the settings record was first created
    pub created_at: Datetime,
    ///Selected color theme
    #[serde(skip_serializing_if = "Option::is_none")]
    pub theme: Option<S>,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub ui_settings: Option<settings::UiSettings<S>>,
    ///When the settings were last updated
    pub updated_at: Datetime,
    ///Settings schema version for backward compatibility
    pub version: i64,
    #[serde(flatten, default, skip_serializing_if = "Option::is_none")]
    pub extra_data: Option<BTreeMap<SmolStr, Data<S>>>,
}

/// Typed wrapper for GetRecord response with this collection's record type.

#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic)]
#[serde(rename_all = "camelCase")]
pub struct SettingsGetRecordOutput<S: BosStr = DefaultStr> {
    #[serde(skip_serializing_if = "Option::is_none")]
    pub cid: Option<Cid<S>>,
    pub uri: AtUri<S>,
    pub value: Settings<S>,
}

/// Content moderation and filtering settings

#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic, Default)]
#[serde(rename_all = "camelCase", bound(deserialize = "S: Deserialize<'de> + BosStr"))]
pub struct ModerationSettings<S: BosStr = DefaultStr> {
    ///How to handle posts from muted accounts
    #[serde(skip_serializing_if = "Option::is_none")]
    pub muted_accounts_handling: Option<S>,
    ///How to handle posts containing muted words or phrases
    #[serde(skip_serializing_if = "Option::is_none")]
    pub muted_content_handling: Option<S>,
    #[serde(flatten, default, skip_serializing_if = "Option::is_none")]
    pub extra_data: Option<BTreeMap<SmolStr, Data<S>>>,
}


#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic, Default)]
#[serde(rename_all = "camelCase", bound(deserialize = "S: Deserialize<'de> + BosStr"))]
pub struct StatsVisibleSections<S: BosStr = DefaultStr> {
    ///Show activity section in stats overview
    #[serde(skip_serializing_if = "Option::is_none")]
    pub activity: Option<bool>,
    ///Show engagement section in stats overview
    #[serde(skip_serializing_if = "Option::is_none")]
    pub engagement: Option<bool>,
    ///Show progress section in stats overview
    #[serde(skip_serializing_if = "Option::is_none")]
    pub progress: Option<bool>,
    #[serde(flatten, default, skip_serializing_if = "Option::is_none")]
    pub extra_data: Option<BTreeMap<SmolStr, Data<S>>>,
}

/// UI visibility and behavior settings

#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, IntoStatic, Default)]
#[serde(rename_all = "camelCase", bound(deserialize = "S: Deserialize<'de> + BosStr"))]
pub struct UiSettings<S: BosStr = DefaultStr> {
    #[serde(skip_serializing_if = "Option::is_none")]
    pub corner_elements: Option<settings::CornerElements<S>>,
    ///Font size scale (0.8 = 80%, 1.0 = 100% default, 1.2 = 120%)
    #[serde(skip_serializing_if = "Option::is_none")]
    pub font_size: Option<S>,
    ///Primary name slot for post cards
    #[serde(skip_serializing_if = "Option::is_none")]
    pub post_card_primary_slot: Option<S>,
    ///Secondary name slot for post cards
    #[serde(skip_serializing_if = "Option::is_none")]
    pub post_card_secondary_slot: Option<S>,
    ///Primary name slot for profile cards
    #[serde(skip_serializing_if = "Option::is_none")]
    pub profile_card_primary_slot: Option<S>,
    ///Secondary name slot for profile cards
    #[serde(skip_serializing_if = "Option::is_none")]
    pub profile_card_secondary_slot: Option<S>,
    ///Show Bluesky icon in post card headers
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_post_card_at_symbol: Option<bool>,
    ///Show avatar image in post card footer
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_post_card_avatar: Option<bool>,
    ///Show display name on post cards
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_post_card_display_name: Option<bool>,
    ///Show the entire post card footer section
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_post_card_footer: Option<bool>,
    ///Show handle/username on post cards
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_post_card_handle: Option<bool>,
    ///Show the entire post card header section
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_post_card_header: Option<bool>,
    ///Show post number indicator
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_post_count: Option<bool>,
    ///Show indicator for posts that have been read
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_post_read_indicator: Option<bool>,
    ///Show Bluesky icon on profile cards
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_at_symbol: Option<bool>,
    ///Show blocked count on profiles
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_blocked: Option<bool>,
    ///Show blocking count on profiles
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_blocking: Option<bool>,
    ///Show cancelled count on profiles
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_cancelled: Option<bool>,
    ///Show cancelling count on profiles
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_cancelling: Option<bool>,
    ///Show avatar image in profile card footer
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_card_avatar: Option<bool>,
    ///Show the entire profile card footer section
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_card_footer: Option<bool>,
    ///Show the entire profile card header section
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_card_header: Option<bool>,
    ///Show collection count on profiles
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_collections: Option<bool>,
    ///Show display name on profile cards
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_display_name: Option<bool>,
    ///Show follower count on profiles
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_followers: Option<bool>,
    ///Show following count on profiles
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_following: Option<bool>,
    ///Show handle/username on profile cards
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_handle: Option<bool>,
    ///Show lexicon count on profiles
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_lexicons: Option<bool>,
    ///Show listed count on profiles
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_listed: Option<bool>,
    ///Show listing count on profiles
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_listing: Option<bool>,
    ///Show lists count on profiles
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_lists: Option<bool>,
    ///Show post count on profiles
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_posts: Option<bool>,
    ///Show pronouns on profile cards
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_pronouns: Option<bool>,
    ///Show verified count on profiles
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_verified: Option<bool>,
    ///Show verifying count on profiles
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_verifying: Option<bool>,
    ///Show website link on profile cards
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_profile_website: Option<bool>,
    ///Show rarity indicator based on post engagement
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_rarity_indicator: Option<bool>,
    ///Show when the post was created
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_timestamp: Option<bool>,
    ///Show author username on posts
    #[serde(skip_serializing_if = "Option::is_none")]
    pub show_username: Option<bool>,
    #[serde(flatten, default, skip_serializing_if = "Option::is_none")]
    pub extra_data: Option<BTreeMap<SmolStr, Data<S>>>,
}

impl<S: BosStr> Settings<S> {
    pub fn uri(uri: S) -> Result<RecordUri<S, SettingsRecord>, UriError> {
        RecordUri::try_from_uri(AtUri::new(uri)?)
    }
}

impl<S: BosStr> LexiconSchema for AnimationTiming<S> {
    fn nsid() -> &'static str {
        "net.anisota.settings"
    }
    fn def_name() -> &'static str {
        "animationTiming"
    }
    fn lexicon_doc() -> LexiconDoc<'static> {
        lexicon_doc_net_anisota_settings()
    }
    fn validate(&self) -> Result<(), ConstraintError> {
        if let Some(ref value) = self.card_advance {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 10usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("card_advance"),
                    max: 10usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.card_flip {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 10usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("card_flip"),
                    max: 10usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.card_stack_entrance {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 10usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("card_stack_entrance"),
                    max: 10usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.corner_elements {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 10usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("corner_elements"),
                    max: 10usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.fullscreen_transitions {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 10usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("fullscreen_transitions"),
                    max: 10usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.modals {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 10usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("modals"),
                    max: 10usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.overall {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 10usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("overall"),
                    max: 10usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.page_transitions {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 10usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("page_transitions"),
                    max: 10usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.thread_transitions {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 10usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("thread_transitions"),
                    max: 10usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.ui_transitions {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 10usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("ui_transitions"),
                    max: 10usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        Ok(())
    }
}

impl<S: BosStr> LexiconSchema for BatchNotificationTypes<S> {
    fn nsid() -> &'static str {
        "net.anisota.settings"
    }
    fn def_name() -> &'static str {
        "batchNotificationTypes"
    }
    fn lexicon_doc() -> LexiconDoc<'static> {
        lexicon_doc_net_anisota_settings()
    }
    fn validate(&self) -> Result<(), ConstraintError> {
        Ok(())
    }
}

impl<S: BosStr> LexiconSchema for BehaviorSettings<S> {
    fn nsid() -> &'static str {
        "net.anisota.settings"
    }
    fn def_name() -> &'static str {
        "behaviorSettings"
    }
    fn lexicon_doc() -> LexiconDoc<'static> {
        lexicon_doc_net_anisota_settings()
    }
    fn validate(&self) -> Result<(), ConstraintError> {
        if let Some(ref value) = self.feed_cache_length {
            if *value < 1i64 {
                return Err(ConstraintError::Minimum {
                    path: ValidationPath::from_field("feed_cache_length"),
                    min: 1i64,
                    actual: *value,
                });
            }
        }
        if let Some(ref value) = self.highlight_min_follower_count {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 20usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("highlight_min_follower_count"),
                    max: 20usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.highlight_min_follower_ratio {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 20usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("highlight_min_follower_ratio"),
                    max: 20usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.min_follower_count {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 20usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("min_follower_count"),
                    max: 20usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.min_follower_ratio {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 20usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("min_follower_ratio"),
                    max: 20usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        Ok(())
    }
}

impl<S: BosStr> LexiconSchema for ControlSettings<S> {
    fn nsid() -> &'static str {
        "net.anisota.settings"
    }
    fn def_name() -> &'static str {
        "controlSettings"
    }
    fn lexicon_doc() -> LexiconDoc<'static> {
        lexicon_doc_net_anisota_settings()
    }
    fn validate(&self) -> Result<(), ConstraintError> {
        Ok(())
    }
}

impl<S: BosStr> LexiconSchema for CornerElements<S> {
    fn nsid() -> &'static str {
        "net.anisota.settings"
    }
    fn def_name() -> &'static str {
        "cornerElements"
    }
    fn lexicon_doc() -> LexiconDoc<'static> {
        lexicon_doc_net_anisota_settings()
    }
    fn validate(&self) -> Result<(), ConstraintError> {
        Ok(())
    }
}

impl<S: BosStr> LexiconSchema for FilterNotificationTypes<S> {
    fn nsid() -> &'static str {
        "net.anisota.settings"
    }
    fn def_name() -> &'static str {
        "filterNotificationTypes"
    }
    fn lexicon_doc() -> LexiconDoc<'static> {
        lexicon_doc_net_anisota_settings()
    }
    fn validate(&self) -> Result<(), ConstraintError> {
        Ok(())
    }
}

impl<S: BosStr> LexiconSchema for FilterRelationshipTypes<S> {
    fn nsid() -> &'static str {
        "net.anisota.settings"
    }
    fn def_name() -> &'static str {
        "filterRelationshipTypes"
    }
    fn lexicon_doc() -> LexiconDoc<'static> {
        lexicon_doc_net_anisota_settings()
    }
    fn validate(&self) -> Result<(), ConstraintError> {
        Ok(())
    }
}

impl<S: BosStr> LexiconSchema for HideReposts<S> {
    fn nsid() -> &'static str {
        "net.anisota.settings"
    }
    fn def_name() -> &'static str {
        "hideReposts"
    }
    fn lexicon_doc() -> LexiconDoc<'static> {
        lexicon_doc_net_anisota_settings()
    }
    fn validate(&self) -> Result<(), ConstraintError> {
        Ok(())
    }
}

impl<S: BosStr> LexiconSchema for HighlightNotificationTypes<S> {
    fn nsid() -> &'static str {
        "net.anisota.settings"
    }
    fn def_name() -> &'static str {
        "highlightNotificationTypes"
    }
    fn lexicon_doc() -> LexiconDoc<'static> {
        lexicon_doc_net_anisota_settings()
    }
    fn validate(&self) -> Result<(), ConstraintError> {
        Ok(())
    }
}

impl<S: BosStr> LexiconSchema for KeyboardShortcuts<S> {
    fn nsid() -> &'static str {
        "net.anisota.settings"
    }
    fn def_name() -> &'static str {
        "keyboardShortcuts"
    }
    fn lexicon_doc() -> LexiconDoc<'static> {
        lexicon_doc_net_anisota_settings()
    }
    fn validate(&self) -> Result<(), ConstraintError> {
        Ok(())
    }
}

impl<S: BosStr> LexiconSchema for KeyboardShortcutsComposer<S> {
    fn nsid() -> &'static str {
        "net.anisota.settings"
    }
    fn def_name() -> &'static str {
        "keyboardShortcutsComposer"
    }
    fn lexicon_doc() -> LexiconDoc<'static> {
        lexicon_doc_net_anisota_settings()
    }
    fn validate(&self) -> Result<(), ConstraintError> {
        if let Some(ref value) = self.publish {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 50usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("publish"),
                    max: 50usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        Ok(())
    }
}

impl<S: BosStr> LexiconSchema for KeyboardShortcutsGlobal<S> {
    fn nsid() -> &'static str {
        "net.anisota.settings"
    }
    fn def_name() -> &'static str {
        "keyboardShortcutsGlobal"
    }
    fn lexicon_doc() -> LexiconDoc<'static> {
        lexicon_doc_net_anisota_settings()
    }
    fn validate(&self) -> Result<(), ConstraintError> {
        if let Some(ref value) = self.collection {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 50usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("collection"),
                    max: 50usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.feed {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 50usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("feed"),
                    max: 50usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.inventory {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 50usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("inventory"),
                    max: 50usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.profile {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 50usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("profile"),
                    max: 50usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        Ok(())
    }
}

impl<S: BosStr> LexiconSchema for KeyboardShortcutsModals<S> {
    fn nsid() -> &'static str {
        "net.anisota.settings"
    }
    fn def_name() -> &'static str {
        "keyboardShortcutsModals"
    }
    fn lexicon_doc() -> LexiconDoc<'static> {
        lexicon_doc_net_anisota_settings()
    }
    fn validate(&self) -> Result<(), ConstraintError> {
        if let Some(ref value) = self.keyboard_help {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 50usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("keyboard_help"),
                    max: 50usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.notifications {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 50usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("notifications"),
                    max: 50usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.post_composer {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 50usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("post_composer"),
                    max: 50usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.stats {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 50usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("stats"),
                    max: 50usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.touch_menu {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 50usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("touch_menu"),
                    max: 50usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        Ok(())
    }
}

impl<S: BosStr> LexiconSchema for KeyboardShortcutsNavigation<S> {
    fn nsid() -> &'static str {
        "net.anisota.settings"
    }
    fn def_name() -> &'static str {
        "keyboardShortcutsNavigation"
    }
    fn lexicon_doc() -> LexiconDoc<'static> {
        lexicon_doc_net_anisota_settings()
    }
    fn validate(&self) -> Result<(), ConstraintError> {
        if let Some(ref value) = self.arrow_down {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 50usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("arrow_down"),
                    max: 50usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.arrow_left {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 50usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("arrow_left"),
                    max: 50usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.arrow_right {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 50usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("arrow_right"),
                    max: 50usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.arrow_up {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 50usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("arrow_up"),
                    max: 50usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.escape {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 50usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("escape"),
                    max: 50usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        Ok(())
    }
}

impl<S: BosStr> LexiconSchema for KeyboardShortcutsPostInteractions<S> {
    fn nsid() -> &'static str {
        "net.anisota.settings"
    }
    fn def_name() -> &'static str {
        "keyboardShortcutsPostInteractions"
    }
    fn lexicon_doc() -> LexiconDoc<'static> {
        lexicon_doc_net_anisota_settings()
    }
    fn validate(&self) -> Result<(), ConstraintError> {
        if let Some(ref value) = self.like {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 50usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("like"),
                    max: 50usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.quote {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 50usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("quote"),
                    max: 50usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.reply {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 50usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("reply"),
                    max: 50usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        if let Some(ref value) = self.repost {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 50usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("repost"),
                    max: 50usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        Ok(())
    }
}

/// Marker type for deserializing records from this collection.

#[derive(Debug, Serialize, Deserialize)]
pub struct SettingsRecord;
impl XrpcResp for SettingsRecord {
    const NSID: &'static str = "net.anisota.settings";
    const ENCODING: &'static str = "application/json";
    type Output<S: BosStr> = SettingsGetRecordOutput<S>;
    type Err = RecordError;
}

impl<S: BosStr> From<SettingsGetRecordOutput<S>> for Settings<S> {
    fn from(output: SettingsGetRecordOutput<S>) -> Self {
        output.value
    }
}

impl<S: BosStr> Collection for Settings<S> {
    const NSID: &'static str = "net.anisota.settings";
    type Record = SettingsRecord;
}

impl Collection for SettingsRecord {
    const NSID: &'static str = "net.anisota.settings";
    type Record = SettingsRecord;
}

impl<S: BosStr> LexiconSchema for Settings<S> {
    fn nsid() -> &'static str {
        "net.anisota.settings"
    }
    fn def_name() -> &'static str {
        "main"
    }
    fn lexicon_doc() -> LexiconDoc<'static> {
        lexicon_doc_net_anisota_settings()
    }
    fn validate(&self) -> Result<(), ConstraintError> {
        {
            let value = &self.version;
            if *value < 1i64 {
                return Err(ConstraintError::Minimum {
                    path: ValidationPath::from_field("version"),
                    min: 1i64,
                    actual: *value,
                });
            }
        }
        Ok(())
    }
}

impl<S: BosStr> LexiconSchema for ModerationSettings<S> {
    fn nsid() -> &'static str {
        "net.anisota.settings"
    }
    fn def_name() -> &'static str {
        "moderationSettings"
    }
    fn lexicon_doc() -> LexiconDoc<'static> {
        lexicon_doc_net_anisota_settings()
    }
    fn validate(&self) -> Result<(), ConstraintError> {
        Ok(())
    }
}

impl<S: BosStr> LexiconSchema for StatsVisibleSections<S> {
    fn nsid() -> &'static str {
        "net.anisota.settings"
    }
    fn def_name() -> &'static str {
        "statsVisibleSections"
    }
    fn lexicon_doc() -> LexiconDoc<'static> {
        lexicon_doc_net_anisota_settings()
    }
    fn validate(&self) -> Result<(), ConstraintError> {
        Ok(())
    }
}

impl<S: BosStr> LexiconSchema for UiSettings<S> {
    fn nsid() -> &'static str {
        "net.anisota.settings"
    }
    fn def_name() -> &'static str {
        "uiSettings"
    }
    fn lexicon_doc() -> LexiconDoc<'static> {
        lexicon_doc_net_anisota_settings()
    }
    fn validate(&self) -> Result<(), ConstraintError> {
        if let Some(ref value) = self.font_size {
            #[allow(unused_comparisons)]
            if <str>::len(value.as_ref()) > 10usize {
                return Err(ConstraintError::MaxLength {
                    path: ValidationPath::from_field("font_size"),
                    max: 10usize,
                    actual: <str>::len(value.as_ref()),
                });
            }
        }
        Ok(())
    }
}

fn lexicon_doc_net_anisota_settings() -> LexiconDoc<'static> {
    #[allow(unused_imports)]
    use jacquard_common::{CowStr, deps::smol_str::SmolStr, types::blob::MimeType};
    use jacquard_lexicon::lexicon::*;
    use alloc::collections::BTreeMap;
    LexiconDoc {
        lexicon: Lexicon::Lexicon1,
        id: CowStr::new_static("net.anisota.settings"),
        defs: {
            let mut map = BTreeMap::new();
            map.insert(
                SmolStr::new_static("animationTiming"),
                LexUserType::Object(LexObject {
                    description: Some(
                        CowStr::new_static(
                            "Animation timing and speed settings for various UI animations",
                        ),
                    ),
                    properties: {
                        #[allow(unused_mut)]
                        let mut map = BTreeMap::new();
                        map.insert(
                            SmolStr::new_static("cardAdvance"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static(
                                        "Card advance exit to right and entrance back in from right (stored as string)",
                                    ),
                                ),
                                max_length: Some(10usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("cardFlip"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static(
                                        "Card flip animation between front and back (stored as string)",
                                    ),
                                ),
                                max_length: Some(10usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("cardStackEntrance"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static(
                                        "Card stack animate in entrance from the top of screen (stored as string)",
                                    ),
                                ),
                                max_length: Some(10usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("cornerElements"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static(
                                        "Staggered interactive corner element entrance animation (stored as string)",
                                    ),
                                ),
                                max_length: Some(10usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("fullscreenTransitions"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static(
                                        "Card stack height expansion and shrinking when entering/exiting fullscreen (stored as string)",
                                    ),
                                ),
                                max_length: Some(10usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("modals"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static(
                                        "Modal entrance and exit animations (stored as string)",
                                    ),
                                ),
                                max_length: Some(10usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("overall"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static(
                                        "Master speed multiplier that affects all animations (stored as string, e.g. '1.0' = normal speed)",
                                    ),
                                ),
                                max_length: Some(10usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("pageTransitions"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static(
                                        "Page transitions and navigation animations (stored as string)",
                                    ),
                                ),
                                max_length: Some(10usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("threadTransitions"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static(
                                        "Thread train sliding, entering, and exiting animations (stored as string)",
                                    ),
                                ),
                                max_length: Some(10usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("uiTransitions"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static(
                                        "Control row and feed subtitle fade in/out animations (stored as string)",
                                    ),
                                ),
                                max_length: Some(10usize),
                                ..Default::default()
                            }),
                        );
                        map
                    },
                    ..Default::default()
                }),
            );
            map.insert(
                SmolStr::new_static("batchNotificationTypes"),
                LexUserType::Object(LexObject {
                    properties: {
                        #[allow(unused_mut)]
                        let mut map = BTreeMap::new();
                        map.insert(
                            SmolStr::new_static("follows"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("likes"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("mentions"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("quotes"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("replies"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("reposts"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map
                    },
                    ..Default::default()
                }),
            );
            map.insert(
                SmolStr::new_static("behaviorSettings"),
                LexUserType::Object(LexObject {
                    description: Some(
                        CowStr::new_static("App behavior and functionality settings"),
                    ),
                    properties: {
                        #[allow(unused_mut)]
                        let mut map = BTreeMap::new();
                        map.insert(
                            SmolStr::new_static("animationTiming"),
                            LexObjectProperty::Ref(LexRef {
                                r#ref: CowStr::new_static("#animationTiming"),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("anisotaOnlyMode"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("audioEnabled"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("batchNotificationTypes"),
                            LexObjectProperty::Ref(LexRef {
                                r#ref: CowStr::new_static("#batchNotificationTypes"),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("batchNotifications"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("bypassDetachedQuotes"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("combineRelationshipAndFollowerFilters"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("confirmDeletes"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("confirmDraftSaves"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("defaultHomePage"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Default page to show on app load"),
                                ),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("defaultPostTarget"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static(
                                        "Default publishing target for new posts",
                                    ),
                                ),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("feedCacheLength"),
                            LexObjectProperty::Integer(LexInteger {
                                minimum: Some(1i64),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("filterByFollowerRatio"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("filterNotificationTypes"),
                            LexObjectProperty::Ref(LexRef {
                                r#ref: CowStr::new_static("#filterNotificationTypes"),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("filterNotificationsByFollowers"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("filterNotificationsByRelationship"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("filterRelationshipTypes"),
                            LexObjectProperty::Ref(LexRef {
                                r#ref: CowStr::new_static("#filterRelationshipTypes"),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("forceChronologicalSort"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("fullscreenBehavior"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static(
                                        "Fullscreen behavior mode: fullscreen (show control row), immersive (hide all UI), or cycle (cycle through states)",
                                    ),
                                ),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("hideInteractedPosts"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("hideNotificationCount"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("hideReadPosts"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("hideReposts"),
                            LexObjectProperty::Ref(LexRef {
                                r#ref: CowStr::new_static("#hideReposts"),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("highlightByFollowerRatio"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("highlightMaxFollowerCount"),
                            LexObjectProperty::Integer(LexInteger {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("highlightMinFollowerCount"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static(
                                        "Minimum follower count for notification highlighting (stored as string or integer)",
                                    ),
                                ),
                                max_length: Some(20usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("highlightMinFollowerRatio"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static(
                                        "Minimum follower-to-following ratio for highlighting (stored as string)",
                                    ),
                                ),
                                max_length: Some(20usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("highlightNotificationTypes"),
                            LexObjectProperty::Ref(LexRef {
                                r#ref: CowStr::new_static("#highlightNotificationTypes"),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("highlightNotifications"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("includeReplyEngagement"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("keyboardShortcuts"),
                            LexObjectProperty::Ref(LexRef {
                                r#ref: CowStr::new_static("#keyboardShortcuts"),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("maxFollowerCount"),
                            LexObjectProperty::Integer(LexInteger {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("minFollowerCount"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static(
                                        "Minimum follower count for notification filtering (stored as string)",
                                    ),
                                ),
                                max_length: Some(20usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("minFollowerRatio"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static(
                                        "Minimum follower ratio for filtering (stored as string)",
                                    ),
                                ),
                                max_length: Some(20usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("moderationSettings"),
                            LexObjectProperty::Ref(LexRef {
                                r#ref: CowStr::new_static("#moderationSettings"),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("postDrafts"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("reverseFeedOrder"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showBlockedPosts"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showNewHighlightsSection"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showNotificationSections"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showOlderSection"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showRarityInHeader"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showRecentlyReadSection"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showThreadSuggestion"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showUnreadSection"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("soundscape"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Selected background audio soundscape"),
                                ),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("statsVisibleSections"),
                            LexObjectProperty::Ref(LexRef {
                                r#ref: CowStr::new_static("#statsVisibleSections"),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("textOnlyMode"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("trackReadPosts"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map
                    },
                    ..Default::default()
                }),
            );
            map.insert(
                SmolStr::new_static("controlSettings"),
                LexUserType::Object(LexObject {
                    description: Some(
                        CowStr::new_static("Control button visibility settings"),
                    ),
                    properties: {
                        #[allow(unused_mut)]
                        let mut map = BTreeMap::new();
                        map.insert(
                            SmolStr::new_static("accountList"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("back"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("commentButton"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("copyAuthorDID"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("copyButton"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("copyPostLink"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("copyPostText"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("delete"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("engageButton"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("feedSwitcher"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("fetch"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("flip"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("forward"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("fullscreen"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("leafletPublications"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("like"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("list"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("multiEngageButton"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("multiRepostButton"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("positionButton"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("postList"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("quickAccess"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("quote"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("relationshipButton"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("reply"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("repost"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("shuffle"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("textOnlyMode"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map
                    },
                    ..Default::default()
                }),
            );
            map.insert(
                SmolStr::new_static("cornerElements"),
                LexUserType::Object(LexObject {
                    description: Some(
                        CowStr::new_static("Corner element positioning settings"),
                    ),
                    properties: {
                        #[allow(unused_mut)]
                        let mut map = BTreeMap::new();
                        map.insert(
                            SmolStr::new_static("bottomLeft"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Element to show in bottom left corner"),
                                ),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("bottomRight"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Element to show in bottom right corner"),
                                ),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("topLeft"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Element to show in top left corner"),
                                ),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("topRight"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Element to show in top right corner"),
                                ),
                                ..Default::default()
                            }),
                        );
                        map
                    },
                    ..Default::default()
                }),
            );
            map.insert(
                SmolStr::new_static("filterNotificationTypes"),
                LexUserType::Object(LexObject {
                    properties: {
                        #[allow(unused_mut)]
                        let mut map = BTreeMap::new();
                        map.insert(
                            SmolStr::new_static("follows"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("likes"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("mentions"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("quotes"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("replies"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("reposts"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map
                    },
                    ..Default::default()
                }),
            );
            map.insert(
                SmolStr::new_static("filterRelationshipTypes"),
                LexUserType::Object(LexObject {
                    properties: {
                        #[allow(unused_mut)]
                        let mut map = BTreeMap::new();
                        map.insert(
                            SmolStr::new_static("followers"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("following"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("mutuals"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("nonMutuals"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map
                    },
                    ..Default::default()
                }),
            );
            map.insert(
                SmolStr::new_static("hideReposts"),
                LexUserType::Object(LexObject {
                    properties: {
                        #[allow(unused_mut)]
                        let mut map = BTreeMap::new();
                        map.insert(
                            SmolStr::new_static("feed"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("profile"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map
                    },
                    ..Default::default()
                }),
            );
            map.insert(
                SmolStr::new_static("highlightNotificationTypes"),
                LexUserType::Object(LexObject {
                    properties: {
                        #[allow(unused_mut)]
                        let mut map = BTreeMap::new();
                        map.insert(
                            SmolStr::new_static("follows"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("likes"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("mentions"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("quotes"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("replies"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("reposts"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map
                    },
                    ..Default::default()
                }),
            );
            map.insert(
                SmolStr::new_static("keyboardShortcuts"),
                LexUserType::Object(LexObject {
                    description: Some(
                        CowStr::new_static("Keyboard shortcut configuration"),
                    ),
                    properties: {
                        #[allow(unused_mut)]
                        let mut map = BTreeMap::new();
                        map.insert(
                            SmolStr::new_static("composer"),
                            LexObjectProperty::Ref(LexRef {
                                r#ref: CowStr::new_static("#keyboardShortcutsComposer"),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("global"),
                            LexObjectProperty::Ref(LexRef {
                                r#ref: CowStr::new_static("#keyboardShortcutsGlobal"),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("modals"),
                            LexObjectProperty::Ref(LexRef {
                                r#ref: CowStr::new_static("#keyboardShortcutsModals"),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("navigation"),
                            LexObjectProperty::Ref(LexRef {
                                r#ref: CowStr::new_static("#keyboardShortcutsNavigation"),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("postInteractions"),
                            LexObjectProperty::Ref(LexRef {
                                r#ref: CowStr::new_static(
                                    "#keyboardShortcutsPostInteractions",
                                ),
                                ..Default::default()
                            }),
                        );
                        map
                    },
                    ..Default::default()
                }),
            );
            map.insert(
                SmolStr::new_static("keyboardShortcutsComposer"),
                LexUserType::Object(LexObject {
                    description: Some(
                        CowStr::new_static("Post composer keyboard shortcuts"),
                    ),
                    properties: {
                        #[allow(unused_mut)]
                        let mut map = BTreeMap::new();
                        map.insert(
                            SmolStr::new_static("publish"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Publish post (e.g., ctrl+enter)"),
                                ),
                                max_length: Some(50usize),
                                ..Default::default()
                            }),
                        );
                        map
                    },
                    ..Default::default()
                }),
            );
            map.insert(
                SmolStr::new_static("keyboardShortcutsGlobal"),
                LexUserType::Object(LexObject {
                    description: Some(
                        CowStr::new_static("Global navigation keyboard shortcuts"),
                    ),
                    properties: {
                        #[allow(unused_mut)]
                        let mut map = BTreeMap::new();
                        map.insert(
                            SmolStr::new_static("collection"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Navigate to collection"),
                                ),
                                max_length: Some(50usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("feed"),
                            LexObjectProperty::String(LexString {
                                description: Some(CowStr::new_static("Navigate to feed")),
                                max_length: Some(50usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("inventory"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Navigate to inventory"),
                                ),
                                max_length: Some(50usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("profile"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Navigate to profile"),
                                ),
                                max_length: Some(50usize),
                                ..Default::default()
                            }),
                        );
                        map
                    },
                    ..Default::default()
                }),
            );
            map.insert(
                SmolStr::new_static("keyboardShortcutsModals"),
                LexUserType::Object(LexObject {
                    description: Some(CowStr::new_static("Modal keyboard shortcuts")),
                    properties: {
                        #[allow(unused_mut)]
                        let mut map = BTreeMap::new();
                        map.insert(
                            SmolStr::new_static("keyboardHelp"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Show keyboard shortcuts help"),
                                ),
                                max_length: Some(50usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("notifications"),
                            LexObjectProperty::String(LexString {
                                description: Some(CowStr::new_static("Open notifications")),
                                max_length: Some(50usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("postComposer"),
                            LexObjectProperty::String(LexString {
                                description: Some(CowStr::new_static("Open post composer")),
                                max_length: Some(50usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("stats"),
                            LexObjectProperty::String(LexString {
                                description: Some(CowStr::new_static("Open stats modal")),
                                max_length: Some(50usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("touchMenu"),
                            LexObjectProperty::String(LexString {
                                description: Some(CowStr::new_static("Open touch menu")),
                                max_length: Some(50usize),
                                ..Default::default()
                            }),
                        );
                        map
                    },
                    ..Default::default()
                }),
            );
            map.insert(
                SmolStr::new_static("keyboardShortcutsNavigation"),
                LexUserType::Object(LexObject {
                    description: Some(
                        CowStr::new_static("Navigation keyboard shortcuts"),
                    ),
                    properties: {
                        #[allow(unused_mut)]
                        let mut map = BTreeMap::new();
                        map.insert(
                            SmolStr::new_static("arrowDown"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Scroll down or next item"),
                                ),
                                max_length: Some(50usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("arrowLeft"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Go back to previous card"),
                                ),
                                max_length: Some(50usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("arrowRight"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Advance to next card"),
                                ),
                                max_length: Some(50usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("arrowUp"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Scroll up or previous item"),
                                ),
                                max_length: Some(50usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("escape"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Exit fullscreen or close modals"),
                                ),
                                max_length: Some(50usize),
                                ..Default::default()
                            }),
                        );
                        map
                    },
                    ..Default::default()
                }),
            );
            map.insert(
                SmolStr::new_static("keyboardShortcutsPostInteractions"),
                LexUserType::Object(LexObject {
                    description: Some(
                        CowStr::new_static("Post interaction keyboard shortcuts"),
                    ),
                    properties: {
                        #[allow(unused_mut)]
                        let mut map = BTreeMap::new();
                        map.insert(
                            SmolStr::new_static("like"),
                            LexObjectProperty::String(LexString {
                                description: Some(CowStr::new_static("Like current post")),
                                max_length: Some(50usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("quote"),
                            LexObjectProperty::String(LexString {
                                description: Some(CowStr::new_static("Quote current post")),
                                max_length: Some(50usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("reply"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Reply to current post"),
                                ),
                                max_length: Some(50usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("repost"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Repost current post"),
                                ),
                                max_length: Some(50usize),
                                ..Default::default()
                            }),
                        );
                        map
                    },
                    ..Default::default()
                }),
            );
            map.insert(
                SmolStr::new_static("main"),
                LexUserType::Record(LexRecord {
                    description: Some(
                        CowStr::new_static(
                            "User settings for the Anisota app, synchronized across devices via ATProto",
                        ),
                    ),
                    key: Some(CowStr::new_static("literal:settings")),
                    record: LexRecordRecord::Object(LexObject {
                        required: Some(
                            vec![
                                SmolStr::new_static("version"),
                                SmolStr::new_static("createdAt"),
                                SmolStr::new_static("updatedAt")
                            ],
                        ),
                        properties: {
                            #[allow(unused_mut)]
                            let mut map = BTreeMap::new();
                            map.insert(
                                SmolStr::new_static("behaviorSettings"),
                                LexObjectProperty::Ref(LexRef {
                                    r#ref: CowStr::new_static("#behaviorSettings"),
                                    ..Default::default()
                                }),
                            );
                            map.insert(
                                SmolStr::new_static("controlOrder"),
                                LexObjectProperty::Array(LexArray {
                                    description: Some(
                                        CowStr::new_static("Order of control buttons"),
                                    ),
                                    items: LexArrayItem::String(LexString {
                                        ..Default::default()
                                    }),
                                    ..Default::default()
                                }),
                            );
                            map.insert(
                                SmolStr::new_static("controlSettings"),
                                LexObjectProperty::Ref(LexRef {
                                    r#ref: CowStr::new_static("#controlSettings"),
                                    ..Default::default()
                                }),
                            );
                            map.insert(
                                SmolStr::new_static("createdAt"),
                                LexObjectProperty::String(LexString {
                                    description: Some(
                                        CowStr::new_static(
                                            "When the settings record was first created",
                                        ),
                                    ),
                                    format: Some(LexStringFormat::Datetime),
                                    ..Default::default()
                                }),
                            );
                            map.insert(
                                SmolStr::new_static("theme"),
                                LexObjectProperty::String(LexString {
                                    description: Some(
                                        CowStr::new_static("Selected color theme"),
                                    ),
                                    ..Default::default()
                                }),
                            );
                            map.insert(
                                SmolStr::new_static("uiSettings"),
                                LexObjectProperty::Ref(LexRef {
                                    r#ref: CowStr::new_static("#uiSettings"),
                                    ..Default::default()
                                }),
                            );
                            map.insert(
                                SmolStr::new_static("updatedAt"),
                                LexObjectProperty::String(LexString {
                                    description: Some(
                                        CowStr::new_static("When the settings were last updated"),
                                    ),
                                    format: Some(LexStringFormat::Datetime),
                                    ..Default::default()
                                }),
                            );
                            map.insert(
                                SmolStr::new_static("version"),
                                LexObjectProperty::Integer(LexInteger {
                                    minimum: Some(1i64),
                                    ..Default::default()
                                }),
                            );
                            map
                        },
                        ..Default::default()
                    }),
                    ..Default::default()
                }),
            );
            map.insert(
                SmolStr::new_static("moderationSettings"),
                LexUserType::Object(LexObject {
                    description: Some(
                        CowStr::new_static("Content moderation and filtering settings"),
                    ),
                    properties: {
                        #[allow(unused_mut)]
                        let mut map = BTreeMap::new();
                        map.insert(
                            SmolStr::new_static("mutedAccountsHandling"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static(
                                        "How to handle posts from muted accounts",
                                    ),
                                ),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("mutedContentHandling"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static(
                                        "How to handle posts containing muted words or phrases",
                                    ),
                                ),
                                ..Default::default()
                            }),
                        );
                        map
                    },
                    ..Default::default()
                }),
            );
            map.insert(
                SmolStr::new_static("statsVisibleSections"),
                LexUserType::Object(LexObject {
                    properties: {
                        #[allow(unused_mut)]
                        let mut map = BTreeMap::new();
                        map.insert(
                            SmolStr::new_static("activity"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("engagement"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("progress"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map
                    },
                    ..Default::default()
                }),
            );
            map.insert(
                SmolStr::new_static("uiSettings"),
                LexUserType::Object(LexObject {
                    description: Some(
                        CowStr::new_static("UI visibility and behavior settings"),
                    ),
                    properties: {
                        #[allow(unused_mut)]
                        let mut map = BTreeMap::new();
                        map.insert(
                            SmolStr::new_static("cornerElements"),
                            LexObjectProperty::Ref(LexRef {
                                r#ref: CowStr::new_static("#cornerElements"),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("fontSize"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static(
                                        "Font size scale (0.8 = 80%, 1.0 = 100% default, 1.2 = 120%)",
                                    ),
                                ),
                                max_length: Some(10usize),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("postCardPrimarySlot"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Primary name slot for post cards"),
                                ),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("postCardSecondarySlot"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Secondary name slot for post cards"),
                                ),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("profileCardPrimarySlot"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Primary name slot for profile cards"),
                                ),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("profileCardSecondarySlot"),
                            LexObjectProperty::String(LexString {
                                description: Some(
                                    CowStr::new_static("Secondary name slot for profile cards"),
                                ),
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showPostCardAtSymbol"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showPostCardAvatar"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showPostCardDisplayName"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showPostCardFooter"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showPostCardHandle"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showPostCardHeader"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showPostCount"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showPostReadIndicator"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfileAtSymbol"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfileBlocked"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfileBlocking"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfileCancelled"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfileCancelling"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfileCardAvatar"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfileCardFooter"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfileCardHeader"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfileCollections"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfileDisplayName"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfileFollowers"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfileFollowing"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfileHandle"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfileLexicons"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfileListed"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfileListing"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfileLists"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfilePosts"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfilePronouns"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfileVerified"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfileVerifying"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showProfileWebsite"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showRarityIndicator"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showTimestamp"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map.insert(
                            SmolStr::new_static("showUsername"),
                            LexObjectProperty::Boolean(LexBoolean {
                                ..Default::default()
                            }),
                        );
                        map
                    },
                    ..Default::default()
                }),
            );
            map
        },
        ..Default::default()
    }
}

pub mod settings_state {

    pub use crate::builder_types::{Set, Unset, IsSet, IsUnset};
    #[allow(unused)]
    use ::core::marker::PhantomData;
    mod sealed {
        pub trait Sealed {}
    }
    /// State trait tracking which required fields have been set
    pub trait State: sealed::Sealed {
        type CreatedAt;
        type UpdatedAt;
        type Version;
    }
    /// Empty state - all required fields are unset
    pub struct Empty(());
    impl sealed::Sealed for Empty {}
    impl State for Empty {
        type CreatedAt = Unset;
        type UpdatedAt = Unset;
        type Version = Unset;
    }
    ///State transition - sets the `created_at` field to Set
    pub struct SetCreatedAt<St: State = Empty>(PhantomData<fn() -> St>);
    impl<St: State> sealed::Sealed for SetCreatedAt<St> {}
    impl<St: State> State for SetCreatedAt<St> {
        type CreatedAt = Set<members::created_at>;
        type UpdatedAt = St::UpdatedAt;
        type Version = St::Version;
    }
    ///State transition - sets the `updated_at` field to Set
    pub struct SetUpdatedAt<St: State = Empty>(PhantomData<fn() -> St>);
    impl<St: State> sealed::Sealed for SetUpdatedAt<St> {}
    impl<St: State> State for SetUpdatedAt<St> {
        type CreatedAt = St::CreatedAt;
        type UpdatedAt = Set<members::updated_at>;
        type Version = St::Version;
    }
    ///State transition - sets the `version` field to Set
    pub struct SetVersion<St: State = Empty>(PhantomData<fn() -> St>);
    impl<St: State> sealed::Sealed for SetVersion<St> {}
    impl<St: State> State for SetVersion<St> {
        type CreatedAt = St::CreatedAt;
        type UpdatedAt = St::UpdatedAt;
        type Version = Set<members::version>;
    }
    /// Marker types for field names
    #[allow(non_camel_case_types)]
    pub mod members {
        ///Marker type for the `created_at` field
        pub struct created_at(());
        ///Marker type for the `updated_at` field
        pub struct updated_at(());
        ///Marker type for the `version` field
        pub struct version(());
    }
}

/// Builder for constructing an instance of this type.
pub struct SettingsBuilder<St: settings_state::State, S: BosStr = DefaultStr> {
    _state: PhantomData<fn() -> St>,
    _fields: (
        Option<settings::BehaviorSettings<S>>,
        Option<Vec<S>>,
        Option<settings::ControlSettings<S>>,
        Option<Datetime>,
        Option<S>,
        Option<settings::UiSettings<S>>,
        Option<Datetime>,
        Option<i64>,
    ),
    _type: PhantomData<fn() -> S>,
}

impl Settings<DefaultStr> {
    /// Create a new builder for this type, using the default string type (DefaultStr = SmolStr) if needed
    pub fn new() -> SettingsBuilder<settings_state::Empty, DefaultStr> {
        SettingsBuilder::new()
    }
}

impl<S: BosStr> Settings<S> {
    /// Create a new builder for this type
    pub fn builder() -> SettingsBuilder<settings_state::Empty, S> {
        SettingsBuilder::builder()
    }
}

impl SettingsBuilder<settings_state::Empty, DefaultStr> {
    /// Create a new builder with all fields unset, using the default string type, if needed
    pub fn new() -> Self {
        SettingsBuilder {
            _state: PhantomData,
            _fields: (None, None, None, None, None, None, None, None),
            _type: PhantomData,
        }
    }
}

impl<S: BosStr> SettingsBuilder<settings_state::Empty, S> {
    /// Create a new builder with all fields unset
    pub fn builder() -> Self {
        SettingsBuilder {
            _state: PhantomData,
            _fields: (None, None, None, None, None, None, None, None),
            _type: PhantomData,
        }
    }
}

impl<St: settings_state::State, S: BosStr> SettingsBuilder<St, S> {
    /// Set the `behaviorSettings` field (optional)
    pub fn behavior_settings(
        mut self,
        value: impl Into<Option<settings::BehaviorSettings<S>>>,
    ) -> Self {
        self._fields.0 = value.into();
        self
    }
    /// Set the `behaviorSettings` field to an Option value (optional)
    pub fn maybe_behavior_settings(
        mut self,
        value: Option<settings::BehaviorSettings<S>>,
    ) -> Self {
        self._fields.0 = value;
        self
    }
}

impl<St: settings_state::State, S: BosStr> SettingsBuilder<St, S> {
    /// Set the `controlOrder` field (optional)
    pub fn control_order(mut self, value: impl Into<Option<Vec<S>>>) -> Self {
        self._fields.1 = value.into();
        self
    }
    /// Set the `controlOrder` field to an Option value (optional)
    pub fn maybe_control_order(mut self, value: Option<Vec<S>>) -> Self {
        self._fields.1 = value;
        self
    }
}

impl<St: settings_state::State, S: BosStr> SettingsBuilder<St, S> {
    /// Set the `controlSettings` field (optional)
    pub fn control_settings(
        mut self,
        value: impl Into<Option<settings::ControlSettings<S>>>,
    ) -> Self {
        self._fields.2 = value.into();
        self
    }
    /// Set the `controlSettings` field to an Option value (optional)
    pub fn maybe_control_settings(
        mut self,
        value: Option<settings::ControlSettings<S>>,
    ) -> Self {
        self._fields.2 = value;
        self
    }
}

impl<St, S: BosStr> SettingsBuilder<St, S>
where
    St: settings_state::State,
    St::CreatedAt: settings_state::IsUnset,
{
    /// Set the `createdAt` field (required)
    pub fn created_at(
        mut self,
        value: impl Into<Datetime>,
    ) -> SettingsBuilder<settings_state::SetCreatedAt<St>, S> {
        self._fields.3 = Option::Some(value.into());
        SettingsBuilder {
            _state: PhantomData,
            _fields: self._fields,
            _type: PhantomData,
        }
    }
}

impl<St: settings_state::State, S: BosStr> SettingsBuilder<St, S> {
    /// Set the `theme` field (optional)
    pub fn theme(mut self, value: impl Into<Option<S>>) -> Self {
        self._fields.4 = value.into();
        self
    }
    /// Set the `theme` field to an Option value (optional)
    pub fn maybe_theme(mut self, value: Option<S>) -> Self {
        self._fields.4 = value;
        self
    }
}

impl<St: settings_state::State, S: BosStr> SettingsBuilder<St, S> {
    /// Set the `uiSettings` field (optional)
    pub fn ui_settings(
        mut self,
        value: impl Into<Option<settings::UiSettings<S>>>,
    ) -> Self {
        self._fields.5 = value.into();
        self
    }
    /// Set the `uiSettings` field to an Option value (optional)
    pub fn maybe_ui_settings(mut self, value: Option<settings::UiSettings<S>>) -> Self {
        self._fields.5 = value;
        self
    }
}

impl<St, S: BosStr> SettingsBuilder<St, S>
where
    St: settings_state::State,
    St::UpdatedAt: settings_state::IsUnset,
{
    /// Set the `updatedAt` field (required)
    pub fn updated_at(
        mut self,
        value: impl Into<Datetime>,
    ) -> SettingsBuilder<settings_state::SetUpdatedAt<St>, S> {
        self._fields.6 = Option::Some(value.into());
        SettingsBuilder {
            _state: PhantomData,
            _fields: self._fields,
            _type: PhantomData,
        }
    }
}

impl<St, S: BosStr> SettingsBuilder<St, S>
where
    St: settings_state::State,
    St::Version: settings_state::IsUnset,
{
    /// Set the `version` field (required)
    pub fn version(
        mut self,
        value: impl Into<i64>,
    ) -> SettingsBuilder<settings_state::SetVersion<St>, S> {
        self._fields.7 = Option::Some(value.into());
        SettingsBuilder {
            _state: PhantomData,
            _fields: self._fields,
            _type: PhantomData,
        }
    }
}

impl<St, S: BosStr> SettingsBuilder<St, S>
where
    St: settings_state::State,
    St::CreatedAt: settings_state::IsSet,
    St::UpdatedAt: settings_state::IsSet,
    St::Version: settings_state::IsSet,
{
    /// Build the final struct.
    pub fn build(self) -> Settings<S> {
        Settings {
            behavior_settings: self._fields.0,
            control_order: self._fields.1,
            control_settings: self._fields.2,
            created_at: self._fields.3.unwrap(),
            theme: self._fields.4,
            ui_settings: self._fields.5,
            updated_at: self._fields.6.unwrap(),
            version: self._fields.7.unwrap(),
            extra_data: Default::default(),
        }
    }
    /// Build the final struct with custom extra_data.
    pub fn build_with_data(self, extra_data: BTreeMap<SmolStr, Data<S>>) -> Settings<S> {
        Settings {
            behavior_settings: self._fields.0,
            control_order: self._fields.1,
            control_settings: self._fields.2,
            created_at: self._fields.3.unwrap(),
            theme: self._fields.4,
            ui_settings: self._fields.5,
            updated_at: self._fields.6.unwrap(),
            version: self._fields.7.unwrap(),
            extra_data: Some(extra_data),
        }
    }
}