trait SchemaPivotTrait in Schema.org Metatag 8
Schema.org Schema Metatag Manager trait.
Hierarchy
- trait \Drupal\schema_metatag\Plugin\metatag\Tag\SchemaPivotTrait
File
- src/
Plugin/ metatag/ Tag/ SchemaPivotTrait.php, line 8
Namespace
Drupal\schema_metatag\Plugin\metatag\TagView source
trait SchemaPivotTrait {
/**
* The form element.
*/
public function pivotForm($value) {
$form = [
'#type' => 'select',
'#title' => 'Pivot',
'#default_value' => !empty($value['pivot']) ? $value['pivot'] : '',
'#empty_option' => t('- None -'),
'#empty_value' => '',
'#options' => [
1 => $this
->t('Pivot'),
],
'#weight' => -9,
'#description' => $this
->t('Combine and pivot multiple values to display them as multiple objects.'),
];
return $form;
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
SchemaPivotTrait:: |
public | function | The form element. |