refactor: divide DeployList

This commit is contained in:
Fu Diwei
2024-10-22 17:44:39 +08:00
parent e53749e16e
commit 062d66222a
13 changed files with 1030 additions and 747 deletions

View File

@@ -0,0 +1,16 @@
import { createContext, useContext } from "react";
import { DeployConfig } from "@/domain/domain";
type DeployEditContext = {
deploy: DeployConfig;
error: Record<string, string>;
setDeploy: (deploy: DeployConfig) => void;
setError: (error: Record<string, string>) => void;
};
export const Context = createContext<DeployEditContext>({} as DeployEditContext);
export const useDeployEditContext = () => {
return useContext(Context);
};