108 lines
2.6 KiB
JavaScript
108 lines
2.6 KiB
JavaScript
// @ts-check
|
||
import { defineConfig, passthroughImageService } from 'astro/config';
|
||
import starlight from "@astrojs/starlight";
|
||
import startlightBlog from "starlight-blog";
|
||
import starlightScrollToTop from "starlight-scroll-to-top";
|
||
|
||
// https://astro.build/config
|
||
export default defineConfig({
|
||
integrations: [
|
||
starlight({
|
||
title: "Jabber.Space",
|
||
defaultLocale: "root",
|
||
customCss: ["./src/styles/global.css"],
|
||
locales: {
|
||
root: {
|
||
label: "English",
|
||
lang: "en"
|
||
},
|
||
ru: {
|
||
label: "Русский",
|
||
lang: "ru"
|
||
}
|
||
},
|
||
head: [],
|
||
social: [
|
||
{
|
||
icon: "github",
|
||
label: "Git",
|
||
href: "https://git.jabber.space/devs/cproof/"
|
||
}
|
||
],
|
||
editLink: {
|
||
baseUrl: "https://git.jabber.space/devs/jabber.space/src/branch/master"
|
||
},
|
||
lastUpdated: true,
|
||
sidebar: [
|
||
{
|
||
label: "Getting Started",
|
||
autogenerate: { directory: "getting-started" },
|
||
translations: {
|
||
'ru-RU': 'Введение',
|
||
},
|
||
},
|
||
{
|
||
label: "Guides",
|
||
autogenerate: { directory: "guides" },
|
||
translations: {
|
||
'ru-RU': 'Инструкции',
|
||
},
|
||
},
|
||
{
|
||
label: "Contributing",
|
||
autogenerate: { directory: "contributing" },
|
||
},
|
||
{
|
||
label: "About",
|
||
autogenerate: { directory: "about" },
|
||
translations: {
|
||
'ru-RU': 'О проекте',
|
||
},
|
||
},
|
||
{
|
||
label: "Blog",
|
||
link: "/blog/",
|
||
translations: {
|
||
'ru-RU': 'Блог',
|
||
},
|
||
},
|
||
{
|
||
label: "Command Reference",
|
||
link: "/command-reference/",
|
||
translations: {
|
||
'ru-RU': 'Список команд',
|
||
},
|
||
},
|
||
{
|
||
label: "API Reference",
|
||
badge: "C",
|
||
autogenerate: { directory: "/api-reference/c/" }
|
||
},
|
||
{
|
||
label: "API Reference",
|
||
badge: "Python",
|
||
autogenerate: { directory: "/api-reference/python/" }
|
||
}
|
||
],
|
||
plugins: [
|
||
startlightBlog({
|
||
navigation: "none"
|
||
}),
|
||
starlightScrollToTop({
|
||
position: "right",
|
||
tooltipText: "Scroll to top",
|
||
showTooltip: true,
|
||
smoothScroll: true,
|
||
threshold: 20,
|
||
svgPath: "M12 4L7 9H9V16H15V9H17L12 4M10 16L12 20L14 16",
|
||
svgStrokeWidth: 1,
|
||
borderRadius: "50"
|
||
})
|
||
]
|
||
})
|
||
],
|
||
image: {
|
||
service: passthroughImageService(),
|
||
},
|
||
});
|