pub struct FieldNode {Show 17 fields
pub id: String,
pub key: String,
pub label: String,
pub widget: WidgetKind,
pub help: String,
pub placeholder: String,
pub default_value: String,
pub required: bool,
pub width: Option<u8>,
pub options: Vec<Choice>,
pub rules: Vec<ConditionalRule>,
pub min: Option<f64>,
pub max: Option<f64>,
pub step: Option<String>,
pub min_length: Option<u32>,
pub max_length: Option<u32>,
pub pattern: String,
}Expand description
A scalar input. widget is the admin widget kind; validation extras
mirror the crate::widget::Widget surface so compilation is 1:1.
Fields§
§id: StringBuilder-minted node id (stable across edits; used by the i18n leaf model + the builder UI). Backfilled client-side.
key: String§label: String§widget: WidgetKind§help: String§placeholder: String§default_value: StringInitial value for new pages (JSON-encoded for multi-value kinds).
required: bool§width: Option<u8>1–12 column width when this field sits inside a row.
options: Vec<Choice>§rules: Vec<ConditionalRule>Conditional show/hide rules (form-builder storage shape).
min: Option<f64>§max: Option<f64>§step: Option<String>§min_length: Option<u32>§max_length: Option<u32>§pattern: StringTrait Implementations§
Source§impl<'de> Deserialize<'de> for FieldNode
impl<'de> Deserialize<'de> for FieldNode
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Forget for FieldNode
impl Freeze for FieldNode
impl RefUnwindSafe for FieldNode
impl Send for FieldNode
impl Sync for FieldNode
impl Unpin for FieldNode
impl UnsafeUnpin for FieldNode
impl UnwindSafe for FieldNode
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
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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> ⓘ
Converts
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> ⓘ
Converts
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 moreCreates a shared type from an unshared type.