const th = require('./template-helper');
-function hAppSection(pageTitle) {
- return ` <section class="h-app hidden">
+function hAppSection(pageTitle, logoUrl) {
+ return ` <section hidden class="h-app">
<h2>h-app Information for IndieAuth Logins</h2>
- <img src="static/favicon.ico" class="u-logo">
+ <img src="${logoUrl}" class="u-logo">
<a href="" class="u-url p-name">${pageTitle}</a>
<p class="p-summary">
This is a WebSub Hub service, facilitating content distribution.
const contactHTML = options.adminContactHTML;
const footerEntries = options.manager.footerEntries;
const hubURL = options.dingus.selfBaseUrl || '<s>https://hub.example.com/</s>';
- const headElements = [];
const navLinks = [{
href: 'admin/',
text: 'Admin',
}];
- const mainContent = [
+ const htmlOptions = {
+ pageTitle,
+ logoUrl: options.manager.logoUrl,
+ footerEntries,
+ navLinks,
+ };
+ const content = [
aboutSection(),
usageSection(isPublicHub, hubURL),
contactSection(contactHTML),
- hAppSection(pageTitle),
+ hAppSection(pageTitle, options.manager.logoUrl),
];
- return th.htmlTemplate(ctx, 0, pageTitle, headElements, navLinks, mainContent, footerEntries,
- );
+ return th.htmlPage(0, ctx, htmlOptions, content);
};
\ No newline at end of file