You are here

public function ParserOperationForm::getDescription in Markdown 8.2

Returns additional text to display as a description.

Return value

\Drupal\Core\StringTranslation\TranslatableMarkup The form description.

Overrides ConfirmFormBase::getDescription

File

src/Form/ParserOperationForm.php, line 91

Class

ParserOperationForm
Provides a confirmation form to disable a parser.

Namespace

Drupal\markdown\Form

Code

public function getDescription() {
  switch ($this->operation) {
    case 'default':
      return $this
        ->t('Are you sure you want to set %parser as the default markdown parser?', [
        '@operation' => $this->operation,
        '%parser' => $this->parser
          ->getLabel(FALSE),
      ]);
  }
  return $this
    ->t('Are you sure you want to @operation the %parser markdown parser?', [
    '@operation' => $this->operation,
    '%parser' => $this->parser
      ->getLabel(FALSE),
  ]);
}