Refactor and migrate Child Account Service to components

Remove all prohibited dependencies (c/b and content) from
Child Account Service and pass the needed objects from
the constructor.
Migrate Child Account Service to components, as it is
need for the iOS support of supervised users.

Bug: b/286377198
Change-Id: I7ad25c6535d07ba70c12046dba9ba49824cb49da
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4632731
Reviewed-by: Tomek Jurkiewicz <[email protected]>
Reviewed-by: Alex Ilin <[email protected]>
Commit-Queue: Anthi Orfanou <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1161720}
diff --git a/chrome/browser/prefs/browser_prefs.cc b/chrome/browser/prefs/browser_prefs.cc
index 92f2a01..6cd429f 100644
--- a/chrome/browser/prefs/browser_prefs.cc
+++ b/chrome/browser/prefs/browser_prefs.cc
@@ -223,7 +223,7 @@
 #endif
 
 #if BUILDFLAG(ENABLE_SUPERVISED_USERS)
-#include "chrome/browser/supervised_user/child_accounts/child_account_service.h"
+#include "components/supervised_user/core/browser/child_account_service.h"
 #include "components/supervised_user/core/browser/supervised_user_service.h"
 #endif
 
@@ -1676,7 +1676,7 @@
 #endif
 
 #if BUILDFLAG(ENABLE_SUPERVISED_USERS)
-  ChildAccountService::RegisterProfilePrefs(registry);
+  supervised_user::ChildAccountService::RegisterProfilePrefs(registry);
   supervised_user::SupervisedUserService::RegisterProfilePrefs(registry);
 #endif