mirror of
https://github.com/cpvalente/ontime.git
synced 2026-08-25 17:09:09 +00:00
refactor: expose public dir
This commit is contained in:
committed by
Carlos Valente
parent
82810f1cb1
commit
dd13eb31d8
@@ -7,5 +7,5 @@ export const ontimePlaceholderInfo: GetInfo = {
|
|||||||
version: '2.0.0',
|
version: '2.0.0',
|
||||||
serverPort: 4001,
|
serverPort: 4001,
|
||||||
osc: oscPlaceholderSettings,
|
osc: oscPlaceholderSettings,
|
||||||
cssOverride: '',
|
publicDir: '',
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -84,8 +84,8 @@ export default function ViewSettingsForm() {
|
|||||||
<Alert status='info' variant='ontime-on-dark-info'>
|
<Alert status='info' variant='ontime-on-dark-info'>
|
||||||
<AlertIcon />
|
<AlertIcon />
|
||||||
<AlertDescription>
|
<AlertDescription>
|
||||||
You can override the styles of the viewers with a custom CSS file. <br />
|
You can the Ontime views or customise its styles by modifying the provided CSS file. <br />
|
||||||
{info?.cssOverride && `In your installation the file is at ${info?.cssOverride}`}
|
The CSS file is in the user directory at {`${info.publicDir}/user/styles/override.css`}
|
||||||
<br />
|
<br />
|
||||||
<br />
|
<br />
|
||||||
<ExternalLink href={cssOverrideDocsUrl}>See the docs</ExternalLink>
|
<ExternalLink href={cssOverrideDocsUrl}>See the docs</ExternalLink>
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import { GetInfo, SessionStats } from 'ontime-types';
|
import { GetInfo, SessionStats } from 'ontime-types';
|
||||||
|
|
||||||
import { getDataProvider } from '../../classes/data-provider/DataProvider.js';
|
import { getDataProvider } from '../../classes/data-provider/DataProvider.js';
|
||||||
import { publicFiles } from '../../setup/index.js';
|
import { publicDir } from '../../setup/index.js';
|
||||||
import { getNetworkInterfaces } from '../../utils/networkInterfaces.js';
|
import { getNetworkInterfaces } from '../../utils/networkInterfaces.js';
|
||||||
import { socket } from '../../adapters/WebsocketAdapter.js';
|
import { socket } from '../../adapters/WebsocketAdapter.js';
|
||||||
import { getLastRequest } from '../../api-integration/integration.controller.js';
|
import { getLastRequest } from '../../api-integration/integration.controller.js';
|
||||||
@@ -44,6 +44,6 @@ export async function getInfo(): Promise<GetInfo> {
|
|||||||
version,
|
version,
|
||||||
serverPort,
|
serverPort,
|
||||||
osc,
|
osc,
|
||||||
cssOverride: publicFiles.cssOverride,
|
publicDir: publicDir.root,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ export interface GetInfo {
|
|||||||
version: string;
|
version: string;
|
||||||
serverPort: number;
|
serverPort: number;
|
||||||
osc: OSCSettings;
|
osc: OSCSettings;
|
||||||
cssOverride: string;
|
publicDir: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
export type ProjectFile = {
|
export type ProjectFile = {
|
||||||
|
|||||||
Reference in New Issue
Block a user