[timeline] sticky header, scroll to hour....

This commit is contained in:
Filip Kaluža committed 2023-01-03 13:25:45 +01:00
1 parent 1fe2bd1c9b
commit affc96fc73
9 files changed
+68 -37

No files matched your search

@@ -1,6 +1,7 @@
<template lang="pug">
//- weekdays-headings are on week view only.
.vuecal__flex.vuecal__weekdays-headings
.vuecal__flex.vuecal__weekdays-headings(
ref="vuecal_weekday_heading")
template(v-for="(heading, i) in headings" :key="i")
.vuecal__flex.vuecal__heading(
v-if="!heading.hide"
@@ -31,7 +32,8 @@ export default {
transitionDirection: { type: String, default: 'right' },
weekDays: { type: Array, default: () => [] },
switchToNarrowerView: { type: Function, default: () => {} },
unscheduledTime: { type: Array, default: [] }
unscheduledTime: { type: Array, default: [] },
// viewPortOffset: { type: Number, default: 0 },
},
methods: {
@@ -48,7 +50,10 @@ export default {
name: heading.name,
initials: heading.initials,
...(heading.today ? { today: heading.today } : {})
})
}),
onTimelineScroll(viewPortOffset) {
this.$refs['vuecal_weekday_heading'].style.top = `${viewPortOffset}px`
}
},
computed: {