pub enum ControlSpec {
Enum {
key: String,
variants: Vec<EnumVariant>,
default: String,
},
Bool {
key: String,
default: bool,
},
Number {
key: String,
default: f64,
include: Option<bool>,
min: Option<f64>,
max: Option<f64>,
step: Option<f64>,
},
String {
key: String,
default: String,
placeholder: Option<String>,
},
Color {
key: String,
default: String,
},
ColorRange {
key_pos: String,
key_neg: String,
default_pos: String,
default_neg: String,
is_gradient: bool,
},
DatetimeFormat,
StringFormat,
NumberSeriesStyle {
default: NumberSeriesStyleDefaultConfig,
},
Symbols {
default: KeyValueOpts,
},
NumberFormat,
AggregateDepth,
}Expand description
Discriminated union of widget kinds the viewer can render. Composite
variants wrap an existing rich Yew component and carry only the
component’s *DefaultConfig. Primitive variants render generic scalar
widgets and carry their own key inline; the visible label is
resolved at CSS time via --psp-label--<key>--content.
Variants§
Enum
Bool
Number
Fields
String
Color
ColorRange
Paired pos/neg color picker rendered as a single horizontal
gradient/range bar. Used to expose the existing
crate::components::form::color_range_selector::ColorRangeSelector
widget at primitive granularity. Owns two top-level keys
(key_pos + key_neg); the visible label is derived from
key_pos.
Fields
DatetimeFormat
Residual format-only widget for datetime columns — owns
date_format only. Pair with primitive Enum and Color fields
for datetime_color_mode + color to fully decompose datetime
styling.
StringFormat
Residual format-only widget for string columns — owns format
only. Pair with primitive Enum and Color fields for
string_color_mode + color to fully decompose string styling.
NumberSeriesStyle
Fields
default: NumberSeriesStyleDefaultConfigSymbols
Fields
default: KeyValueOptsNumberFormat
AggregateDepth
Implementations§
Source§impl ControlSpec
impl ControlSpec
Sourcepub fn serialized_keys(&self) -> Vec<&str>
pub fn serialized_keys(&self) -> Vec<&str>
Top-level JSON keys this control owns when its value is serialized
into a column’s config map. For primitives this is just [key];
for composites it’s the set of fields the wrapped sub-struct
flattens. Used by ColumnConfigSchema::active_keys to filter the
columns_config blob passed to plugin.restore().
Trait Implementations§
Source§impl Clone for ControlSpec
impl Clone for ControlSpec
Source§fn clone(&self) -> ControlSpec
fn clone(&self) -> ControlSpec
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ControlSpec
impl Debug for ControlSpec
Source§impl<'de> Deserialize<'de> for ControlSpec
impl<'de> Deserialize<'de> for ControlSpec
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>,
Auto Trait Implementations§
impl Freeze for ControlSpec
impl RefUnwindSafe for ControlSpec
impl Send for ControlSpec
impl Sync for ControlSpec
impl Unpin for ControlSpec
impl UnsafeUnpin for ControlSpec
impl UnwindSafe for ControlSpec
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> FromQuery for Twhere
T: DeserializeOwned,
impl<T> FromQuery for Twhere
T: DeserializeOwned,
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 moreSource§impl<T> IntoPropValue<Option<T>> for T
impl<T> IntoPropValue<Option<T>> for T
Source§fn into_prop_value(self) -> Option<T>
fn into_prop_value(self) -> Option<T>
self to a value of a Properties struct.Source§impl<T> IntoPropValue<T> for T
impl<T> IntoPropValue<T> for T
Source§fn into_prop_value(self) -> T
fn into_prop_value(self) -> T
self to a value of a Properties struct.