@conduction/docusaurus-preset 3.14.0 → 3.15.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/css/brand.css +25 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@conduction/docusaurus-preset",
3
- "version": "3.14.0",
3
+ "version": "3.15.0",
4
4
  "scripts": {
5
5
  "prepack": "node scripts/prepack-bundle-css.js"
6
6
  },
package/src/css/brand.css CHANGED
@@ -311,6 +311,31 @@ a:not(.navbar__link):not(.footer__link-item):not(.button):hover {
311
311
  background: transparent;
312
312
  }
313
313
 
314
+ /* ============================================================
315
+ Heading anchor hash glyphs.
316
+
317
+ Docusaurus auto-generates a hidden `<a class="hash-link">#</a>`
318
+ inside every h2-h6 so readers can copy a deep link. Default
319
+ Infima styling renders the glyph in the primary brand colour
320
+ (cobalt) which is fine for the visible state, but the affordance
321
+ reads stronger when the hash itself lights up in KNVB orange
322
+ the moment the cursor touches it.
323
+
324
+ We render the glyph in cobalt-300 by default (visible-on-hover
325
+ of the heading, via the theme's anchorWithStickyNavbar rule)
326
+ and flip it to var(--c-orange-knvb) the moment the user hovers
327
+ or focuses the hash itself.
328
+ ============================================================ */
329
+ .hash-link {
330
+ color: var(--c-cobalt-300);
331
+ transition: color 120ms ease;
332
+ }
333
+ .hash-link:hover,
334
+ .hash-link:focus-visible {
335
+ color: var(--c-orange-knvb);
336
+ text-decoration: none;
337
+ }
338
+
314
339
  /* ============================================================
315
340
  Body grows with content.
316
341