27 | {code}
28 |
29 | )
30 | }
31 |
--------------------------------------------------------------------------------
/components/deploy-dialog.tsx:
--------------------------------------------------------------------------------
1 | import Logo from './logo'
2 | import { CopyButton } from './ui/copy-button'
3 | import {
4 | Select,
5 | SelectContent,
6 | SelectGroup,
7 | SelectItem,
8 | SelectLabel,
9 | SelectTrigger,
10 | SelectValue,
11 | } from './ui/select'
12 | import { publish } from '@/app/actions/publish'
13 | import { Button } from '@/components/ui/button'
14 | import {
15 | DropdownMenu,
16 | DropdownMenuContent,
17 | DropdownMenuTrigger,
18 | } from '@/components/ui/dropdown-menu'
19 | import { Input } from '@/components/ui/input'
20 | import { Duration } from '@/lib/duration'
21 | import { usePostHog } from 'posthog-js/react'
22 | import { useEffect, useState } from 'react'
23 |
24 | export function DeployDialog({
25 | url,
26 | sbxId,
27 | teamID,
28 | accessToken,
29 | }: {
30 | url: string
31 | sbxId: string
32 | teamID: string | undefined
33 | accessToken: string | undefined
34 | }) {
35 | const posthog = usePostHog()
36 |
37 | const [publishedURL, setPublishedURL] = useState21 | {out} 22 |23 | ))} 24 | {stderr && 25 | stderr.length > 0 && 26 | stderr.map((err: string, index: number) => ( 27 |
28 | {err} 29 |30 | ))} 31 |
30 | Star on GitHub 31 |
32 |