diff --git a/core/lib/Drupal/Core/Config/ConfigManager.php b/core/lib/Drupal/Core/Config/ConfigManager.php
index 8b3b3d66fd..10b31f9dc8 100644
--- a/core/lib/Drupal/Core/Config/ConfigManager.php
+++ b/core/lib/Drupal/Core/Config/ConfigManager.php
@@ -296,8 +296,8 @@ public function getConfigEntitiesToChangeOnDependencyRemoval($type, array $names
     // initial values.
     $dependency_manager = $this->getConfigDependencyManager();
     $dependents = $this->findConfigEntityDependentsAsEntities($type, $names, $dependency_manager);
-    $original_dependencies = $dependents;
-    $delete_uuids = [];
+    $original_dependencies = $current_dependencies = $dependents;
+    $affected_uuids = [];
 
     $return = [
       'update' => [],
@@ -305,13 +305,6 @@ public function getConfigEntitiesToChangeOnDependencyRemoval($type, array $names
       'unchanged' => [],
     ];
 
-    // Create a map of UUIDs to $original_dependencies key so that we can remove
-    // fixed dependencies.
-    $uuid_map = [];
-    foreach ($original_dependencies as $key => $entity) {
-      $uuid_map[$entity->uuid()] = $key;
-    }
-
     // Try to fix any dependencies and find out what will happen to the
     // dependency graph. Entities are processed in the order of most dependent
     // first. For example, this ensures that Menu UI third party dependencies on
@@ -324,16 +317,17 @@ public function getConfigEntitiesToChangeOnDependencyRemoval($type, array $names
         $dependent = clone $dependent;
       }
       $fixed = FALSE;
-      if ($this->callOnDependencyRemoval($dependent, $original_dependencies, $type, $names)) {
+      if ($this->callOnDependencyRemoval($dependent, $current_dependencies, $type, $names)) {
         // Recalculate dependencies and update the dependency graph data.
         $dependent->calculateDependencies();
         $dependency_manager->updateData($dependent->getConfigDependencyName(), $dependent->getDependencies());
         // Based on the updated data rebuild the list of dependents. This will
         // remove entities that are no longer dependent after the recalculation.
-        $dependents = $this->findConfigEntityDependentsAsEntities($type, $names, $dependency_manager);
-        // Remove any entities that we've already marked for deletion.
-        $dependents = array_filter($dependents, function ($dependent) use ($delete_uuids) {
-          return !in_array($dependent->uuid(), $delete_uuids);
+        $current_dependencies = $this->findConfigEntityDependentsAsEntities($type, $names, $dependency_manager);
+        $dependents = $current_dependencies;
+        // Remove any entities that we've already processed.
+        $dependents = array_filter($dependents, function ($dependent) use ($affected_uuids) {
+          return !in_array($dependent->uuid(), $affected_uuids);
         });
         // Ensure that the dependency has actually been fixed. It is possible
         // that the dependent has multiple dependencies that cause it to be in
@@ -347,23 +341,22 @@ public function getConfigEntitiesToChangeOnDependencyRemoval($type, array $names
           }
         }
         if ($fixed) {
-          // Remove the fixed dependency from the list of original dependencies.
-          unset($original_dependencies[$uuid_map[$dependent->uuid()]]);
+          $affected_uuids[] = $dependent->uuid();
           $return['update'][] = $dependent;
         }
       }
       // If the entity cannot be fixed then it has to be deleted.
       if (!$fixed) {
-        $delete_uuids[] = $dependent->uuid();
+        $affected_uuids[] = $dependent->uuid();
         // Deletes should occur in the order of the least dependent first. For
         // example, this ensures that fields are removed before field storages.
         array_unshift($return['delete'], $dependent);
       }
     }
-    // Use the lists of UUIDs to filter the original list to work out which
-    // configuration entities are unchanged.
-    $return['unchanged'] = array_filter($original_dependencies, function ($dependent) use ($delete_uuids) {
-      return !(in_array($dependent->uuid(), $delete_uuids));
+    // Use the list of affected UUIDs to filter the original list to work out
+    // which configuration entities are unchanged.
+    $return['unchanged'] = array_filter($original_dependencies, function ($dependent) use ($affected_uuids) {
+      return !(in_array($dependent->uuid(), $affected_uuids));
     });
 
     return $return;
diff --git a/core/lib/Drupal/Core/Entity/EntityDisplayBase.php b/core/lib/Drupal/Core/Entity/EntityDisplayBase.php
index ca106b290f..4b11451a4c 100644
--- a/core/lib/Drupal/Core/Entity/EntityDisplayBase.php
+++ b/core/lib/Drupal/Core/Entity/EntityDisplayBase.php
@@ -462,6 +462,15 @@ public function onDependencyRemoval(array $dependencies) {
         $changed = TRUE;
       }
     }
+    foreach (\Drupal::service('entity_field.manager')->getBaseFieldDefinitions($this->getTargetEntityTypeId()) as $field_name => $field_definition) {
+      if (in_array($field_definition->getProvider(), $dependencies['module'], TRUE)) {
+        // Remove components for base fields whose modules are being
+        // uninstalled.
+        $this->removeComponent($field_name);
+        unset($this->hidden[$field_name]);
+        $changed = TRUE;
+      }
+    }
     foreach ($this->getComponents() as $name => $component) {
       if ($renderer = $this->getRenderer($name)) {
         if (in_array($renderer->getPluginDefinition()['provider'], $dependencies['module'])) {
