To create full featured multi language datepicker element use this component.
Code:
<fvDatepicker v-model="input" />
export default {
data () {
return {
input: undefined
}
}
}
Examples:
Notes:
- The display css prop of input is inline-flex, so do not change it to block or ... for custom styles.
- You can globally set the dateLibrary prop by setting by Framevuerk.use('date', Date).
- Input value can be any types that allow by Date Library as first argument. All output value is Date Library constructor.
- For jalaali dates, we highly propose idate npm package.
API:
Name | Type | Default | Description |
---|
value* | | --- | |
required | | false | Does input required to fill? Also with function type you can pass function with one argument (fn(value){}) and return Boolean value. |
disabled | | false | |
placeholder | | '' | Placeholder text. (when no option selected) |
multiple | | false | Allow user to select multiple options. |
deleteButton | | true | Show delete button next to selected values. |
dateLibrary | | --- | Custom Date library instead of default javascript Date class. |
defaultValue | | Date.now() | Default highlighted date. |
Name | Params | Description |
---|
input | | Fired when component request to change value. |
Name | Params | Description |
---|
value | | Template for value inside input. |
Name | Description |
---|
.fv-size-xs | |
.fv-size-sm | |
.fv-size-md | Medium size (actived by default) |
.fv-size-lg | |
.fv-size-xl | |