exportconstwithMinimumDate=()=>{loadDefaultFeedbackMessages();return html`
<lion-input-date
label="MinDate"
help-text="Enter a date greater than or equal to today."
.modelValue="${newDate('2018/05/30')}"
.validators="${[newMinDate(newDate())]}"
>
</lion-input-date>
`;};
With maximum date
exportconstwithMaximumDate=()=>{loadDefaultFeedbackMessages();return html`
<lion-input-date
label="MaxDate"
help-text="Enter a date smaller than or equal to today."
.modelValue="${newDate('2100/05/30')}"
.validators="${[newMaxDate(newDate())]}"
></lion-input-date>
`;};
With minimum and maximum date
exportconstwithMinimumAndMaximumDate=()=>{loadDefaultFeedbackMessages();return html`
<lion-input-date
label="MinMaxDate"
.modelValue="${newDate('2018/05/30')}"
.validators="${[newMinMaxDate({min:newDate('2018/05/24'),max:newDate('2018/06/24')}),]}"
>
<div slot="help-text">
Enter a date between ${formatDate(newDate('2018/05/24'))} and
${formatDate(newDate('2018/06/24'))}.
</div>
</lion-input-date>
`;};
Faulty prefilled
exportconstfaultyPrefilled=()=> html`
<lion-input-date
label="Date"
help-text="Faulty prefilled input will be cleared"
.modelValue="${'foo'}"
></lion-input-date>
`;