'#button_type' => 'primary',
];
return $form;
} /**
* {@inheritdoc}
*/
public function getDefaultOperations(EntityInterface
$entity) { /** @var \Drupal\search\SearchPageInterface $entity */
$operations = parent::
getDefaultOperations($entity);
// Prevent the default search from being disabled or deleted.
if ($entity->
isDefaultSearch()) { unset($operations['disable'
],
$operations['delete'
]);
} else { $operations['default'
] =
[ 'title' =>
$this->
t('Set as default'
),
'url' => Url::
fromRoute('entity.search_page.set_default',
[ 'search_page' =>
$entity->
id(),
]),