openvibers/openvibe.events Commits
Events: a phone no longer scrolls sideways on the home (#146)
Changes
@@@ -266,7 +266,7 @@ function sections({ apiUrl, stats = null }) {// footer meets the edges; each curl sample on its own full-width row (three columns cut every command off); the four// webhook steps two by two instead of three and one alone, each title level with its number.// The data sections' rules follow: the stat tiles, the per-service bars, the public event cards and the questions, in theme tokens (accent-light is drawn for dark themes, so text in it is mixed toward the text colour).--const HOME_STYLE = '<style>body{margin:0}.page .sc-code{grid-template-columns:minmax(0,1fr)}.page .sc-steps{grid-template-columns:repeat(auto-fit,minmax(min(100%,420px),1fr))}.page .sc-steps li{align-items:start;align-content:start}.page .sc-steps b{line-height:30px}'++const HOME_STYLE = '<style>body{margin:0}/* The hero\'s aura is drawn 54px past its right edge (shared showcase, sc-hero-vis at right:-54px); without a clip the phone scrolls sideways by ~43px (2026-10-29). */.page{overflow-x:clip}.page .sc-code{grid-template-columns:minmax(0,1fr)}.page .sc-steps{grid-template-columns:repeat(auto-fit,minmax(min(100%,420px),1fr))}.page .sc-steps li{align-items:start;align-content:start}.page .sc-steps b{line-height:30px}'+ '.page{--hm-accent-text:color-mix(in srgb,var(--accent-light,#60a5fa) 45%,var(--text-primary,#e6edf7))}.sc-eyebrow{color:var(--hm-accent-text)}'+ '.hm-stats-sec{margin-top:40px}.hm-stats{list-style:none;margin:0;padding:0;display:grid;gap:10px;grid-template-columns:repeat(auto-fit,minmax(min(130px,100%),1fr))}'+ '.hm-stats li{display:grid;gap:2px;padding:14px 16px;border-radius:14px;border:1px solid var(--border,rgba(255,255,255,.08));background:var(--bg-secondary,#101828)}'@@@ -79,7 +79,7 @@ t('GET / as a browser: the home page, its CSP and its cache policy', async () =>assert.strictEqual(r.headers.vary, 'Accept');assert.strictEqual((r.body.match(/<h1\b/g) || []).length, 1, 'exactly one h1');// The page's own rules: the body meets the edges (no browser margin), each curl sample takes a full row.-- assert.match(r.body, /<style>body\{margin:0\}\.page \.sc-code\{grid-template-columns:minmax\(0,1fr\)\}/);++ // body margins are gone, the page clips the hero aura's spill, and the curl samples get one full-width column.\n assert.match(r.body, /<style>body\{margin:0\}[\s\S]{0,200}\.page \.sc-code\{grid-template-columns:minmax\(0,1fr\)\}/);\n assert.match(r.body, /\.page\{overflow-x:clip\}/);assert.ok(r.body.includes('Events your services'), 'the hero text');assert.ok(r.body.includes(`<link rel="canonical" href="${SITE}/">`), 'the canonical product origin');assert.ok(r.body.includes(`The API is at ${SITE}`), 'the hero note names the API origin');
@@ -266,7 +266,7 @@ function sections({ apiUrl, stats = null }) {
@@ -266,7 +266,7 @@ function sections({ apiUrl, stats = null }) {
// footer meets the edges; each curl sample on its own full-width row (three columns cut every command off); the four
// footer meets the edges; each curl sample on its own full-width row (three columns cut every command off); the four
// webhook steps two by two instead of three and one alone, each title level with its number.
// webhook steps two by two instead of three and one alone, each title level with its number.
// The data sections' rules follow: the stat tiles, the per-service bars, the public event cards and the questions, in theme tokens (accent-light is drawn for dark themes, so text in it is mixed toward the text colour).
// The data sections' rules follow: the stat tiles, the per-service bars, the public event cards and the questions, in theme tokens (accent-light is drawn for dark themes, so text in it is mixed toward the text colour).
-const HOME_STYLE = '<style>body{margin:0}.page .sc-code{grid-template-columns:minmax(0,1fr)}.page .sc-steps{grid-template-columns:repeat(auto-fit,minmax(min(100%,420px),1fr))}.page .sc-steps li{align-items:start;align-content:start}.page .sc-steps b{line-height:30px}'
+const HOME_STYLE = '<style>body{margin:0}/* The hero\'s aura is drawn 54px past its right edge (shared showcase, sc-hero-vis at right:-54px); without a clip the phone scrolls sideways by ~43px (2026-10-29). */.page{overflow-x:clip}.page .sc-code{grid-template-columns:minmax(0,1fr)}.page .sc-steps{grid-template-columns:repeat(auto-fit,minmax(min(100%,420px),1fr))}.page .sc-steps li{align-items:start;align-content:start}.page .sc-steps b{line-height:30px}'
+ '.page{--hm-accent-text:color-mix(in srgb,var(--accent-light,#60a5fa) 45%,var(--text-primary,#e6edf7))}.sc-eyebrow{color:var(--hm-accent-text)}'
+ '.page{--hm-accent-text:color-mix(in srgb,var(--accent-light,#60a5fa) 45%,var(--text-primary,#e6edf7))}.sc-eyebrow{color:var(--hm-accent-text)}'
+ '.hm-stats-sec{margin-top:40px}.hm-stats{list-style:none;margin:0;padding:0;display:grid;gap:10px;grid-template-columns:repeat(auto-fit,minmax(min(130px,100%),1fr))}'
+ '.hm-stats-sec{margin-top:40px}.hm-stats{list-style:none;margin:0;padding:0;display:grid;gap:10px;grid-template-columns:repeat(auto-fit,minmax(min(130px,100%),1fr))}'
+ '.hm-stats li{display:grid;gap:2px;padding:14px 16px;border-radius:14px;border:1px solid var(--border,rgba(255,255,255,.08));background:var(--bg-secondary,#101828)}'
+ '.hm-stats li{display:grid;gap:2px;padding:14px 16px;border-radius:14px;border:1px solid var(--border,rgba(255,255,255,.08));background:var(--bg-secondary,#101828)}'
@@ -79,7 +79,7 @@ t('GET / as a browser: the home page, its CSP and its cache policy', async () =>
@@ -79,7 +79,7 @@ t('GET / as a browser: the home page, its CSP and its cache policy', async () =>
assert.strictEqual(r.headers.vary, 'Accept');
assert.strictEqual(r.headers.vary, 'Accept');
assert.strictEqual((r.body.match(/<h1\b/g) || []).length, 1, 'exactly one h1');
assert.strictEqual((r.body.match(/<h1\b/g) || []).length, 1, 'exactly one h1');
// The page's own rules: the body meets the edges (no browser margin), each curl sample takes a full row.
// The page's own rules: the body meets the edges (no browser margin), each curl sample takes a full row.
- assert.match(r.body, /<style>body\{margin:0\}\.page \.sc-code\{grid-template-columns:minmax\(0,1fr\)\}/);
+ // body margins are gone, the page clips the hero aura's spill, and the curl samples get one full-width column.\n assert.match(r.body, /<style>body\{margin:0\}[\s\S]{0,200}\.page \.sc-code\{grid-template-columns:minmax\(0,1fr\)\}/);\n assert.match(r.body, /\.page\{overflow-x:clip\}/);
assert.ok(r.body.includes('Events your services'), 'the hero text');
assert.ok(r.body.includes('Events your services'), 'the hero text');
assert.ok(r.body.includes(`<link rel="canonical" href="${SITE}/">`), 'the canonical product origin');
assert.ok(r.body.includes(`<link rel="canonical" href="${SITE}/">`), 'the canonical product origin');
assert.ok(r.body.includes(`The API is at ${SITE}`), 'the hero note names the API origin');
assert.ok(r.body.includes(`The API is at ${SITE}`), 'the hero note names the API origin');