2026-03-18 18:30:06 -05:00
|
|
|
---
|
|
|
|
|
import type { CollectionEntry } from "astro:content";
|
|
|
|
|
import { api } from "../core/api/dynamic";
|
2026-03-19 13:26:34 -05:00
|
|
|
import ApiDescription from "./ApiDescription.astro";
|
2026-03-18 18:30:06 -05:00
|
|
|
import { ApiTester } from "./ApiTester";
|
|
|
|
|
|
|
|
|
|
interface Props {
|
|
|
|
|
locale: string;
|
|
|
|
|
api: CollectionEntry<"api">;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
const { locale, api: apiData } = Astro.props;
|
|
|
|
|
const strings = await api.strings(locale);
|
2026-03-19 13:26:34 -05:00
|
|
|
const body = apiData.data.docs ?? strings.api.no_docs;
|
2026-03-18 18:30:06 -05:00
|
|
|
---
|
|
|
|
|
|
|
|
|
|
<style>
|
|
|
|
|
.container {
|
|
|
|
|
display: flex;
|
|
|
|
|
flex-direction: column;
|
|
|
|
|
}
|
|
|
|
|
</style>
|
|
|
|
|
|
|
|
|
|
<div class="container">
|
|
|
|
|
<ApiTester client:idle {locale} path={apiData.id} />
|
2026-03-19 17:17:23 -05:00
|
|
|
<ApiDescription {locale} {body} />
|
2026-03-18 18:30:06 -05:00
|
|
|
</div>
|