@props([
// Entries, built with App\Support\CrmCalendar::event().
'events' => [],
// month | week | day | agenda. A phone always opens on the agenda.
'view' => 'month',
// May entries be dragged and resized? Each entry can still refuse (editable: false).
'editable' => false,
// May empty days be clicked or dragged across to start a new entry?
'selectable' => false,
// The date to open on (Y-m-d). Today when omitted.
'date' => null,
// A fixed pixel height, or null to grow with the content.
'height' => null,
// Names this calendar, so 'crm-calendar-events' can address one of several.
'name' => 'main',
// Which entry types the key lists (keys of CrmCalendar::types()). All when omitted.
'legend' => null,
// Livewire methods to call, each given the event detail as its one argument.
'onClick' => null,
'onDrop' => null,
'onSelect' => null,
'onRange' => null,
])
{{--
The CRM calendar. The one wrapper around FullCalendar (conflict register
C6): events in through `events`, clicks and drops out through the `on*`
props and as crm-calendar-* browser events. The contract is written out in
resources/js/crm-calendar.js.
Example, on a Livewire page: