@commonpub/layer 0.21.6 → 0.21.7

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.
@@ -139,8 +139,11 @@ const isEnded = computed(() => c.value?.status === 'completed' || c.value?.statu
139
139
  --hero-bg: var(--text);
140
140
  --hero-text: var(--color-text-inverse);
141
141
  --hero-text-dim: var(--text-faint);
142
- --hero-border: rgba(255, 255, 255, 0.15);
143
- --hero-surface: rgba(255, 255, 255, 0.06);
142
+ /* Alpha of the hero foreground so the structure lines/surfaces track
143
+ the inverted hero in both themes (white-on-dark in light mode,
144
+ dark-on-light in dark mode) instead of vanishing white-on-white. */
145
+ --hero-border: color-mix(in srgb, var(--hero-text) 18%, transparent);
146
+ --hero-surface: color-mix(in srgb, var(--hero-text) 7%, transparent);
144
147
  position: relative; overflow: hidden; background: var(--hero-bg); padding: 56px 0 48px;
145
148
  }
146
149
  .cpub-hero-pattern { position: absolute; inset: 0; }
@@ -227,7 +227,10 @@ const tocActiveId = ref('');
227
227
  function scrollToHeading(id: string): void {
228
228
  const el = document.getElementById(id);
229
229
  if (el) {
230
- el.scrollIntoView({ behavior: 'smooth', block: 'start' });
230
+ // CSS scroll-behavior is reduced-motion-gated in base.css, but the JS
231
+ // smooth option ignores that — honour the preference explicitly.
232
+ const reduceMotion = window.matchMedia('(prefers-reduced-motion: reduce)').matches;
233
+ el.scrollIntoView({ behavior: reduceMotion ? 'auto' : 'smooth', block: 'start' });
231
234
  tocActiveId.value = id;
232
235
  }
233
236
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@commonpub/layer",
3
- "version": "0.21.6",
3
+ "version": "0.21.7",
4
4
  "type": "module",
5
5
  "main": "./nuxt.config.ts",
6
6
  "files": [
@@ -51,15 +51,15 @@
51
51
  "vue-router": "^4.3.0",
52
52
  "zod": "^4.3.6",
53
53
  "@commonpub/docs": "0.6.3",
54
- "@commonpub/config": "0.12.0",
55
- "@commonpub/learning": "0.5.2",
56
- "@commonpub/auth": "0.6.0",
57
- "@commonpub/explainer": "0.7.12",
58
- "@commonpub/schema": "0.16.0",
59
54
  "@commonpub/editor": "0.7.9",
55
+ "@commonpub/explainer": "0.7.13",
60
56
  "@commonpub/protocol": "0.9.10",
57
+ "@commonpub/config": "0.12.0",
58
+ "@commonpub/learning": "0.5.2",
61
59
  "@commonpub/server": "2.53.1",
62
- "@commonpub/ui": "0.8.5"
60
+ "@commonpub/ui": "0.8.5",
61
+ "@commonpub/schema": "0.16.0",
62
+ "@commonpub/auth": "0.6.0"
63
63
  },
64
64
  "devDependencies": {
65
65
  "@testing-library/jest-dom": "^6.9.1",
@@ -1229,7 +1229,7 @@ async function createVersion(): Promise<void> {
1229
1229
  position: fixed;
1230
1230
  inset: 0;
1231
1231
  z-index: 10000;
1232
- background: rgba(0, 0, 0, 0.5);
1232
+ background: var(--color-surface-overlay, rgba(0, 0, 0, 0.5));
1233
1233
  display: flex;
1234
1234
  align-items: flex-start;
1235
1235
  justify-content: center;
@@ -1402,7 +1402,7 @@ async function createVersion(): Promise<void> {
1402
1402
  }
1403
1403
 
1404
1404
  .cpub-settings-danger {
1405
- background: rgba(224, 64, 48, 0.03);
1405
+ background: var(--red-bg);
1406
1406
  }
1407
1407
 
1408
1408
  .cpub-settings-danger .cpub-settings-section-title {
@@ -1410,7 +1410,7 @@ async function createVersion(): Promise<void> {
1410
1410
  }
1411
1411
 
1412
1412
  .cpub-settings-danger-text {
1413
- font-size: 12px;
1413
+ font-size: var(--text-xs);
1414
1414
  color: var(--text-dim);
1415
1415
  margin-bottom: 10px;
1416
1416
  }