showonne / vue-date Goto Github PK
View Code? Open in Web Editor NEWA datepicker component for Vue.js
Home Page: https://showonne.github.io/vue-date/
License: MIT License
A datepicker component for Vue.js
Home Page: https://showonne.github.io/vue-date/
License: MIT License
I am using 1.1.6.
the code
<datepicker v-model="taskCreateTimeMin" :language="'ch'"></datepicker>
I want to clear the value of input ,but no cancle button.`
I need to be able to reset the date field once set. How can this be done?
Hello, thank you for your plugin, I would like to know if it is possible to disable those days on the calendar ?
现在我们需要一个选择时间换围的功能,请问有计划实现么?
How to set startDay to Monday?
Language 'es' is not well supported:
Days: {0: Domingo, 1: Lunes, 2: Martes, 3: Miércoles, 4: Jueves, 5: Viernes, 6: Sábado}
You can change 'é' 'á' chars for 'e' and 'a' respectively
Months: {1: Enero, 2: Febrero, 3: Marzo, 4: Abril, 5: Mayo, 6: Junio, 7: Julio, 8: Agosto, 9: Septiembre, 10: Octubre, 11: Noviembre, 12: Diciembre}
这个日期选择不兼容IE9吗
做的项目需要用到服务器端渲染(SSR),但是vue-date里的windon会报错,能否升级版本到支持SSR
If I should use this, i need npm install vue-date@versions
can I define datepicker as field type in vue-form-generator?
Headline said all
How to range with date now?
当切换日历年份的时候,每月对应的日期和星期匹配不正确,比如切换到2016年12月1日时,匹配的星期为星期五(Fr),但其实应该是星期四(Th),看了源码发现是在298和299行 ----
298. let startDay = new Date(this.year, this.tmpMonth, 1).getDay()
299. let previousMongthLength = new Date(this.year, this.tmpMonth, 0).getDate()
获取当前选择的年份使用的是this.year ,修改为 this.tmpYear 即可。
I am getting the following errors after I updated the module:
Uncaught TypeError: Cannot read property '0' of undefined
at VueComponent.eval (eval at (app.js:769), :1:10244)
at Array.func (eval at (app.js:1776), :454:26)
at MutationObserver.nextTickHandler (eval at (app.js:1776), :405:16)
(anonymous) @ index.js?6fa7:1
func @ vue.js?3de6:454
nextTickHandler @ vue.js?3de6:405
vue.js?3de6:2252 Uncaught TypeError: t._v is not a function
at Proxy.render (eval at (app.js:769), :1:22995)
at VueComponent.Vue._render (eval at (app.js:1776), :2240:22)
at VueComponent.eval (eval at (app.js:1776), :1695:21)
at Watcher.get (eval at (app.js:1776), :740:27)
at new Watcher (eval at (app.js:1776), :732:12)
at VueComponent.Vue._mount (eval at (app.js:1776), :1694:19)
at VueComponent.Vue$3.$mount (eval at (app.js:1776), :5592:15)
at VueComponent.Vue$3.$mount (eval at (app.js:1776), :7494:16)
at init (eval at (app.js:1776), :1978:11)
at createElm (eval at (app.js:1776), :3825:56)
This is the view:
<datepicker
range="event_date.range"
v-model="event_date.date"
@input="updateEventDate">
Please can you add support to language "pt-br" and format "dd/mm/yyyy"/"dd-mm-yyyy" ?
pt-br: {1: 'Jan', 2: 'Fev', 3: 'Mar', 4: 'Abr', 5: 'Mai', 6: ' 7: 'Jul', 8: 'Ago', 9: 'Set', 10: 'Out', 11: 'Nov', 12: 'Dez'}
Could you please add a TypeScript typings file to this library? Thanks
Language 'fr' is not well supported
months : {
"original": [ "Janvier", "Février", "Mars", "Avril", "Mai", "Juin", "Juillet", "Août", "Septembre", "Octobre", "Novembre", "Décembre" ],
"abbr": [ "Jan", "Fév", "Mar", "Avr", "Mai", "Juin", "Juil", "Août", "Sep", "Oct", "Nov", "Déc" ]
},
days : [ "Dim", "Lun", "Mar", "Mer", "Jeu", "Ven", "Sam" ]
应该是我调了width造成的显示问题,width好像是固定为320px,如果能够自适应一下就好了。
If I set programmatically the date (v-model object), that value appears in component label, then I open date-picker and 'today' is selected-highlighted, but should be selected the value I set.
i can't pass data to my controller even i'm using the attribute name !
I try to change the date range programmatically by an assignment of a new date range for the v-model
:
this.datePickerRange = [
// date1,
// date2
]
Only update the input but not the component range.
Just added these lines of code:
case 'de': return {1: 'Jan', 2: 'Feb', 3: 'Mar', 4: 'Apr', 5: 'May', 6: 'Jun', 7: 'Jul', 8: 'Aug', 9: 'Sep', 10: 'Okt', 11: 'Nov', 12: 'Dez'}[item];
prevMonthPreview() {
if (this.tmpMonth === 0) {
this.tmpMonth = 11;
this.tmpYear = this.tmpYear - 1;
} else {
this.tmpMonth = this.tmpMonth - 1;
}
},
nextMonthPreview() {
if (this.tmpMonth === 11) {
this.tmpMonth = 0;
this.tmpYear = this.tmpYear + 1;
} else {
this.tmpMonth = this.tmpMonth + 1;
}
}
Clear (set back to default view)
clear() {
this.panelType = 'date';
this.$emit('input', this.range ? ['', ''] : '');
}
not done yet: reset to selected:
If you already picked a date or range and you open the datepicker and change the year/month and close it without to adopt that date and reopen it date and month still have the last selected values, it should be set back to init state on panelType = 'date' and the list should be the one where your date is visible
Best + thx for your work!
PJ
on chrome console [Vue warn]: Avoid mutating a prop directly since the value will be overwritten whenever the parent component re-renders. Instead, use a data or computed property based on the prop's value. Prop being mutated: "value"
(found in component at ./src/components/datepicker.vue)
child component should emit event to change props value on che parent
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.