A "Date Picker" control for selecting dates from a calendar-like interface.
view : Model -> Props -> Html Msg
The view for displaying the element.
init : Date -> ( Model, Platform.Cmd.Cmd Msg )
Creates the initial model for the element, using an "index date" to determine what
starting date the calendar opens up to. This does not have to be Date.today
update : Msg -> Model -> Props -> DatePickerResult
The main function for updating the element in response to Msg
defaultProps : String -> Props
Convenience function for getting a default Props
record. Requires that
the element's id be passed in.
Messages return from the view
{ showDatePicker : Basics.Bool
, today : Date
, monthMap : MonthMap
, outroMonthMap : Maybe MonthMap
}
The model the element uses to render itself.
{ id : String
, label : String
, selectedDateDisplay : Date -> String
, selectedDate : Maybe Date
, weekdayDisplay : Time.Weekday -> String
, monthDisplay : Time.Month -> String
, dateIsHighlighted : Date -> Basics.Bool
, canSelectDate : Date -> Basics.Bool
, canSelectMonth : ( Time.Month
, Basics.Int ) -> Basics.Bool
}
Configurable properties for rendering the view
ComponentResult Model Msg ExternalMsg Basics.Never
Alias for the element's Component Result type type.
The external message type for the Component Result type