|
|
@@ -26,6 +26,7 @@ import { DrawioViewerScript } from '~/components/Script/DrawioViewerScript';
|
|
|
import { SupportedAction, type SupportedActionType } from '~/interfaces/activity';
|
|
|
import type { CrowiRequest } from '~/interfaces/crowi-request';
|
|
|
import type { RendererConfig } from '~/interfaces/services/renderer';
|
|
|
+import type { ISidebarConfig } from '~/interfaces/sidebar-config';
|
|
|
import type { PageModel, PageDocument } from '~/server/models/page';
|
|
|
import type { PageRedirectModel } from '~/server/models/page-redirect';
|
|
|
import {
|
|
|
@@ -47,7 +48,6 @@ import {
|
|
|
} from '~/stores/page';
|
|
|
import { useRedirectFrom } from '~/stores/page-redirect';
|
|
|
import { useRemoteRevisionId } from '~/stores/remote-latest-page';
|
|
|
-import { useSelectedGrant } from '~/stores/ui';
|
|
|
import { useSetupGlobalSocket, useSetupGlobalSocketForPage } from '~/stores/websocket';
|
|
|
import loggerFactory from '~/utils/logger';
|
|
|
|
|
|
@@ -149,6 +149,8 @@ type Props = CommonProps & {
|
|
|
isSearchScopeChildrenAsDefault: boolean,
|
|
|
isEnabledMarp: boolean,
|
|
|
|
|
|
+ sidebarConfig: ISidebarConfig,
|
|
|
+
|
|
|
isSlackConfigured: boolean,
|
|
|
// isMailerSetup: boolean,
|
|
|
isAclEnabled: boolean,
|
|
|
@@ -530,6 +532,11 @@ function injectServerConfigurations(context: GetServerSidePropsContext, props: P
|
|
|
|
|
|
props.isEnabledAttachTitleHeader = configManager.getConfig('crowi', 'customize:isEnabledAttachTitleHeader');
|
|
|
|
|
|
+ props.sidebarConfig = {
|
|
|
+ isSidebarCollapsedMode: configManager.getConfig('crowi', 'customize:isSidebarCollapsedMode'),
|
|
|
+ isSidebarClosedAtDockMode: configManager.getConfig('crowi', 'customize:isSidebarClosedAtDockMode'),
|
|
|
+ };
|
|
|
+
|
|
|
props.rendererConfig = {
|
|
|
isEnabledLinebreaks: configManager.getConfig('markdown', 'markdown:isEnabledLinebreaks'),
|
|
|
isEnabledLinebreaksInComments: configManager.getConfig('markdown', 'markdown:isEnabledLinebreaksInComments'),
|