clean up: remove vestige of custom login url

...and put Share settings at end of Other section
pull/667/head
matt wilkie 2024-11-24 22:39:33 +07:00
parent 1f282a5973
commit 879035d16f
4 changed files with 7 additions and 8 deletions

@ -91,12 +91,12 @@ const CONTENT_WIDGETS = {
_optionsOther: [ _optionsOther: [
SearchEngineOptions, SearchEngineOptions,
TrayOptions, TrayOptions,
ShareSettingsOptions,
NoteErasureTimeoutOptions, NoteErasureTimeoutOptions,
AttachmentErasureTimeoutOptions, AttachmentErasureTimeoutOptions,
RevisionsSnapshotIntervalOptions, RevisionsSnapshotIntervalOptions,
RevisionSnapshotsLimitOptions, RevisionSnapshotsLimitOptions,
NetworkConnectionsOptions NetworkConnectionsOptions,
ShareSettingsOptions
], ],
_optionsAdvanced: [ _optionsAdvanced: [
DatabaseIntegrityCheckOptions, DatabaseIntegrityCheckOptions,

@ -102,7 +102,6 @@ const defaultOptions: DefaultOption[] = [
{ name: 'headingStyle', value: 'underline', isSynced: true }, { name: 'headingStyle', value: 'underline', isSynced: true },
{ name: 'autoCollapseNoteTree', value: 'true', isSynced: true }, { name: 'autoCollapseNoteTree', value: 'true', isSynced: true },
{ name: 'autoReadonlySizeText', value: '10000', isSynced: false }, { name: 'autoReadonlySizeText', value: '10000', isSynced: false },
{ name: 'redirectBareDomain', value: 'false', isSynced: true },
{ name: 'autoReadonlySizeCode', value: '30000', isSynced: false }, { name: 'autoReadonlySizeCode', value: '30000', isSynced: false },
{ name: 'dailyBackupEnabled', value: 'true', isSynced: false }, { name: 'dailyBackupEnabled', value: 'true', isSynced: false },
{ name: 'weeklyBackupEnabled', value: 'true', isSynced: false }, { name: 'weeklyBackupEnabled', value: 'true', isSynced: false },
@ -138,8 +137,9 @@ const defaultOptions: DefaultOption[] = [
{ name: "textNoteEditorType", value: "ckeditor-balloon", isSynced: true }, { name: "textNoteEditorType", value: "ckeditor-balloon", isSynced: true },
{ name: "layoutOrientation", value: "vertical", isSynced: false }, { name: "layoutOrientation", value: "vertical", isSynced: false },
{ name: 'shareRedirectUrl', value: 'share', isSynced: true },
{ name: 'loginRedirectUrl', value: 'login', isSynced: true }, // Share settings
{ name: 'redirectBareDomain', value: 'false', isSynced: true },
{ name: 'showLoginInShareTheme', value: 'false', isSynced: true } { name: 'showLoginInShareTheme', value: 'false', isSynced: true }
]; ];

@ -158,8 +158,7 @@ function register(router: Router) {
const { header, content, isEmpty } = contentRenderer.getContent(note); const { header, content, isEmpty } = contentRenderer.getContent(note);
const subRoot = getSharedSubTreeRoot(note); const subRoot = getSharedSubTreeRoot(note);
const showLoginInShareTheme = optionService.getOption('showLoginInShareTheme'); const showLoginInShareTheme = optionService.getOption('showLoginInShareTheme');
const loginRedirectUrl = optionService.getOption('loginRedirectUrl'); const opts = { note, header, content, isEmpty, subRoot, assetPath, appPath, showLoginInShareTheme };
const opts = { note, header, content, isEmpty, subRoot, assetPath, appPath, showLoginInShareTheme, loginRedirectUrl };
let useDefaultView = true; let useDefaultView = true;
// Check if the user has their own template // Check if the user has their own template

@ -91,7 +91,7 @@
<footer> <footer>
<% if (showLoginInShareTheme === 'true') { %> <% if (showLoginInShareTheme === 'true') { %>
<p><a href="<%= loginRedirectUrl %>" class="login-link"><%= loginRedirectUrl %></a></p> <p><a href="/login" class="login-link">Login</a></p>
<% } %> <% } %>
</footer> </footer>
</body> </body>