public function OptionsFormHelperTrait::getColumnHeaderFormatElement in FullCalendar 8.2
Same name and namespace in other branches
- 8.5 src/Plugin/fullcalendar/type/OptionsFormHelperTrait.php \Drupal\fullcalendar\Plugin\fullcalendar\type\OptionsFormHelperTrait::getColumnHeaderFormatElement()
- 8.4 src/Plugin/fullcalendar/type/OptionsFormHelperTrait.php \Drupal\fullcalendar\Plugin\fullcalendar\type\OptionsFormHelperTrait::getColumnHeaderFormatElement()
Get a column header format element.
Parameters
mixed $default: The default value.
string $fieldset: The name of the fieldset.
string $title: The field title.
Return value
array Drupal FAPI array.
1 call to OptionsFormHelperTrait::getColumnHeaderFormatElement()
- FullCalendar::buildOptionsForm in src/
Plugin/ fullcalendar/ type/ FullCalendar.php
File
- src/
Plugin/ fullcalendar/ type/ OptionsFormHelperTrait.php, line 288
Class
Namespace
Drupal\fullcalendar\Plugin\fullcalendar\typeCode
public function getColumnHeaderFormatElement($default, $fieldset, $title = '') {
return [
'#type' => 'textfield',
'#title' => !empty($title) ? $title : t('Column header format'),
'#description' => $this
->t('Determines the text that will be displayed the calendar’s column headings. Use comma-separated key:value pairs for @formatting properties e.g. weekday:short. @more-info', [
'@formatting' => Link::fromTextAndUrl($this
->t('date-formatting object'), Url::fromUri(self::FC_DOCS_URL . '/date-formatting', [
'attributes' => [
'target' => '_blank',
],
]))
->toString(),
'@more-info' => Link::fromTextAndUrl($this
->t('More info'), Url::fromUri(self::FC_DOCS_URL . '/columnHeaderFormat', [
'attributes' => [
'target' => '_blank',
],
]))
->toString(),
]),
'#default_value' => $default,
'#size' => '60',
'#fieldset' => $fieldset,
];
}