Protected
bindProtected
componentProtected
Optional
contentThe data bound to the Handlebars template.
Optional
dataThe data bound to the component.
Protected
defaultProtected
handlebarsThe Handlebars reference shared by all HawkSearch components.
Protected
configurationThe optional configuration object for this component.
The root element which should be used for querying any child elements. This resolves to this.shadowRoot
if the Shadow DOM is enabled, otherwise this
.
Static
observedProtected
bindProtected
getProtected
interpolateReplaces placeholders in a given string with values from a data object.
The template
string with all placeholders replaced by the values specified in values
.
The template string.
The object containing properties which will be bound to template
.
Protected
onProtected
registerOptional method that can be overwritten to register Handlebars helper functions which can be accessed from the template. For more information, see Custom Helpers.
Binds contentModel to the Handlebars template and renders the resulting HTML content.
Protected
renderDetermines whether the data meets the necessary conditions to perform data binding and render content.
Whether the component should be rendered. If false
, the component will have empty contents and be set to display: none;
.
The Date Picker component provides an intuitive interface that allows the user to select a range in ISO format. This component is currently only used within the Date Range Facet Component.
Tag
The tag for this component is
<hawksearch-date-picker>
.Attributes
string
Date
Date
Date
Event-Binding Attributes
The input element must have this attribute. When this element is clicked, the date picker modal will be displayed.
This root element of the date picker modal must have this attribute to calculate modal positioning.
This attribute is used to identify the form element used to select a specific month.
This attribute is used to identify the form element used to select a specific year.
When an element with this attribute is clicked, the month specified by
hawksearch-month
andhawksearch-year
to be displayed in the date picker modal.When an element with this attribute is clicked, the previous month will be displayed in the date picker modal.
When an element with this attribute is clicked, the next month will be displayed in the date picker modal.
When an element with this attribute is clicked, the month selector will be displayed in the date picker modal to quickly jump to a particular month rather than using pagination.
string
(ISO date format)When an element with this attribute is clicked, the specified date will be selected and displayed in the input element.
Events
Date
This event fires whenever the user selects a date.
Handlebars Helpers
Date
This helper function returns the zero-padded day of the month from a provided date object.
Default Template
The following is the default Handlebars template for this component. To create a custom template, it is recommended to use this as a starting point. {@embed ./date-picker.component.hbs}