From 190f8ea86d1c865da73a2bdc5346b16b8622e345 Mon Sep 17 00:00:00 2001 From: Jari Kolehmainen Date: Mon, 16 Jan 2023 19:42:57 +0200 Subject: [PATCH] move IpcRendererNavigationEvents to common Signed-off-by: Jari Kolehmainen --- src/common/catalog-entities/kubernetes-cluster.ts | 2 +- src/common/front-end-routing/app-navigation-channel.ts | 2 +- .../front-end-routing/cluster-frame-navigation-channel.ts | 2 +- .../navigation/events.ts => common/ipc/navigation-events.ts} | 0 .../start-main-application/lens-window/navigate.injectable.ts | 2 +- src/renderer/components/command-palette/command-dialog.tsx | 2 +- src/renderer/components/layout/sidebar-cluster.tsx | 2 +- src/renderer/routes/navigate-to-url.injectable.ts | 2 +- 8 files changed, 7 insertions(+), 7 deletions(-) rename src/{renderer/navigation/events.ts => common/ipc/navigation-events.ts} (100%) diff --git a/src/common/catalog-entities/kubernetes-cluster.ts b/src/common/catalog-entities/kubernetes-cluster.ts index d47ab47831b8..57cac07122f6 100644 --- a/src/common/catalog-entities/kubernetes-cluster.ts +++ b/src/common/catalog-entities/kubernetes-cluster.ts @@ -8,7 +8,7 @@ import { CatalogEntity, CatalogCategory, categoryVersion } from "../catalog/cata import { broadcastMessage } from "../ipc"; import { app } from "electron"; import type { CatalogEntityConstructor, CatalogEntitySpec } from "../catalog/catalog-entity"; -import { IpcRendererNavigationEvents } from "../../renderer/navigation/events"; +import { IpcRendererNavigationEvents } from "../ipc/navigation-events"; import { requestClusterActivation, requestClusterDisconnection } from "../../renderer/ipc"; import KubeClusterCategoryIcon from "./icons/kubernetes.svg"; import getClusterByIdInjectable from "../cluster-store/get-by-id.injectable"; diff --git a/src/common/front-end-routing/app-navigation-channel.ts b/src/common/front-end-routing/app-navigation-channel.ts index e0b881eff928..b3d8f02c66cf 100644 --- a/src/common/front-end-routing/app-navigation-channel.ts +++ b/src/common/front-end-routing/app-navigation-channel.ts @@ -2,7 +2,7 @@ * Copyright (c) OpenLens Authors. All rights reserved. * Licensed under MIT License. See LICENSE in root directory for more information. */ -import { IpcRendererNavigationEvents } from "../../renderer/navigation/events"; +import { IpcRendererNavigationEvents } from "../ipc/navigation-events"; import type { MessageChannel } from "../utils/channel/message-channel-listener-injection-token"; export type AppNavigationChannel = MessageChannel; diff --git a/src/common/front-end-routing/cluster-frame-navigation-channel.ts b/src/common/front-end-routing/cluster-frame-navigation-channel.ts index 9d9a1904afba..2439f523e2a3 100644 --- a/src/common/front-end-routing/cluster-frame-navigation-channel.ts +++ b/src/common/front-end-routing/cluster-frame-navigation-channel.ts @@ -2,7 +2,7 @@ * Copyright (c) OpenLens Authors. All rights reserved. * Licensed under MIT License. See LICENSE in root directory for more information. */ -import { IpcRendererNavigationEvents } from "../../renderer/navigation/events"; +import { IpcRendererNavigationEvents } from "../ipc/navigation-events"; import type { MessageChannel } from "../utils/channel/message-channel-listener-injection-token"; export type ClusterFrameNavigationChannel = MessageChannel; diff --git a/src/renderer/navigation/events.ts b/src/common/ipc/navigation-events.ts similarity index 100% rename from src/renderer/navigation/events.ts rename to src/common/ipc/navigation-events.ts diff --git a/src/main/start-main-application/lens-window/navigate.injectable.ts b/src/main/start-main-application/lens-window/navigate.injectable.ts index 8b204be9b3fa..7bcd14072bc6 100644 --- a/src/main/start-main-application/lens-window/navigate.injectable.ts +++ b/src/main/start-main-application/lens-window/navigate.injectable.ts @@ -5,7 +5,7 @@ import { getInjectable } from "@ogre-tools/injectable"; import { iter } from "../../../common/utils"; import clusterFramesInjectable from "../../../common/cluster-frames.injectable"; -import { IpcRendererNavigationEvents } from "../../../renderer/navigation/events"; +import { IpcRendererNavigationEvents } from "../../../common/ipc/navigation-events"; import showApplicationWindowInjectable from "./show-application-window.injectable"; import getCurrentApplicationWindowInjectable from "./application-window/get-current-application-window.injectable"; import assert from "assert"; diff --git a/src/renderer/components/command-palette/command-dialog.tsx b/src/renderer/components/command-palette/command-dialog.tsx index db33bde1cdb9..ba4036f4c572 100644 --- a/src/renderer/components/command-palette/command-dialog.tsx +++ b/src/renderer/components/command-palette/command-dialog.tsx @@ -11,7 +11,7 @@ import React, { useState } from "react"; import commandOverlayInjectable from "./command-overlay.injectable"; import type { CatalogEntity } from "../../../common/catalog"; import { broadcastMessage } from "../../../common/ipc"; -import { IpcRendererNavigationEvents } from "../../navigation/events"; +import { IpcRendererNavigationEvents } from "../../../common/ipc/navigation-events"; import type { RegisteredCommand } from "./registered-commands/commands"; import { iter } from "../../utils"; import { withInjectables } from "@ogre-tools/injectable-react"; diff --git a/src/renderer/components/layout/sidebar-cluster.tsx b/src/renderer/components/layout/sidebar-cluster.tsx index 55f3f20ecf38..24b0622a857f 100644 --- a/src/renderer/components/layout/sidebar-cluster.tsx +++ b/src/renderer/components/layout/sidebar-cluster.tsx @@ -8,7 +8,7 @@ import { observable } from "mobx"; import React, { useState } from "react"; import { broadcastMessage } from "../../../common/ipc"; import type { CatalogEntity, CatalogEntityContextMenu } from "../../api/catalog-entity"; -import { IpcRendererNavigationEvents } from "../../navigation/events"; +import { IpcRendererNavigationEvents } from "../../../common/ipc/navigation-events"; import { Avatar } from "../avatar"; import { Icon } from "../icon"; import { Menu, MenuItem } from "../menu"; diff --git a/src/renderer/routes/navigate-to-url.injectable.ts b/src/renderer/routes/navigate-to-url.injectable.ts index 832080674ce0..616bfb643192 100644 --- a/src/renderer/routes/navigate-to-url.injectable.ts +++ b/src/renderer/routes/navigate-to-url.injectable.ts @@ -7,7 +7,7 @@ import observableHistoryInjectable from "../navigation/observable-history.inject import { runInAction } from "mobx"; import type { NavigateToUrl } from "../../common/front-end-routing/navigate-to-url-injection-token"; import { navigateToUrlInjectionToken } from "../../common/front-end-routing/navigate-to-url-injection-token"; -import { IpcRendererNavigationEvents } from "../navigation/events"; +import { IpcRendererNavigationEvents } from "../../common/ipc/navigation-events"; import broadcastMessageInjectable from "../../common/ipc/broadcast-message.injectable"; const navigateToUrlInjectable = getInjectable({