mirror of
https://github.com/wavetermdev/waveterm.git
synced 2025-11-28 13:10:24 +08:00
* Kebab Menu + Switch App Functionality * Updated Secrets Tab (still more to do, but closer) * Better Error Handling (Switch to Secrets Tab) * Add AppInit functionality to Tsunami (fixes initialization issues and races with embedded assets, and error handling) * Tsunami - ListStaticFiles * Tsunami - More Robust Manifest generation (even when there are extra stdout messages)
26 lines
1.4 KiB
TypeScript
26 lines
1.4 KiB
TypeScript
// Copyright 2025, Command Line Inc.
|
|
// SPDX-License-Identifier: Apache-2.0
|
|
|
|
import { MessageModal } from "@/app/modals/messagemodal";
|
|
import { NewInstallOnboardingModal } from "@/app/onboarding/onboarding";
|
|
import { UpgradeOnboardingModal } from "@/app/onboarding/onboarding-upgrade";
|
|
import { DeleteFileModal, PublishAppModal, RenameFileModal } from "@/builder/builder-apppanel";
|
|
import { SetSecretDialog } from "@/builder/tabs/builder-secrettab";
|
|
import { AboutModal } from "./about";
|
|
import { UserInputModal } from "./userinputmodal";
|
|
|
|
const modalRegistry: { [key: string]: React.ComponentType<any> } = {
|
|
[NewInstallOnboardingModal.displayName || "NewInstallOnboardingModal"]: NewInstallOnboardingModal,
|
|
[UpgradeOnboardingModal.displayName || "UpgradeOnboardingModal"]: UpgradeOnboardingModal,
|
|
[UserInputModal.displayName || "UserInputModal"]: UserInputModal,
|
|
[AboutModal.displayName || "AboutModal"]: AboutModal,
|
|
[MessageModal.displayName || "MessageModal"]: MessageModal,
|
|
[PublishAppModal.displayName || "PublishAppModal"]: PublishAppModal,
|
|
[RenameFileModal.displayName || "RenameFileModal"]: RenameFileModal,
|
|
[DeleteFileModal.displayName || "DeleteFileModal"]: DeleteFileModal,
|
|
[SetSecretDialog.displayName || "SetSecretDialog"]: SetSecretDialog,
|
|
};
|
|
|
|
export const getModalComponent = (key: string): React.ComponentType<any> | undefined => {
|
|
return modalRegistry[key];
|
|
};
|