Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion app/components/MakeRealButton.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { useEditor, useToasts } from '@tldraw/tldraw'
import { useCallback } from 'react'
import { makeReal } from '../makeReal'
import { makeReal } from '../lib/makeReal'

export function MakeRealButton() {
const editor = useEditor()
Expand Down
10 changes: 5 additions & 5 deletions app/lib/makeReal.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import { Editor, createShapeId, getSvgAsImage, track } from '@tldraw/tldraw'
import { getSelectionAsText } from './lib/getSelectionAsText'
import { getHtmlFromOpenAI } from './lib/getHtmlFromOpenAI'
import { blobToBase64 } from './lib/blobToBase64'
import { addGridToSvg } from './lib/addGridToSvg'
import { PreviewShape } from './PreviewShape/PreviewShape'
import { getSelectionAsText } from './getSelectionAsText'
import { getHtmlFromOpenAI } from './getHtmlFromOpenAI'
import { blobToBase64 } from './blobToBase64'
import { addGridToSvg } from './addGridToSvg'
import { PreviewShape } from '../PreviewShape/PreviewShape'

export async function makeReal(editor: Editor, apiKey: string) {
// Get the selected shapes (we need at least one)
Expand Down