move CalendarEvent to CMSDataType
This commit is contained in:
parent
5af1f48150
commit
aaff6c92b8
1 changed files with 1 additions and 13 deletions
|
|
@ -1,8 +1,7 @@
|
|||
<script lang="ts">
|
||||
import FullCalendar from '$lib/components/FullCalendar.svelte';
|
||||
import daygridPlugin from '@fullcalendar/daygrid';
|
||||
// import type { EventClickArg } from '@fullcalendar/core';
|
||||
import type {CalendarEvent} from './CalendarEvent'
|
||||
import type {CalendarEvent} from '$lib/data/CMSDataType'
|
||||
let calendarRef;
|
||||
export let events:CalendarEvent[]
|
||||
let options = {
|
||||
|
|
@ -25,18 +24,7 @@
|
|||
today: 'วันนี้'
|
||||
},
|
||||
events,
|
||||
// eventClick: clickEvent,
|
||||
};
|
||||
/*
|
||||
function clickEvent(info:EventClickArg){
|
||||
alert(
|
||||
'Event: ' + info.event.title +
|
||||
'\nID: ' + info.event.id +
|
||||
'\nCoordinates: ' + info.jsEvent.pageX + ',' + info.jsEvent.pageY +
|
||||
'\nView: ' + info.view.type
|
||||
);
|
||||
}
|
||||
*/
|
||||
</script>
|
||||
<FullCalendar bind:this={calendarRef} {options} />
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue