feat: footer text override option
This commit is contained in:
@@ -44,6 +44,7 @@ defaults:
|
||||
title: Wiki.js
|
||||
company: ''
|
||||
contentLicense: ''
|
||||
footerOverride: ''
|
||||
logoUrl: https://static.requarks.io/logo/wikijs-butterfly.svg
|
||||
pageExtensions:
|
||||
- md
|
||||
|
@@ -17,6 +17,7 @@ module.exports = {
|
||||
title: WIKI.config.title,
|
||||
company: WIKI.config.company,
|
||||
contentLicense: WIKI.config.contentLicense,
|
||||
footerOverride: WIKI.config.footerOverride,
|
||||
logoUrl: WIKI.config.logoUrl,
|
||||
pageExtensions: WIKI.config.pageExtensions.join(', '),
|
||||
...WIKI.config.seo,
|
||||
@@ -60,6 +61,10 @@ module.exports = {
|
||||
WIKI.config.contentLicense = args.contentLicense
|
||||
}
|
||||
|
||||
if (args.hasOwnProperty('footerOverride')) {
|
||||
WIKI.config.footerOverride = args.footerOverride
|
||||
}
|
||||
|
||||
if (args.hasOwnProperty('logoUrl')) {
|
||||
WIKI.config.logoUrl = _.trim(args.logoUrl)
|
||||
}
|
||||
@@ -120,7 +125,7 @@ module.exports = {
|
||||
forceDownload: _.get(args, 'uploadForceDownload', WIKI.config.uploads.forceDownload)
|
||||
}
|
||||
|
||||
await WIKI.configSvc.saveToDb(['host', 'title', 'company', 'contentLicense', 'seo', 'logoUrl', 'pageExtensions', 'auth', 'editShortcuts', 'features', 'security', 'uploads'])
|
||||
await WIKI.configSvc.saveToDb(['host', 'title', 'company', 'contentLicense', 'footerOverride', 'seo', 'logoUrl', 'pageExtensions', 'auth', 'editShortcuts', 'features', 'security', 'uploads'])
|
||||
|
||||
if (WIKI.config.security.securityTrustProxy) {
|
||||
WIKI.app.enable('trust proxy')
|
||||
|
@@ -32,6 +32,7 @@ type SiteMutation {
|
||||
analyticsId: String
|
||||
company: String
|
||||
contentLicense: String
|
||||
footerOverride: String
|
||||
logoUrl: String
|
||||
pageExtensions: String
|
||||
authAutoLogin: Boolean
|
||||
@@ -81,6 +82,7 @@ type SiteConfig {
|
||||
analyticsId: String
|
||||
company: String
|
||||
contentLicense: String
|
||||
footerOverride: String
|
||||
logoUrl: String
|
||||
pageExtensions: String
|
||||
authAutoLogin: Boolean
|
||||
|
@@ -154,6 +154,7 @@ module.exports = async () => {
|
||||
rtl: WIKI.config.lang.rtl,
|
||||
company: WIKI.config.company,
|
||||
contentLicense: WIKI.config.contentLicense,
|
||||
footerOverride: WIKI.config.footerOverride,
|
||||
logoUrl: WIKI.config.logoUrl
|
||||
}
|
||||
res.locals.langs = await WIKI.models.locales.getNavLocales({ cache: true })
|
||||
|
@@ -160,7 +160,7 @@ module.exports = {
|
||||
fNames.old = fMatch[1]
|
||||
fNames.new = fMatch[4]
|
||||
} else {
|
||||
fNames.old = (fMatch[1] + fMatch[2] + fMatch[4]).replace('//', '/'),
|
||||
fNames.old = (fMatch[1] + fMatch[2] + fMatch[4]).replace('//', '/')
|
||||
fNames.new = (fMatch[1] + fMatch[3] + fMatch[4]).replace('//', '/')
|
||||
}
|
||||
const fPath = path.join(this.repoPath, fNames.new)
|
||||
|
Reference in New Issue
Block a user