Skip to content

Deleting events #91

Answered by bobmanc
bobmanc asked this question in Q&A
Mar 8, 2023 · 8 comments · 4 replies
Discussion options

You must be logged in to vote

I figured it out in case anyone is wondering.

calendar.eventCalendar.setOption('eventContent', (info) => { return {html: '<div class="cal-container"><div class="cal-header"><div>' + info.timeText + '</div><div>X</div></div><div class="cal-body">BODY</div></div>'}; }); calendar.eventCalendar.setOption('eventClick', (info) => { if ((info.jsEvent.layerX > info.el.offsetWidth - 20) && (info.jsEvent.layerY < 20)) { calendar.eventCalendar.removeEventById(info.event.id); setTimeout(() => { calendar.saveCalendarEvents(); }, 1000); } });

.cal-container {
height: 100%;
display: grid;
grid-template-rows:20px 1fr;
}

.cal-header {
display: flex;
justify-content: space-between;
align-items: center;
p…

Replies: 8 comments 4 replies

Comment options

You must be logged in to vote
0 replies
Answer selected by bobmanc
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@vkurko
Comment options

Comment options

You must be logged in to vote
1 reply
@vkurko
Comment options

Comment options

You must be logged in to vote
1 reply
@vkurko
Comment options

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@vkurko
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants