Skip to content

Commit

Permalink
Merge pull request #21 from saadiqbal-dev/main
Browse files Browse the repository at this point in the history
Toggle modal on commit
  • Loading branch information
elliotBraem authored Apr 12, 2024
2 parents 3abef71 + 3f450a6 commit b22967d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
8 changes: 7 additions & 1 deletion apps/canvas/widget/hyperfile/create.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,13 @@ const handleCreate = () => {
}

// sometimes we're not logged in, so it doesn't do anything!
Social.set(hyperfile, { force: true });
Social.set(hyperfile, {
force: true,
onCommit: () => {
// close modal
props.toggleModal();
},
});
});
}
};
Expand Down
2 changes: 1 addition & 1 deletion apps/canvas/widget/tldraw/ShareZone.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,7 @@ return (
<div className="w-100">
<Widget
src={activePlugin.interface.src}
props={activePlugin.interface.props}
props={{ ...activePlugin.interface.props, toggleModal }}
/>
</div>
<Widget
Expand Down

0 comments on commit b22967d

Please sign in to comment.