Major new version #2

Merged
LeoVasanko merged 86 commits from vol002 into main 2025-08-26 05:58:24 +01:00
2 changed files with 14 additions and 1 deletions
Showing only changes of commit 467a984955 - Show all commits

View File

@ -299,6 +299,19 @@ function onDragPointerMove(e) {
ns,
ne,
)
} else if (st.isVirtual && (st.mode === 'resize-left' || st.mode === 'resize-right')) {
// For virtual occurrence resize: convert to real once, then adjust range
if (!st.realizedId) {
const newId = store.splitMoveVirtualOccurrence(st.id, st.startDate, st.startDate, st.endDate)
if (newId) {
st.realizedId = newId
st.id = newId
st.isVirtual = false
} else return
}
// Apply range change; rotate if left edge moved and weekday changed
const rotate = st.mode === 'resize-left'
store.setEventRange(st.id, ns, ne, { mode: st.mode, rotatePattern: rotate })
}
}

View File

@ -286,8 +286,8 @@ export const useCalendarStore = defineStore('calendar', {
DEFAULT_TZ,
)
if (
mode === 'move' &&
rotatePattern &&
(mode === 'move' || mode === 'resize-left') &&
snapshot.isRepeating &&
snapshot.repeat === 'weeks' &&
Array.isArray(snapshot.repeatWeekdays)