diagonal line support
This commit is contained in:
@@ -30,7 +30,18 @@ const year = computed({
|
||||
set(v) { update(v, month.value, day.value, time.value)},
|
||||
})
|
||||
const time = computed({
|
||||
get() { return '' + (s.utc ? `${props.modelValue.getUTCHours()}:${props.modelValue.getUTCMinutes()}` : `${props.modelValue.getHours()}:${props.modelValue.getMinutes()}` ) },
|
||||
get() {
|
||||
let hour, min
|
||||
if( s.utc ) {
|
||||
hour = props.modelValue.getUTCHours()
|
||||
min = props.modelValue.getUTCMinutes()
|
||||
}
|
||||
else {
|
||||
hour = props.modelValue.getHours()
|
||||
min = props.modelValue.getMinutes()
|
||||
}
|
||||
return hour.toString().padStart(2,'0') + ':' + min.toString().padStart(2,'0')
|
||||
},
|
||||
set(v) { update(year.value, month.value, day.value, v) }
|
||||
})
|
||||
|
||||
@@ -45,7 +56,6 @@ const monthItems = monthsForLocale(undefined, 'short').map((v)=>{return {title:v
|
||||
|
||||
function buildDate(y, m, d, t) {
|
||||
const [hours,minutes] = t.split(':')
|
||||
console.log('buildDate', y, m, d, hours, minutes)
|
||||
return s.utc ? new Date(Date.UTC(y, m, d, hours, minutes))
|
||||
: new Date(y, m, d, hours, minutes);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user