refactor: place all presentation code in a presentation folder

Some features didn't have this folder.

Bug: twpowertools:226
Change-Id: Ic9803e7ee66a15c6c9e083509e059e453a26ed0f
diff --git a/src/entryPoints/communityConsole/contentScripts/main.ts b/src/entryPoints/communityConsole/contentScripts/main.ts
index 9c70743..1cc7e21 100644
--- a/src/entryPoints/communityConsole/contentScripts/main.ts
+++ b/src/entryPoints/communityConsole/contentScripts/main.ts
@@ -16,9 +16,9 @@
 import AutoRefreshThreadListSetUpHandler from '../../../features/autoRefresh/presentation/nodeWatcherHandlers/threadListSetUp.handler';
 import AutoRefreshStylesScript from '../../../features/autoRefresh/presentation/scripts/styles.script';
 import ReportDialogColorThemeFix from '../../../features/ccDarkTheme/core/logic/reportDialog';
-import CCDarkThemeEcAppHandler from '../../../features/ccDarkTheme/nodeWatcherHandlers/ecApp.handler';
-import CCDarkThemeReportDialogHandler from '../../../features/ccDarkTheme/nodeWatcherHandlers/reportDialog.handler';
-import CCDarkThemeUnifiedProfilesIframeHandler from '../../../features/ccDarkTheme/nodeWatcherHandlers/unifiedProfilesIframe.handler';
+import CCDarkThemeEcAppHandler from '../../../features/ccDarkTheme/presentation/nodeWatcherHandlers/ecApp.handler';
+import CCDarkThemeReportDialogHandler from '../../../features/ccDarkTheme/presentation/nodeWatcherHandlers/reportDialog.handler';
+import CCDarkThemeUnifiedProfilesIframeHandler from '../../../features/ccDarkTheme/presentation/nodeWatcherHandlers/unifiedProfilesIframe.handler';
 import Features from '../../../features/Features';
 import CCInfiniteScroll from '../../../features/infiniteScroll/core/ccInfiniteScroll';
 import { NodeWatcherAdapter } from '../../../infrastructure/presentation/nodeWatcher/NodeWatcher.adapter';
@@ -28,9 +28,9 @@
 import { SortedScriptsProviderAdapter } from '../../../infrastructure/presentation/scripts/SortedScriptsProvider.adapter';
 import { NodeWatcherHandler } from '../../../presentation/nodeWatcher/NodeWatcherHandler';
 import StandaloneScripts from '../../../scripts/Scripts';
-import CCInfiniteScrollSetUpHandler from '../../../features/infiniteScroll/nodeWatcherHandlers/ccInfiniteScrollSetUp.handler';
-import CCInfiniteScrollLoadMoreBarHandler from '../../../features/infiniteScroll/nodeWatcherHandlers/ccInfiniteScrollLoadMoreBar.handler';
-import CCInfiniteScrollLoadMoreBtnHandler from '../../../features/infiniteScroll/nodeWatcherHandlers/ccInfiniteScrollLoadMoreBtn.handler';
+import CCInfiniteScrollSetUpHandler from '../../../features/infiniteScroll/presentation/nodeWatcherHandlers/ccInfiniteScrollSetUp.handler';
+import CCInfiniteScrollLoadMoreBarHandler from '../../../features/infiniteScroll/presentation/nodeWatcherHandlers/ccInfiniteScrollLoadMoreBar.handler';
+import CCInfiniteScrollLoadMoreBtnHandler from '../../../features/infiniteScroll/presentation/nodeWatcherHandlers/ccInfiniteScrollLoadMoreBtn.handler';
 import WorkflowsThreadListActionBarHandler from '../../../features/workflows/presentation/nodeWatcherHandlers/threadListActionBar.handler';
 import WorkflowsImportCRTagsHandler from '../../../features/workflows/presentation/nodeWatcherHandlers/crTags.handler';
 import Workflows from '../../../features/workflows/core/communityConsole/workflows';
diff --git a/src/entryPoints/communityConsole/contentScripts/start.ts b/src/entryPoints/communityConsole/contentScripts/start.ts
index 73d2230..9ffdd95 100644
--- a/src/entryPoints/communityConsole/contentScripts/start.ts
+++ b/src/entryPoints/communityConsole/contentScripts/start.ts
@@ -14,8 +14,8 @@
   ScriptRunPhase,
 } from '../../../common/architecture/scripts/Script';
 import AutoRefreshSetUpScript from '../../../features/autoRefresh/presentation/scripts/setUp.script';
-import CCDarkThemeInjectAutoDarkTheme from '../../../features/ccDarkTheme/scripts/injectAutoDarkTheme.script';
-import CCDarkThemeInjectForcedDarkTheme from '../../../features/ccDarkTheme/scripts/injectForcedDarkTheme.script';
+import CCDarkThemeInjectAutoDarkTheme from '../../../features/ccDarkTheme/presentation/scripts/injectAutoDarkTheme.script';
+import CCDarkThemeInjectForcedDarkTheme from '../../../features/ccDarkTheme/presentation/scripts/injectForcedDarkTheme.script';
 import Features from '../../../features/Features';
 import InteropThreadPageSetupScript from '../../../features/interopThreadPage/presentation/scripts/setup.script';
 import ScriptRunner from '../../../infrastructure/presentation/scripts/ScriptRunner';
diff --git a/src/features/ccDarkTheme/nodeWatcherHandlers/reportDialog.handler.ts b/src/features/ccDarkTheme/nodeWatcherHandlers/reportDialog.handler.ts
deleted file mode 100644
index 56699e9..0000000
--- a/src/features/ccDarkTheme/nodeWatcherHandlers/reportDialog.handler.ts
+++ /dev/null
@@ -1,25 +0,0 @@
-import CssSelectorNodeWatcherHandler from '../../../infrastructure/presentation/nodeWatcher/handlers/CssSelectorHandler.adapter';
-import { NodeMutation } from '../../../presentation/nodeWatcher/NodeWatcherHandler';
-import { OptionsProviderPort } from '../../../services/options/OptionsProvider';
-import ReportDialogColorThemeFix from '../core/logic/reportDialog';
-
-/**
- * Sets the report dialog iframe's theme to the appropriate theme.
- */
-export default class CCDarkThemeReportDialogHandler extends CssSelectorNodeWatcherHandler {
-  cssSelector = 'iframe';
-
-  constructor(
-    private optionsProvider: OptionsProviderPort,
-    private reportDialogColorThemeFix: ReportDialogColorThemeFix,
-  ) {
-    super();
-  }
-
-  onMutatedNode(mutation: NodeMutation) {
-    this.reportDialogColorThemeFix.fixThemeIfReportDialogIframeAndApplicable(
-      mutation.node,
-      this.optionsProvider,
-    );
-  }
-}
diff --git a/src/features/ccDarkTheme/nodeWatcherHandlers/unifiedProfilesIframe.handler.ts b/src/features/ccDarkTheme/nodeWatcherHandlers/unifiedProfilesIframe.handler.ts
deleted file mode 100644
index 28b9753..0000000
--- a/src/features/ccDarkTheme/nodeWatcherHandlers/unifiedProfilesIframe.handler.ts
+++ /dev/null
@@ -1,27 +0,0 @@
-import CssSelectorNodeWatcherHandler from '../../../infrastructure/presentation/nodeWatcher/handlers/CssSelectorHandler.adapter';
-import { NodeMutation } from '../../../presentation/nodeWatcher/NodeWatcherHandler';
-import { OptionsProviderPort } from '../../../services/options/OptionsProvider';
-import { isDarkThemeOn } from '../core/logic/darkTheme';
-import { unifiedProfilesFix } from '../core/logic/unifiedProfiles';
-
-/**
- * Redirect unified profile iframe to dark version if applicable
- */
-export default class CCDarkThemeUnifiedProfilesIframeHandler extends CssSelectorNodeWatcherHandler {
-  cssSelector = 'iframe';
-
-  constructor(private optionsProvider: OptionsProviderPort) {
-    super();
-  }
-
-  async onMutatedNode(mutation: NodeMutation) {
-    const optionsValues = await this.optionsProvider.getOptionsValues();
-
-    if (
-      isDarkThemeOn(optionsValues) &&
-      unifiedProfilesFix.checkIframe(mutation.node)
-    ) {
-      unifiedProfilesFix.fixIframe(mutation.node);
-    }
-  }
-}
diff --git a/src/features/ccDarkTheme/nodeWatcherHandlers/ecApp.handler.ts b/src/features/ccDarkTheme/presentation/nodeWatcherHandlers/ecApp.handler.ts
similarity index 67%
rename from src/features/ccDarkTheme/nodeWatcherHandlers/ecApp.handler.ts
rename to src/features/ccDarkTheme/presentation/nodeWatcherHandlers/ecApp.handler.ts
index 355de3f..3676bcd 100644
--- a/src/features/ccDarkTheme/nodeWatcherHandlers/ecApp.handler.ts
+++ b/src/features/ccDarkTheme/presentation/nodeWatcherHandlers/ecApp.handler.ts
@@ -1,7 +1,7 @@
-import CssSelectorNodeWatcherHandler from '../../../infrastructure/presentation/nodeWatcher/handlers/CssSelectorHandler.adapter';
-import { NodeMutation } from '../../../presentation/nodeWatcher/NodeWatcherHandler';
-import { OptionsProviderPort } from '../../../services/options/OptionsProvider';
-import { injectDarkThemeButton } from '../core/logic/darkTheme';
+import CssSelectorNodeWatcherHandler from '../../../../infrastructure/presentation/nodeWatcher/handlers/CssSelectorHandler.adapter';
+import { NodeMutation } from '../../../../presentation/nodeWatcher/NodeWatcherHandler';
+import { OptionsProviderPort } from '../../../../services/options/OptionsProvider';
+import { injectDarkThemeButton } from '../../core/logic/darkTheme';
 
 /**
  * Injects the dark theme button.
diff --git a/src/features/ccDarkTheme/presentation/nodeWatcherHandlers/reportDialog.handler.ts b/src/features/ccDarkTheme/presentation/nodeWatcherHandlers/reportDialog.handler.ts
new file mode 100644
index 0000000..89ccdf2
--- /dev/null
+++ b/src/features/ccDarkTheme/presentation/nodeWatcherHandlers/reportDialog.handler.ts
@@ -0,0 +1,25 @@
+import CssSelectorNodeWatcherHandler from '../../../../infrastructure/presentation/nodeWatcher/handlers/CssSelectorHandler.adapter';
+import { NodeMutation } from '../../../../presentation/nodeWatcher/NodeWatcherHandler';
+import { OptionsProviderPort } from '../../../../services/options/OptionsProvider';
+import ReportDialogColorThemeFix from '../../core/logic/reportDialog';
+
+/**
+ * Sets the report dialog iframe's theme to the appropriate theme.
+ */
+export default class CCDarkThemeReportDialogHandler extends CssSelectorNodeWatcherHandler {
+  cssSelector = 'iframe';
+
+  constructor(
+    private optionsProvider: OptionsProviderPort,
+    private reportDialogColorThemeFix: ReportDialogColorThemeFix,
+  ) {
+    super();
+  }
+
+  onMutatedNode(mutation: NodeMutation) {
+    this.reportDialogColorThemeFix.fixThemeIfReportDialogIframeAndApplicable(
+      mutation.node,
+      this.optionsProvider,
+    );
+  }
+}
diff --git a/src/features/ccDarkTheme/presentation/nodeWatcherHandlers/unifiedProfilesIframe.handler.ts b/src/features/ccDarkTheme/presentation/nodeWatcherHandlers/unifiedProfilesIframe.handler.ts
new file mode 100644
index 0000000..13b6cc9
--- /dev/null
+++ b/src/features/ccDarkTheme/presentation/nodeWatcherHandlers/unifiedProfilesIframe.handler.ts
@@ -0,0 +1,27 @@
+import CssSelectorNodeWatcherHandler from '../../../../infrastructure/presentation/nodeWatcher/handlers/CssSelectorHandler.adapter';
+import { NodeMutation } from '../../../../presentation/nodeWatcher/NodeWatcherHandler';
+import { OptionsProviderPort } from '../../../../services/options/OptionsProvider';
+import { isDarkThemeOn } from '../../core/logic/darkTheme';
+import { unifiedProfilesFix } from '../../core/logic/unifiedProfiles';
+
+/**
+ * Redirect unified profile iframe to dark version if applicable
+ */
+export default class CCDarkThemeUnifiedProfilesIframeHandler extends CssSelectorNodeWatcherHandler {
+  cssSelector = 'iframe';
+
+  constructor(private optionsProvider: OptionsProviderPort) {
+    super();
+  }
+
+  async onMutatedNode(mutation: NodeMutation) {
+    const optionsValues = await this.optionsProvider.getOptionsValues();
+
+    if (
+      isDarkThemeOn(optionsValues) &&
+      unifiedProfilesFix.checkIframe(mutation.node)
+    ) {
+      unifiedProfilesFix.fixIframe(mutation.node);
+    }
+  }
+}
diff --git a/src/features/ccDarkTheme/scripts/injectAutoDarkTheme.script.ts b/src/features/ccDarkTheme/presentation/scripts/injectAutoDarkTheme.script.ts
similarity index 74%
rename from src/features/ccDarkTheme/scripts/injectAutoDarkTheme.script.ts
rename to src/features/ccDarkTheme/presentation/scripts/injectAutoDarkTheme.script.ts
index c1bf0a1..afbe161 100644
--- a/src/features/ccDarkTheme/scripts/injectAutoDarkTheme.script.ts
+++ b/src/features/ccDarkTheme/presentation/scripts/injectAutoDarkTheme.script.ts
@@ -1,5 +1,5 @@
-import { ScriptPage } from '../../../common/architecture/scripts/Script';
-import StylesheetScript from '../../../common/architecture/scripts/stylesheet/StylesheetScript';
+import { ScriptPage } from '../../../../common/architecture/scripts/Script';
+import StylesheetScript from '../../../../common/architecture/scripts/stylesheet/StylesheetScript';
 
 export default class CCDarkThemeInjectAutoDarkTheme extends StylesheetScript {
   stylesheet = 'ccDarkTheme.bundle.css';
diff --git a/src/features/ccDarkTheme/scripts/injectForcedDarkTheme.script.ts b/src/features/ccDarkTheme/presentation/scripts/injectForcedDarkTheme.script.ts
similarity index 78%
rename from src/features/ccDarkTheme/scripts/injectForcedDarkTheme.script.ts
rename to src/features/ccDarkTheme/presentation/scripts/injectForcedDarkTheme.script.ts
index 04c624a..0a16a70 100644
--- a/src/features/ccDarkTheme/scripts/injectForcedDarkTheme.script.ts
+++ b/src/features/ccDarkTheme/presentation/scripts/injectForcedDarkTheme.script.ts
@@ -1,5 +1,5 @@
-import { ScriptPage } from '../../../common/architecture/scripts/Script';
-import StylesheetScript from '../../../common/architecture/scripts/stylesheet/StylesheetScript';
+import { ScriptPage } from '../../../../common/architecture/scripts/Script';
+import StylesheetScript from '../../../../common/architecture/scripts/stylesheet/StylesheetScript';
 
 export default class CCDarkThemeInjectForcedDarkTheme extends StylesheetScript {
   stylesheet = 'ccDarkTheme.bundle.css';
diff --git a/src/features/infiniteScroll/nodeWatcherHandlers/ccInfiniteScrollLoadMoreBar.handler.ts b/src/features/infiniteScroll/presentation/nodeWatcherHandlers/ccInfiniteScrollLoadMoreBar.handler.ts
similarity index 63%
rename from src/features/infiniteScroll/nodeWatcherHandlers/ccInfiniteScrollLoadMoreBar.handler.ts
rename to src/features/infiniteScroll/presentation/nodeWatcherHandlers/ccInfiniteScrollLoadMoreBar.handler.ts
index d1068e3..c776588 100644
--- a/src/features/infiniteScroll/nodeWatcherHandlers/ccInfiniteScrollLoadMoreBar.handler.ts
+++ b/src/features/infiniteScroll/presentation/nodeWatcherHandlers/ccInfiniteScrollLoadMoreBar.handler.ts
@@ -1,6 +1,6 @@
-import { NodeMutation } from '../../../presentation/nodeWatcher/NodeWatcherHandler';
-import CCInfiniteScroll from '../core/ccInfiniteScroll';
-import CssSelectorNodeWatcherHandler from '../../../infrastructure/presentation/nodeWatcher/handlers/CssSelectorHandler.adapter';
+import { NodeMutation } from '../../../../presentation/nodeWatcher/NodeWatcherHandler';
+import CCInfiniteScroll from '../../core/ccInfiniteScroll';
+import CssSelectorNodeWatcherHandler from '../../../../infrastructure/presentation/nodeWatcher/handlers/CssSelectorHandler.adapter';
 
 export default class CCInfiniteScrollLoadMoreBarHandler extends CssSelectorNodeWatcherHandler {
   cssSelector = '.load-more-bar';
diff --git a/src/features/infiniteScroll/nodeWatcherHandlers/ccInfiniteScrollLoadMoreBtn.handler.ts b/src/features/infiniteScroll/presentation/nodeWatcherHandlers/ccInfiniteScrollLoadMoreBtn.handler.ts
similarity index 66%
rename from src/features/infiniteScroll/nodeWatcherHandlers/ccInfiniteScrollLoadMoreBtn.handler.ts
rename to src/features/infiniteScroll/presentation/nodeWatcherHandlers/ccInfiniteScrollLoadMoreBtn.handler.ts
index 0dd8db6..2f3e72a 100644
--- a/src/features/infiniteScroll/nodeWatcherHandlers/ccInfiniteScrollLoadMoreBtn.handler.ts
+++ b/src/features/infiniteScroll/presentation/nodeWatcherHandlers/ccInfiniteScrollLoadMoreBtn.handler.ts
@@ -1,6 +1,6 @@
-import { NodeMutation } from '../../../presentation/nodeWatcher/NodeWatcherHandler';
-import CssSelectorNodeWatcherHandler from '../../../infrastructure/presentation/nodeWatcher/handlers/CssSelectorHandler.adapter';
-import CCInfiniteScroll from '../core/ccInfiniteScroll';
+import { NodeMutation } from '../../../../presentation/nodeWatcher/NodeWatcherHandler';
+import CssSelectorNodeWatcherHandler from '../../../../infrastructure/presentation/nodeWatcher/handlers/CssSelectorHandler.adapter';
+import CCInfiniteScroll from '../../core/ccInfiniteScroll';
 
 export default class CCInfiniteScrollLoadMoreBtnHandler extends CssSelectorNodeWatcherHandler {
   cssSelector =
diff --git a/src/features/infiniteScroll/nodeWatcherHandlers/ccInfiniteScrollSetUp.handler.ts b/src/features/infiniteScroll/presentation/nodeWatcherHandlers/ccInfiniteScrollSetUp.handler.ts
similarity index 62%
rename from src/features/infiniteScroll/nodeWatcherHandlers/ccInfiniteScrollSetUp.handler.ts
rename to src/features/infiniteScroll/presentation/nodeWatcherHandlers/ccInfiniteScrollSetUp.handler.ts
index 0d77cf7..ad6e153 100644
--- a/src/features/infiniteScroll/nodeWatcherHandlers/ccInfiniteScrollSetUp.handler.ts
+++ b/src/features/infiniteScroll/presentation/nodeWatcherHandlers/ccInfiniteScrollSetUp.handler.ts
@@ -1,6 +1,6 @@
-import { NodeMutation } from '../../../presentation/nodeWatcher/NodeWatcherHandler';
-import CssSelectorNodeWatcherHandler from '../../../infrastructure/presentation/nodeWatcher/handlers/CssSelectorHandler.adapter';
-import CCInfiniteScroll from '../core/ccInfiniteScroll';
+import { NodeMutation } from '../../../../presentation/nodeWatcher/NodeWatcherHandler';
+import CssSelectorNodeWatcherHandler from '../../../../infrastructure/presentation/nodeWatcher/handlers/CssSelectorHandler.adapter';
+import CCInfiniteScroll from '../../core/ccInfiniteScroll';
 
 export default class CCInfiniteScrollSetUpHandler extends CssSelectorNodeWatcherHandler {
   cssSelector = 'ec-app, .scrollable-content';