Skip to content

Commit 69452b8

Browse files
authored
Merge branch 'main' into add-hubsport-script-loader
2 parents b7edb9c + ec475be commit 69452b8

5 files changed

Lines changed: 30 additions & 6 deletions

File tree

.github/workflows/ci.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,9 @@ jobs:
1414
env:
1515
AZURE_STATIC_WEB_APPS_API_TOKEN_HAPPY_OCEAN_048B8E60F: ${{ secrets.AZURE_STATIC_WEB_APPS_API_TOKEN_HAPPY_OCEAN_048B8E60F }}
1616
runs-on: ubuntu-latest
17+
permissions:
18+
contents: read
19+
pull-requests: write
1720
name: Build and Deploy Job
1821
steps:
1922
- uses: actions/checkout@v2
@@ -46,6 +49,10 @@ jobs:
4649
env:
4750
AZURE_STATIC_WEB_APPS_API_TOKEN_HAPPY_OCEAN_048B8E60F: ${{ secrets.AZURE_STATIC_WEB_APPS_API_TOKEN_HAPPY_OCEAN_048B8E60F }}
4851
runs-on: ubuntu-latest
52+
permissions:
53+
contents: read
54+
pull-requests: write
55+
issues: write
4956
name: Close Pull Request Job
5057
steps:
5158
- name: Close Pull Request

.github/workflows/link-checker.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,10 @@ on:
1515
jobs:
1616
link_checker_job:
1717
runs-on: ubuntu-latest
18+
permissions:
19+
contents: read
20+
pull-requests: write
21+
issues: write
1822
name: Link Checker Job
1923
steps:
2024
- uses: actions/checkout@v2

astro.config.mjs

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// @ts-check
2-
import { defineConfig } from "astro/config";
2+
import { defineConfig, fontProviders } from "astro/config";
33
import starlight from "@astrojs/starlight";
44
import starlightLinksValidator from "starlight-links-validator";
55
import starlightClientMermaid from "@pasqal-io/starlight-client-mermaid";
@@ -18,6 +18,18 @@ export default defineConfig({
1818
site: "https://docs.duendesoftware.com",
1919
trailingSlash: "ignore",
2020
redirects: {},
21+
experimental: {
22+
fonts: [
23+
{
24+
provider: fontProviders.google(),
25+
name: "Roboto",
26+
cssVariable: "--font-roboto",
27+
weights: ["100 900", "bold"],
28+
styles: ["normal", "italic"],
29+
display: "swap",
30+
},
31+
],
32+
},
2133
integrations: [
2234
starlight({
2335
customCss: ["./src/styles/custom.css"],

src/components/Head.astro

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
11
---
22
import { getImagePath } from "astro-opengraph-images";
3+
import { Font } from "astro:assets";
34
45
const { head } = Astro.locals.starlightRoute;
56
const { url, site } = Astro;
67
const openGraphImageUrl = getImagePath({ url, site });
78
---
89

910
{head.map(({ tag: Tag, attrs, content }) => <Tag {...attrs} set:html={content} />)}
10-
{openGraphImageUrl && (<meta property="og:image" content={openGraphImageUrl} />)}
11+
{openGraphImageUrl && (<meta property="og:image" content={openGraphImageUrl} />)}
12+
<Font cssVariable="--font-roboto" preload />

src/styles/custom.css

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
1-
/* Font */
2-
@import url('https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100..900;1,100..900&display=swap');
3-
41
/* Dark mode colors. */
52
:root {
6-
--sl-font: 'Roboto';
3+
/* coming from Astro Font support. See astro.config.mjs */
4+
/*noinspection CssUnresolvedCustomProperty*/
5+
--sl-font: var(--font-roboto);
76
--sl-color-accent-low: #43257c;
87
--sl-color-accent: #6e45af;
98
--sl-color-accent-high: #916bdb;

0 commit comments

Comments
 (0)