import type { Metadata } from "next"; import Link from "next/link"; import { getPaths } from "yt-dlp-transcript-common/lib/paths"; import { listSites } from "yt-dlp-transcript-common/lib/site"; import { sortGroups } from "yt-dlp-transcript-common/lib/channelGroups"; import { ChannelFormClient } from "../components/ChannelFormClient"; import type { SiteMembershipOption } from "../components/SiteMembershipsSection"; import { createChannelAction } from "../actions"; export const dynamic = "force-dynamic"; export const metadata: Metadata = { title: "New channel — Channels" }; export default async function NewChannelPage() { const sites: SiteMembershipOption[] = listSites(getPaths()).map((s) => ({ siteId: s.siteId, siteTitle: s.siteTitle, defaultGroupId: s.defaultGroupId, groups: sortGroups(s.groups).map((g) => ({ id: g.id, name: g.name })), })); return (
Channels / new

New channel

); }