#[non_exhaustive]pub struct RecoveryEmailParts<'a> {Show 16 fields
pub app_name: &'a str,
pub app_tagline: Option<&'a str>,
pub title: &'a str,
pub greeting_name: &'a str,
pub intro: &'a str,
pub cta_label: &'a str,
pub cta_url: &'a str,
pub fine_print: &'a str,
pub when: DateTime<Utc>,
pub request_ip: Option<&'a str>,
pub ua_summary: Option<&'a str>,
pub correlation_id: Option<&'a str>,
pub signature_primary: Option<&'a str>,
pub signature_title: Option<&'a str>,
pub support_email: Option<&'a str>,
pub show_powered_by: bool,
}Expand description
Structured inputs to render_recovery_html. Kept separate
from Mail so the framework’s HTML email surface stays
declarative — call-sites pass labelled fields rather than a
long positional argument list.
#[non_exhaustive] so future additions (e.g. a project-
supplied accent override, a footer-link tuple) are SemVer-safe.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.app_name: &'a strUser-facing product identity, e.g. "Library Circulation".
Required for production: never set this to a framework
name. Renders as the brand wordmark, in the security
envelope’s “System” row, and in the email footer.
app_tagline: Option<&'a str>Optional descriptor under the wordmark — e.g.
"Operational library management". None falls back to
"Account security notification".
title: &'a str§greeting_name: &'a strGreeting label resolved by the caller via the documented
display_name → first_name → email-local-part → "there"
fallback. Rendered as "Hello {greeting_name},".
intro: &'a str§cta_label: &'a str§cta_url: &'a str§fine_print: &'a str§when: DateTime<Utc>§request_ip: Option<&'a str>§ua_summary: Option<&'a str>§correlation_id: Option<&'a str>Per-request correlation id (UUID v7). The framework derives
a 6-character reference from its last hex chars and
renders it inside a security-style panel — operators can
match the reference to the audit row, and the visual block
stays compatible with a future MFA verification-code shape.
None hides the reference panel.
signature_primary: Option<&'a str>Account-owner signature primary line (“Abdulwahed Mansour”
or a name-equivalent). None hides the signature block.
signature_title: Option<&'a str>Optional secondary signature line (job title).
support_email: Option<&'a str>Optional support contact surfaced in the email footer.
show_powered_by: booltrue → render the low-key “Powered by RustIO” footer
credit. Off by default; the framework name stays invisible.
Implementations§
Source§impl<'a> RecoveryEmailParts<'a>
impl<'a> RecoveryEmailParts<'a>
Sourcepub fn new(
app_name: &'a str,
title: &'a str,
greeting_name: &'a str,
intro: &'a str,
cta_url: &'a str,
fine_print: &'a str,
when: DateTime<Utc>,
) -> Self
pub fn new( app_name: &'a str, title: &'a str, greeting_name: &'a str, intro: &'a str, cta_url: &'a str, fine_print: &'a str, when: DateTime<Utc>, ) -> Self
Construct a RecoveryEmailParts with sensible defaults
for the optional fields. Required fields are positional;
everything else lands in a safe “none”/default state and
callers mutate the public field directly.
Lets external crates (the CLI’s doctor email
--html-preview, project-side test scaffolding) construct
the struct around its #[non_exhaustive] attribute.
Auto Trait Implementations§
impl<'a> Freeze for RecoveryEmailParts<'a>
impl<'a> RefUnwindSafe for RecoveryEmailParts<'a>
impl<'a> Send for RecoveryEmailParts<'a>
impl<'a> Sync for RecoveryEmailParts<'a>
impl<'a> Unpin for RecoveryEmailParts<'a>
impl<'a> UnsafeUnpin for RecoveryEmailParts<'a>
impl<'a> UnwindSafe for RecoveryEmailParts<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more