dioxus_clerk/components/button_mode.rs
1/// Behavior used by sign-in and sign-up button components.
2///
3/// Unlike [`Routing`](crate::Routing) and [`UserProfileMode`](crate::UserProfileMode),
4/// which mirror clerk-js's fixed option sets, this is a crate-owned concept
5/// that may gain variants (e.g. a future non-modal, non-redirect flow). It is
6/// therefore `#[non_exhaustive]`: match it with a wildcard arm.
7#[derive(Debug, Clone, Copy, Default, PartialEq, Eq)]
8#[non_exhaustive]
9pub enum AuthButtonMode {
10 /// Open Clerk's modal flow on the current page.
11 Modal,
12 /// Redirect through Clerk's configured sign-in/sign-up URL.
13 #[default]
14 Redirect,
15}