code: private function findComponentModuleByType(array $module_list, string $find_component_type)
      {
          foreach($module_list as $m)
          {
              $component_type = call_user_func([$m, 'declareComponentType']);
  
              if ($component_type == $find_component_type){
                  return $m;
              }
          }
          return null;
      }
docs: Find component module by component type
  
  @param string[] $module_list
  @param string $find_component_type
  
  @return string