Skip to content

Commit

Permalink
comment out copy project, need a better flow
Browse files Browse the repository at this point in the history
  • Loading branch information
bthaile committed Sep 21, 2023
1 parent b9d61c8 commit bbc58fb
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 18 deletions.
36 changes: 18 additions & 18 deletions src/components/LeftSidebar/ProjectListItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ import paths from '../../paths';
import { useProject } from 'providers/Project/projectHooks';
import InformationalPopup from 'components/InformationalPopup';
import { LOCAL_PROJECT_ID } from 'util/url';
import CopyIcon from 'components/Icons/CopyIcon';
import { Project } from 'api/apollo/generated/graphql';
//import CopyIcon from 'components/Icons/CopyIcon';
//import { Project } from 'api/apollo/generated/graphql';
import { userDataKeys, UserLocalStorage } from 'util/localstorage';
import ResetIcon from 'components/Icons/ResetIcon';

Expand Down Expand Up @@ -61,7 +61,7 @@ const ProjectListItem = ({ project, projectCount, refetch }: Props) => {
deleteProject,
resetProject,
project: activeProject,
copyProject,
// copyProject,
} = useProject();

const context = useThemeUI();
Expand Down Expand Up @@ -149,15 +149,15 @@ const ProjectListItem = ({ project, projectCount, refetch }: Props) => {
}
};

const copyNewProject = async (project: Project) => {
setDoingAction(true);
try {
await copyProject(project);
await refetch();
} finally {
setDoingAction(false);
}
};
// const copyNewProject = async (project: Project) => {
// setDoingAction(true);
// try {
// await copyProject(project);
// await refetch();
// } finally {
// setDoingAction(false);
// }
// };

const contextMenuOptions = [
{
Expand All @@ -168,12 +168,12 @@ const ProjectListItem = ({ project, projectCount, refetch }: Props) => {
: setShowLastProject(true),
icon: DeleteIcon,
},
{
name: 'Copy Project',
onClick: (project: Project) => copyNewProject(project),
icon: CopyIcon,
args: [project],
},
// {
// name: 'Copy Project',
// onClick: (project: Project) => copyNewProject(project),
// icon: CopyIcon,
// args: [project],
// },
{
name: 'Reset Project',
onClick: () => setShowResetConfirmation(true),
Expand Down
1 change: 1 addition & 0 deletions src/providers/Project/projectDefault.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ transaction(greeting: String) {
`;

const DEFAULT_SCRIPT = `import HelloWorld from 0x05
pub fun main() {
log(HelloWorld.hello())
}
Expand Down

0 comments on commit bbc58fb

Please sign in to comment.