issues-95 get saving and forking to work

This commit is contained in:
Kurt Hutten
2020-11-14 19:44:40 +11:00
parent 7abdd87f03
commit 955f4c9e83
7 changed files with 82 additions and 24 deletions

View File

@@ -60,7 +60,18 @@ const IdeCascadeStudio = ({ part, saveCode, loading, error }) => {
<IdeToolbar
canEdit={canEdit}
isChanges={isChanges && !loading}
onSave={() => {}}
onSave={() => {
saveCode({
input: {
code,
title: part?.title,
userId: currentUser?.sub,
description: part?.description,
},
id: part.id,
isFork: !canEdit,
})
}}
onExport={(type) => threejsViewport[`saveShape${type}`]()}
/>
<div id="topnav" className="topnav hidden">