openvibers/openrestream Commits
Sign in with a button on signed-out pages (#169)
Changes
@@@ -114,7 +114,8 @@ ${twinHead}${icon}<script src="${ovServe.url('theme-loader.js')}" defer></script><style>${CSS}</style>--${styles.map((name) => `<link rel="stylesheet" href="${esc(ovServe.url(name))}">`).join('\n')}++<!-- The shared showcase stylesheet on every page, not only the home: inner pages use its buttons (sc-btn), and without it a sign-in button drew as a bare link (phone sweep, 2026-11-01). It is scoped to its own sc- classes. -->++${[...new Set(['showcase.css', ...styles])].map((name) => `<link rel="stylesheet" href="${esc(ovServe.url(name))}">`).join('\n')}<script src="${ovServe.url('navbar.js')}" defer></script><script src="${ovServe.url('footer.js')}" defer></script></head>@@@ -77,7 +77,7 @@ function createUiRouter({ rt, auth, limits = null, liveLink = null }) {if (req.caller.kind === 'user' && req.caller.subject) return true;page(req, res, {title: 'Sign in', canonicalPath: req.path,-- body: `<h1>Sign in</h1><p>OpenRestream uses your OpenVibe account.</p><p><a href="/auth/login?next=${encodeURIComponent(req.originalUrl)}">Sign in with OpenVibe</a></p>`,++ body: `<h1>Sign in</h1><p>OpenRestream uses your OpenVibe account.</p><p><a class="sc-btn sc-primary" href="/auth/login?next=${encodeURIComponent(req.originalUrl)}">Sign in with OpenVibe</a></p>`,}, 401);return false;}
@@ -114,7 +114,8 @@ ${twinHead}
@@ -114,7 +114,8 @@ ${twinHead}
${icon}
${icon}
<script src="${ovServe.url('theme-loader.js')}" defer></script>
<script src="${ovServe.url('theme-loader.js')}" defer></script>
<style>${CSS}</style>
<style>${CSS}</style>
-${styles.map((name) => `<link rel="stylesheet" href="${esc(ovServe.url(name))}">`).join('\n')}
+<!-- The shared showcase stylesheet on every page, not only the home: inner pages use its buttons (sc-btn), and without it a sign-in button drew as a bare link (phone sweep, 2026-11-01). It is scoped to its own sc- classes. -->
+${[...new Set(['showcase.css', ...styles])].map((name) => `<link rel="stylesheet" href="${esc(ovServe.url(name))}">`).join('\n')}
<script src="${ovServe.url('navbar.js')}" defer></script>
<script src="${ovServe.url('navbar.js')}" defer></script>
<script src="${ovServe.url('footer.js')}" defer></script>
<script src="${ovServe.url('footer.js')}" defer></script>
</head>
</head>
@@ -77,7 +77,7 @@ function createUiRouter({ rt, auth, limits = null, liveLink = null }) {
@@ -77,7 +77,7 @@ function createUiRouter({ rt, auth, limits = null, liveLink = null }) {
if (req.caller.kind === 'user' && req.caller.subject) return true;
if (req.caller.kind === 'user' && req.caller.subject) return true;
page(req, res, {
page(req, res, {
title: 'Sign in', canonicalPath: req.path,
title: 'Sign in', canonicalPath: req.path,
- body: `<h1>Sign in</h1><p>OpenRestream uses your OpenVibe account.</p><p><a href="/auth/login?next=${encodeURIComponent(req.originalUrl)}">Sign in with OpenVibe</a></p>`,
+ body: `<h1>Sign in</h1><p>OpenRestream uses your OpenVibe account.</p><p><a class="sc-btn sc-primary" href="/auth/login?next=${encodeURIComponent(req.originalUrl)}">Sign in with OpenVibe</a></p>`,
}, 401);
}, 401);
return false;
return false;
}
}