mirror of
https://git.sr.ht/~cadence/bibliogram
synced 2026-03-01 18:31:35 +00:00
Add onion location
This commit is contained in:
parent
64ab9cfcee
commit
a13daa7ced
7 changed files with 22 additions and 10 deletions
|
|
@ -21,7 +21,8 @@ module.exports = [
|
|||
rssEnabled: constants.feeds.enabled,
|
||||
allUnblocked: history.testNoneBlocked() || assistantSwitcher.displaySomeUnblocked(),
|
||||
torAvailable: switcher.canUseTor(),
|
||||
hasPrivacyPolicy: constants.has_privacy_policy
|
||||
hasPrivacyPolicy: constants.has_privacy_policy,
|
||||
onionLocation: constants.onion_location
|
||||
})
|
||||
}
|
||||
},
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ let commit = ""
|
|||
|
||||
// Set up inner versioning
|
||||
|
||||
const displayVersions = ["1.0", "1.1", "1.2", "1.3", "1.4"]
|
||||
const displayVersions = ["1.0", "1.1", "1.2", "1.3", "1.4", "1.5"]
|
||||
const versions = new Map(displayVersions.map(v => [v, semver.coerce(v)]))
|
||||
const features = [
|
||||
"PAGE_PROFILE",
|
||||
|
|
@ -78,6 +78,11 @@ const innerMap = new Map()
|
|||
canonicalOrigin: constants.website_origin
|
||||
}
|
||||
})
|
||||
addVersion("1.5", {
|
||||
settings: {
|
||||
onionLocation: constants.onion_location
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
module.exports = [
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
//- Needs rssEnabled, allUnblocked, torAvailable, hasPrivacyPolicy
|
||||
//- Needs rssEnabled, allUnblocked, torAvailable, hasPrivacyPolicy, onionLocation
|
||||
|
||||
doctype html
|
||||
html
|
||||
|
|
@ -36,6 +36,8 @@ html
|
|||
|
||||
h2 About this instance
|
||||
ul
|
||||
if onionLocation
|
||||
li: a(href=onionLocation) Onion site available
|
||||
li: a(href=settingsReferrer) Settings
|
||||
if hasPrivacyPolicy
|
||||
li: a(href="/privacy") Privacy policy
|
||||
|
|
|
|||
|
|
@ -22,7 +22,8 @@ const pinski = new Pinski({
|
|||
"Feature-Policy": deniedFeatures.map(feature => `${feature} 'none'`).join("; "),
|
||||
"Referrer-Policy": "strict-origin",
|
||||
"X-Content-Type-Options": "nosniff"
|
||||
}
|
||||
},
|
||||
onionLocation: constants.onion_location
|
||||
})
|
||||
|
||||
subdirs("pug", async (err, dirs) => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue