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
6 changes: 6 additions & 0 deletions content/docs/kmp/guides/vibe-coding.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
title: "Vibe Coding"
description: "How to Vibe Code using the knowledge of the Superwall Docs"
---

<include>../../../shared/vibe-coding.mdx</include>
2 changes: 2 additions & 0 deletions content/docs/kmp/meta.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
"title": "KMP SDK",
"description": "Beta",
"icon": "Layers",
"root": true,
"pages": [
Expand All @@ -20,6 +21,7 @@
"guides/using-superwall-delegate",
"guides/3rd-party-analytics",
"guides/handling-deep-links",
"guides/vibe-coding",
"[Example App](https://github.com/superwall/Superwall-KMP/tree/main/sample)"
]
}
6 changes: 6 additions & 0 deletions content/docs/unity/guides/vibe-coding.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
title: "Vibe Coding"
description: "How to Vibe Code using the knowledge of the Superwall Docs"
---

<include>../../../shared/vibe-coding.mdx</include>
1 change: 1 addition & 0 deletions content/docs/unity/meta.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
"guides/using-superwall-delegate",
"guides/custom-purchase-controller",
"guides/advanced-configuration",
"guides/vibe-coding",

"---SDK Reference---",
"sdk-reference/index",
Expand Down
6 changes: 6 additions & 0 deletions content/docs/web/guides/vibe-coding.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
title: "Vibe Coding"
description: "How to Vibe Code using the knowledge of the Superwall Docs"
---

<include>../../../shared/vibe-coding.mdx</include>
2 changes: 2 additions & 0 deletions content/docs/web/meta.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
"title": "Web SDK",
"description": "Beta",
"icon": "Globe",
"root": true,
"pages": [
Expand All @@ -18,6 +19,7 @@
"guides/server-side-gating",
"guides/purchases",
"guides/events",
"guides/vibe-coding",
"[Example Apps](https://github.com/superwall/Superwall-Web/tree/main/example)"
]
}
4 changes: 4 additions & 0 deletions content/shared/vibe-coding.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -87,10 +87,14 @@ The Superwall Docs website has `llms.txt` and `llms-full.txt` files, in total an
| ------------------------- | --------------------------------------------------------------------------- | ------------------------------------------------------------------------------------- |
| All | [`llms.txt`](https://superwall.com/docs/llms.txt) | [`llms-full.txt`](https://superwall.com/docs/llms-full.txt) |
| Dashboard | [`dashboard/llms.txt`](https://superwall.com/docs/dashboard/llms.txt) | [`dashboard/llms-full.txt`](https://superwall.com/docs/dashboard/llms-full.txt) |
| Agents | [`agents/llms.txt`](https://superwall.com/docs/agents/llms.txt) | [`agents/llms-full.txt`](https://superwall.com/docs/agents/llms-full.txt) |
| iOS | [`ios/llms.txt`](https://superwall.com/docs/ios/llms.txt) | [`ios/llms-full.txt`](https://superwall.com/docs/ios/llms-full.txt) |
| Android | [`android/llms.txt`](https://superwall.com/docs/android/llms.txt) | [`android/llms-full.txt`](https://superwall.com/docs/android/llms-full.txt) |
| Flutter | [`flutter/llms.txt`](https://superwall.com/docs/flutter/llms.txt) | [`flutter/llms-full.txt`](https://superwall.com/docs/flutter/llms-full.txt) |
| Expo | [`expo/llms.txt`](https://superwall.com/docs/expo/llms.txt) | [`expo/llms-full.txt`](https://superwall.com/docs/expo/llms-full.txt) |
| KMP (Beta) | [`kmp/llms.txt`](https://superwall.com/docs/kmp/llms.txt) | [`kmp/llms-full.txt`](https://superwall.com/docs/kmp/llms-full.txt) |
| Unity (Beta) | [`unity/llms.txt`](https://superwall.com/docs/unity/llms.txt) | [`unity/llms-full.txt`](https://superwall.com/docs/unity/llms-full.txt) |
| Web (Beta) | [`web/llms.txt`](https://superwall.com/docs/web/llms.txt) | [`web/llms-full.txt`](https://superwall.com/docs/web/llms-full.txt) |
| React Native (Deprecated) | [`react-native/llms.txt`](https://superwall.com/docs/react-native/llms.txt) | [`react-native/llms-full.txt`](https://superwall.com/docs/react-native/llms-full.txt) |
| Integrations | [`integrations/llms.txt`](https://superwall.com/docs/integrations/llms.txt) | [`integrations/llms-full.txt`](https://superwall.com/docs/integrations/llms-full.txt) |
| Web Checkout | [`web-checkout/llms.txt`](https://superwall.com/docs/web-checkout/llms.txt) | [`web-checkout/llms-full.txt`](https://superwall.com/docs/web-checkout/llms-full.txt) |
Expand Down
26 changes: 1 addition & 25 deletions src/components/DocsHeader.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"use client";

import { cn } from "@/lib/cn";
import { getSdkTabLabel, isSdkTab } from "@/lib/sdk-tabs";
import { buttonVariants } from "fumadocs-ui/components/ui/button";
import { Popover, PopoverContent, PopoverTrigger } from "fumadocs-ui/components/ui/popover";
import {
Expand All @@ -15,31 +16,6 @@ import Link from "fumadocs-core/link";
import { ChevronDown, Languages, PanelLeft } from "lucide-react";
import { Fragment, useMemo, useRef, useState, type ComponentProps, type PointerEvent } from "react";

const SDK_TAB_LABELS: Record<string, string> = {
ios: "iOS",
android: "Android",
expo: "Expo",
flutter: "Flutter",
unity: "Unity",
"react-native": "React Native",
community: "Community",
};

const SDK_TAB_SLUGS = new Set(Object.keys(SDK_TAB_LABELS));

function getTabPrefix(url: string) {
return url.replace(/^\/docs\//, "").split("/")[0] ?? "";
}

function isSdkTab(tab: LayoutTab) {
return SDK_TAB_SLUGS.has(getTabPrefix(tab.url));
}

function getSdkTabLabel(tab: LayoutTab) {
const prefix = getTabPrefix(tab.url);
return SDK_TAB_LABELS[prefix] ?? String(tab.title);
}

function getSdkTabDescription(tab: LayoutTab) {
return tab.description;
}
Expand Down
Loading
Loading