Package com.flowingcode.addons.ycalendar
Class ExtendedDatePicker
java.lang.Object
com.vaadin.flow.component.Component
com.vaadin.flow.component.AbstractField<C,T>
com.vaadin.flow.component.AbstractSinglePropertyField<DatePicker,LocalDate>
com.vaadin.flow.component.datepicker.DatePicker
com.flowingcode.addons.ycalendar.ExtendedDatePicker
- All Implemented Interfaces:
AttachNotifier,BlurNotifier<DatePicker>,DetachNotifier,Focusable<DatePicker>,FocusNotifier<DatePicker>,HasAriaLabel,HasElement,HasEnabled,HasHelper,HasLabel,HasPlaceholder,HasSize,HasStyle,HasTheme,HasValidation,HasValue<AbstractField.ComponentValueChangeEvent<DatePicker,,LocalDate>, LocalDate> HasValueAndElement<AbstractField.ComponentValueChangeEvent<DatePicker,,LocalDate>, LocalDate> HasAllowedCharPattern,HasAutoOpen,HasClearButton,HasClientValidation,HasOverlayClassName,HasPrefix,HasThemeVariant<DatePickerVariant>,HasTooltip,HasValidationProperties,InputField<AbstractField.ComponentValueChangeEvent<DatePicker,,LocalDate>, LocalDate> HasValidator<LocalDate>,Serializable
@Tag("fc-date-picker")
@JsModule("./fc-date-picker/fc-date-picker.js")
public class ExtendedDatePicker
extends DatePicker
A
DatePicker with UI controls for adjusting individual date parts and a date-based class
name generator.- Author:
- Javier Godoy / Flowing Code
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class com.vaadin.flow.component.datepicker.DatePicker
DatePicker.DatePickerI18n, DatePicker.InvalidChangeEvent, DatePicker.OpenedChangeEventNested classes/interfaces inherited from class com.vaadin.flow.component.AbstractField
AbstractField.ComponentValueChangeEvent<C extends Component,V extends Object> Nested classes/interfaces inherited from interface com.vaadin.flow.component.BlurNotifier
BlurNotifier.BlurEvent<C extends Component>Nested classes/interfaces inherited from interface com.vaadin.flow.component.FocusNotifier
FocusNotifier.FocusEvent<C extends Component>Nested classes/interfaces inherited from interface com.vaadin.flow.component.shared.HasClientValidation
HasClientValidation.ClientValidatedEventNested classes/interfaces inherited from interface com.vaadin.flow.component.HasValue
HasValue.ValueChangeEvent<V extends Object>, HasValue.ValueChangeListener<E extends HasValue.ValueChangeEvent<?>> -
Constructor Summary
ConstructorsConstructorDescriptionDefault constructor.ExtendedDatePicker(LocalDate initialDate) Convenience constructor to create a date picker with a pre-selected date in current UI locale format. -
Method Summary
Modifier and TypeMethodDescriptionvoidRefresh the styles of all dates in the displayed year and month.voidsetClassNameGenerator(ValueProvider<LocalDate, String> classNameGenerator) Sets the function that generates CSS class names for days in this calendar.Methods inherited from class com.vaadin.flow.component.datepicker.DatePicker
addInvalidChangeListener, addOpenedChangeListener, addValidationStatusChangeListener, close, getAriaLabel, getAriaLabelledBy, getDefaultValidator, getI18n, getInitialPosition, getLabel, getLocale, getMax, getMin, getName, isInputValuePresent, isOpened, isRequired, isRequiredIndicatorVisible, isWeekNumbersVisible, onAttach, open, setAriaLabel, setAriaLabelledBy, setErrorMessage, setI18n, setInitialPosition, setLabel, setLocale, setManualValidation, setMax, setMin, setName, setOpened, setRequired, setRequiredIndicatorVisible, setValue, setWeekNumbersVisible, validateMethods inherited from class com.vaadin.flow.component.AbstractSinglePropertyField
getSynchronizationRegistration, hasValidValue, setPresentationValue, setSynchronizedEventMethods inherited from class com.vaadin.flow.component.AbstractField
addValueChangeListener, getEmptyValue, getValue, isEmpty, setModelValue, valueEqualsMethods inherited from class com.vaadin.flow.component.Component
addListener, findAncestor, fireEvent, from, get, getChildren, getElement, getEventBus, getId, getListeners, getParent, getTranslation, getTranslation, getTranslation, getTranslation, getTranslation, getTranslation, getUI, hasListener, isAttached, isTemplateMapped, isVisible, onDetach, onEnabledStateChanged, removeFromParent, scrollIntoView, scrollIntoView, set, setElement, setId, setVisibleMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.vaadin.flow.component.AttachNotifier
addAttachListenerMethods inherited from interface com.vaadin.flow.component.BlurNotifier
addBlurListenerMethods inherited from interface com.vaadin.flow.component.DetachNotifier
addDetachListenerMethods inherited from interface com.vaadin.flow.component.Focusable
addFocusShortcut, blur, focus, getTabIndex, setTabIndexMethods inherited from interface com.vaadin.flow.component.FocusNotifier
addFocusListenerMethods inherited from interface com.vaadin.flow.component.shared.HasAllowedCharPattern
getAllowedCharPattern, setAllowedCharPatternMethods inherited from interface com.vaadin.flow.component.shared.HasAutoOpen
isAutoOpen, setAutoOpenMethods inherited from interface com.vaadin.flow.component.shared.HasClearButton
isClearButtonVisible, setClearButtonVisibleMethods inherited from interface com.vaadin.flow.component.shared.HasClientValidation
addClientValidatedEventListenerMethods inherited from interface com.vaadin.flow.component.HasElement
getElementMethods inherited from interface com.vaadin.flow.component.HasEnabled
isEnabled, setEnabledMethods inherited from interface com.vaadin.flow.component.HasHelper
getHelperComponent, getHelperText, setHelperComponent, setHelperTextMethods inherited from interface com.vaadin.flow.component.shared.HasOverlayClassName
getOverlayClassName, setOverlayClassNameMethods inherited from interface com.vaadin.flow.component.HasPlaceholder
getPlaceholder, setPlaceholderMethods inherited from interface com.vaadin.flow.component.shared.HasPrefix
getPrefixComponent, setPrefixComponentMethods inherited from interface com.vaadin.flow.component.HasSize
getHeight, getHeightUnit, getMaxHeight, getMaxWidth, getMinHeight, getMinWidth, getWidth, getWidthUnit, setHeight, setHeight, setHeightFull, setMaxHeight, setMaxHeight, setMaxWidth, setMaxWidth, setMinHeight, setMinHeight, setMinWidth, setMinWidth, setSizeFull, setSizeUndefined, setWidth, setWidth, setWidthFullMethods inherited from interface com.vaadin.flow.component.HasStyle
addClassName, addClassNames, getClassName, getClassNames, getStyle, hasClassName, removeClassName, removeClassNames, setClassName, setClassNameMethods inherited from interface com.vaadin.flow.component.HasTheme
addThemeName, addThemeNames, getThemeName, getThemeNames, hasThemeName, removeThemeName, removeThemeNames, setThemeName, setThemeNameMethods inherited from interface com.vaadin.flow.component.shared.HasThemeVariant
addThemeVariants, removeThemeVariantsMethods inherited from interface com.vaadin.flow.component.shared.HasTooltip
getTooltip, setTooltipTextMethods inherited from interface com.vaadin.flow.component.shared.HasValidationProperties
getErrorMessage, isInvalid, setInvalidMethods inherited from interface com.vaadin.flow.component.HasValue
addValueChangeListener, clear, getEmptyValue, getOptionalValue, getValue, isEmptyMethods inherited from interface com.vaadin.flow.component.HasValueAndElement
isReadOnly, setReadOnly
-
Constructor Details
-
ExtendedDatePicker
public ExtendedDatePicker()Default constructor. -
ExtendedDatePicker
Convenience constructor to create a date picker with a pre-selected date in current UI locale format.- Parameters:
initialDate- the pre-selected date in the picker
-
-
Method Details
-
setClassNameGenerator
Sets the function that generates CSS class names for days in this calendar. Returningnullfrom the generator results in no custom class name being set. Multiple class names can be returned from the generator as space-separated.- Parameters:
classNameGenerator- theValueProviderto use for generating class names
-
refreshAll
public void refreshAll()Refresh the styles of all dates in the displayed year and month.
-