Skip to content

Commit c8dc99d

Browse files
committed
Fix docs website broken anchors
1 parent 79085e2 commit c8dc99d

File tree

8 files changed

+27
-19
lines changed

8 files changed

+27
-19
lines changed

website/docs/commands/publishing/publish.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -285,7 +285,7 @@ or relative (beware of name clashes with pre-defined repositories above).
285285
### Authentication
286286

287287
Specify publish repository authentication either on the command-line or via
288-
using directives. See user / password / realm in the [settings table](#settings)
288+
using directives. See user / password / realm in the [settings table](#other-settings)
289289
and the [CI overrides](#ci-overrides).
290290

291291
### Connection parameters configuration

website/docusaurus.config.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ module.exports = {
99
url: 'https://scala-cli.virtuslab.org/',
1010
baseUrl: '/',
1111
onBrokenLinks: 'throw',
12+
onBrokenAnchors: 'warn',
1213
markdown: {
1314
hooks: {
1415
onBrokenMarkdownLinks: 'warn'
@@ -39,7 +40,7 @@ module.exports = {
3940
{
4041
// type: 'doc',
4142
label: "Use cases",
42-
to: '/#use_cases',
43+
to: '/',
4344
items: [
4445
{
4546
to: '/education',

website/src/pages/install.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import React from 'react';
22
import Layout from '@theme/Layout';
3+
import Heading from '@theme/Heading';
34

45
import Section from "../components/Section"
56
import BigHeader from "../components/BigHeader"
@@ -12,7 +13,6 @@ const Index = (props) => {
1213

1314
<div className="container content">
1415

15-
1616
{/* Install Scala CLI */}
1717
<Section className="section-install-cli">
1818
<div className="row">
@@ -30,7 +30,10 @@ const Index = (props) => {
3030

3131

3232
<Section className="section-about advanced-install">
33-
33+
{/* Anchor targets for deep linking - using Heading so Docusaurus can detect them */}
34+
<Heading as="h2" id="advanced-installation" style={{display: 'none', margin: 0, padding: 0}}>Advanced Installation</Heading>
35+
<Heading as="h2" id="scala-js" style={{display: 'none', margin: 0, padding: 0}}>Scala.js</Heading>
36+
<Heading as="h2" id="scala-native" style={{display: 'none', margin: 0, padding: 0}}>Scala Native</Heading>
3437
<AdvancedInstallation/>
3538

3639
</Section>

website/src/scss/_variables.scss

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
$theme-red: #F23135;
2+
$theme-yellow: #FFD583;
3+

website/src/scss/components/section-install-cli.scss

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
@use '../variables' as *;
2+
13
.section-install-cli {
24
margin-top: 130px;
35
margin-bottom: 130px;

website/src/scss/components/section-use-tiles.scss

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
@use '../variables' as *;
2+
13
.section-use-tiles {
24
margin-top: 130px;
35
margin-bottom: 130px;

website/src/scss/components/section-yellow-banner.scss

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
@use '../variables' as *;
2+
13
.section-yellow-banner {
24
margin-top: 50px;
35
margin-bottom: 130px;

website/src/scss/style.scss

Lines changed: 10 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,17 @@
11

2-
$theme-red: #F23135;
3-
$theme-yellow: #FFD583;
2+
@use 'variables' as *;
3+
@use 'components/section-base' as *;
4+
@use 'components/section-image-box' as *;
5+
@use 'components/section-features' as *;
6+
@use 'components/section-about' as *;
7+
@use 'components/section-yellow-banner' as *;
8+
@use 'components/section-use-tiles' as *;
9+
@use 'components/section-install-cli' as *;
10+
@use 'components/tooltip' as *;
11+
@use 'components/runnable-sample' as *;
412

513
@import url('https://fonts.googleapis.com/css2?family=Roboto+Mono:wght@400;500;700&display=swap');
614

7-
@import 'components/section-base';
8-
9-
@import 'components/section-image-box';
10-
@import 'components/section-features';
11-
@import 'components/section-about';
12-
13-
@import "./components/section-yellow-banner";
14-
@import "./components/section-use-tiles";
15-
@import "./components/section-install-cli";
16-
17-
@import "./components/tooltip";
18-
@import "./components/runnable-sample";
19-
2015
@font-face {
2116
font-family: "Roboto Mono", monospace;
2217
src: url('https://fonts.googleapis.com/css2?family=Roboto+Mono:wght@400;500;700&display=swap');

0 commit comments

Comments
 (0)