kopia lustrzana https://github.com/transitive-bullshit/chatgpt-api
feat(web): subscribe button should link to sign up if not logged in with next to pricing tab
rodzic
c3d39f1d62
commit
8167006e20
|
@ -484,6 +484,10 @@ function ProjectHeader({
|
|||
project: Project
|
||||
tab?: MarketplacePublicProjectDetailTab
|
||||
}) {
|
||||
const ctx = useAgentic()
|
||||
|
||||
const pricingTabHref = `/marketplace/projects/${project.identifier}?tab=pricing`
|
||||
|
||||
return (
|
||||
<>
|
||||
{/* <MarketplacePublicProjectDetailNav
|
||||
|
@ -513,7 +517,11 @@ function ProjectHeader({
|
|||
asChild={tab !== 'pricing'}
|
||||
>
|
||||
<Link
|
||||
href={`/marketplace/projects/${project.identifier}?tab=pricing`}
|
||||
href={
|
||||
ctx?.isAuthenticated
|
||||
? pricingTabHref
|
||||
: `/signup?${sanitizeSearchParams({ next: pricingTabHref })}`
|
||||
}
|
||||
>
|
||||
Subscribe to {project.identifier}
|
||||
</Link>
|
||||
|
|
|
@ -18,7 +18,7 @@ import { useLocalStorage } from 'react-use'
|
|||
|
||||
import * as config from '@/lib/config'
|
||||
|
||||
type AgenticContextType = {
|
||||
export type AgenticContextType = {
|
||||
api: AgenticApiClient
|
||||
isAuthenticated: boolean
|
||||
logout: () => void
|
||||
|
|
|
@ -11,6 +11,9 @@ import { calendarBookingUrl, githubUrl } from '@/lib/config'
|
|||
import { useAgentic } from './agentic-provider'
|
||||
import { GitHubStarCounter } from './github-star-counter'
|
||||
|
||||
const docsPublishingQuickStartUrl =
|
||||
'https://docs.agentic.so/publishing/quickstart'
|
||||
|
||||
export function SupplySideCTA({
|
||||
variant = 'github',
|
||||
heroVariant = 'orange'
|
||||
|
@ -26,9 +29,9 @@ export function SupplySideCTA({
|
|||
<Link
|
||||
href={
|
||||
ctx?.isAuthenticated
|
||||
? 'https://docs.agentic.so/publishing/quickstart'
|
||||
? docsPublishingQuickStartUrl
|
||||
: `/signup?${sanitizeSearchParams({
|
||||
next: 'https://docs.agentic.so/publishing/quickstart'
|
||||
next: docsPublishingQuickStartUrl
|
||||
})}`
|
||||
}
|
||||
>
|
||||
|
|
1
todo.md
1
todo.md
|
@ -21,7 +21,6 @@
|
|||
- tool input/output schemas; move `$schema` to the top
|
||||
- break out into a few subcomponents; some can be server components
|
||||
- mcp inspector
|
||||
- subscribe button should link to sign up if not logged in with next to pricing tab
|
||||
- improve private project page
|
||||
- link to public page if published
|
||||
- list deployment versions
|
||||
|
|
Ładowanie…
Reference in New Issue