簡體   English   中英

FullCalendar Laravel 沒有全天活動的彩色文本

[英]FullCalendar Laravel Color Text for no fullday event

大家好,我想在沒有全天活動的情況下更改文本顏色,但仍然是白色

圓圈一。

這是我的代碼:

$eventsData = Event::all();
    $events = [];
$events[] = \Calendar::event(
            $row->name, //event title
            $row->allDay, //full day event?
            new Carbon($row->start_date), //start time (you can also use Carbon instead of DateTime)
            new Carbon($row->end_date), //end time (you can also use Carbon instead of DateTime)
            $row->id , //optionally, you can specify an event ID
            $options = [
           'backgroundColor'=> $color,
            'textColor' => '#000000',
                'eventColor'=>'#378006',
                'description' => 'hello',
                'eventClassNames' => 'fc-event-title fc-sticky text-success',
                'display'=> 'auto'

                ]
        );

全天活動已更改,但項目列表沒有

這是壓延選項

$calendar = new Calendar();
    $calendar->addEvents($events)
        ->setOptions([
            'locale' => 'fr',
            'timeZone' => 'Africa/Tunis',
            'firstDay' => 1,
            'businessHours'=> true,
            'displayEventTime' => true,
            'displayEventEnd' => true,
            'selectable' => true,
            'themeSystem' => 'bootstrap',
            'progressiveEventRendering' => true,

            'editable'=> true,
            'selectHelper'=>true,
            'initialView' => 'dayGridMonth',
            'dragScroll' => true,
            'dropAccept'=> '.cool-event',
            'eventResizableFromStart'=> true,
            'dayMaxEvents'=> true,

            'headerToolbar' => [
                'end' => 'today prev,next dayGridMonth timeGridWeek timeGridDay'
            ]
        ]);

在此處輸入圖像描述

您可以在 head 標簽內添加樣式。

<style>
    .fc-title{
        color:white!important;
    }
</style>

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM