Readd function that had gone missing in refactoring.
This commit is contained in:
parent
e50f90f277
commit
1169d6cc15
@ -193,6 +193,17 @@ function finalizeDragAndCreate() {
|
|||||||
removeGlobalTouchListeners()
|
removeGlobalTouchListeners()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Build a minimal event creation payload from current selection
|
||||||
|
// Returns null if selection is invalid or empty.
|
||||||
|
function createEventFromSelection() {
|
||||||
|
const sel = selection.value || {}
|
||||||
|
if (!sel.startDate || !sel.dayCount || sel.dayCount <= 0) return null
|
||||||
|
return {
|
||||||
|
startDate: sel.startDate,
|
||||||
|
dayCount: sel.dayCount,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
function getDateUnderPoint(x, y) {
|
function getDateUnderPoint(x, y) {
|
||||||
const el = document.elementFromPoint(x, y)
|
const el = document.elementFromPoint(x, y)
|
||||||
let cur = el
|
let cur = el
|
||||||
|
Loading…
x
Reference in New Issue
Block a user