m3e/month_view
MonthView is an internal component used to display a single month in a calendar.
This file was generated by m3e/generator
DO NOT EDIT
Types
Config is a public record for configuring this component.
pub type Config {
Config(
range_start: option.Option(date.Date),
range_end: option.Option(date.Date),
today: date.Date,
date: option.Option(date.Date),
active_date: date.Date,
min_date: option.Option(date.Date),
max_date: option.Option(date.Date),
)
}
Constructors
-
Config( range_start: option.Option(date.Date), range_end: option.Option(date.Date), today: date.Date, date: option.Option(date.Date), active_date: date.Date, min_date: option.Option(date.Date), max_date: option.Option(date.Date), )
MonthView is a View Model for this component
Fields:
- range_start: Start of a date range.
- range_end: End of a date range.
- today: Today’s date.
- date: The selected date.
- active_date: The active date.
- min_date: The minimum date that can be selected.
- max_date: The maximum date that can be selected.
pub opaque type MonthView
Values
pub fn active_date(
record: MonthView,
active_date: date.Date,
) -> MonthView
active_date sets the value of active_date for this MonthView.
pub fn date(
record: MonthView,
date: option.Option(date.Date),
) -> MonthView
date sets the value of date for this MonthView.
pub const default_active_date: date.Date
pub fn default_config() -> Config
default_config is the default configuration for this component.
pub const default_date: option.Option(date.Date)
pub const default_max_date: option.Option(date.Date)
pub const default_min_date: option.Option(date.Date)
pub const default_range_end: option.Option(date.Date)
pub const default_range_start: option.Option(date.Date)
pub const default_today: date.Date
pub fn from_config(config: Config) -> MonthView
from_config creates a new MonthView from the given configuration.
pub fn max_date(
record: MonthView,
max_date: option.Option(date.Date),
) -> MonthView
max_date sets the value of max_date for this MonthView.
pub fn min_date(
record: MonthView,
min_date: option.Option(date.Date),
) -> MonthView
min_date sets the value of min_date for this MonthView.
pub fn range_end(
record: MonthView,
range_end: option.Option(date.Date),
) -> MonthView
range_end sets the value of range_end for this MonthView.
pub fn range_start(
record: MonthView,
range_start: option.Option(date.Date),
) -> MonthView
range_start sets the value of range_start for this MonthView.
pub fn render(
model: MonthView,
attributes: List(attribute.Attribute(msg)),
) -> element.Element(msg)
render creates a Lustre Element for a MonthView
pub fn render_config(
c: Config,
attributes: List(attribute.Attribute(msg)),
) -> element.Element(msg)
render_config creates a Lustre Element from a MonthView Config