Updated all the contrib modules to their latest versions.
[yaffs-website] / web / modules / contrib / paragraphs / src / Controller / ParagraphsTypeListBuilder.php
diff --git a/web/modules/contrib/paragraphs/src/Controller/ParagraphsTypeListBuilder.php b/web/modules/contrib/paragraphs/src/Controller/ParagraphsTypeListBuilder.php
deleted file mode 100644 (file)
index 48fd9c0..0000000
+++ /dev/null
@@ -1,71 +0,0 @@
-<?php
-
-namespace Drupal\paragraphs\Controller;
-
-use Drupal\Core\Config\Entity\ConfigEntityListBuilder;
-use Drupal\Core\Entity\EntityInterface;
-
-/**
- * Provides a listing of ParagraphsType.
- */
-class ParagraphsTypeListBuilder extends ConfigEntityListBuilder {
-
-  /**
-   * {@inheritdoc}
-   */
-  public function buildHeader() {
-    $header['icon_file'] = [
-      'data' => $this->t('Icon'),
-    ];
-    $header['label'] = $this->t('Label');
-    $header['id'] = $this->t('Machine name');
-    $header['description'] = $this->t('Description');
-
-    return $header + parent::buildHeader();
-  }
-
-  /**
-   * {@inheritdoc}
-   */
-  public function buildRow(EntityInterface $entity) {
-    $row['icon_file'] = [];
-    if ($icon_url = $entity->getIconUrl()) {
-      $row['icon_file']['class'][] = 'paragraphs-type-icon';
-      $row['icon_file']['data'] = [
-        '#theme' => 'image',
-        '#uri' => $icon_url,
-        '#width' => 32,
-        '#height' => 32,
-      ];
-    }
-    $row['label'] = $entity->label();
-    $row['id'] = $entity->id();
-    $row['description']['data'] = ['#markup' => $entity->getDescription()];
-    // You probably want a few more properties here...
-    return $row + parent::buildRow($entity);
-  }
-
-  /**
-   * {@inheritdoc}
-   */
-  public function getDefaultOperations(EntityInterface $entity) {
-    /** @var \Drupal\field\FieldConfigInterface $entity */
-    $operations = parent::getDefaultOperations($entity);
-
-    if (isset($operations['edit'])) {
-      $operations['edit']['weight'] = 30;
-    }
-
-    return $operations;
-  }
-
-  /**
-   * {@inheritdoc}
-   */
-  public function render() {
-    $build = parent::render();
-    $build['#attached']['library'][] = 'paragraphs/drupal.paragraphs.list_builder';
-    return $build;
-  }
-
-}