aboutsummaryrefslogtreecommitdiffhomepage
path: root/packages/models/src/plugins/server/settings
diff options
context:
space:
mode:
Diffstat (limited to 'packages/models/src/plugins/server/settings')
-rw-r--r--packages/models/src/plugins/server/settings/index.ts2
-rw-r--r--packages/models/src/plugins/server/settings/public-server.setting.ts5
-rw-r--r--packages/models/src/plugins/server/settings/register-server-setting.model.ts12
3 files changed, 19 insertions, 0 deletions
diff --git a/packages/models/src/plugins/server/settings/index.ts b/packages/models/src/plugins/server/settings/index.ts
new file mode 100644
index 000000000..4bdccaa4a
--- /dev/null
+++ b/packages/models/src/plugins/server/settings/index.ts
@@ -0,0 +1,2 @@
1export * from './public-server.setting.js'
2export * from './register-server-setting.model.js'
diff --git a/packages/models/src/plugins/server/settings/public-server.setting.ts b/packages/models/src/plugins/server/settings/public-server.setting.ts
new file mode 100644
index 000000000..0b6251aa3
--- /dev/null
+++ b/packages/models/src/plugins/server/settings/public-server.setting.ts
@@ -0,0 +1,5 @@
1import { SettingEntries } from '../managers/plugin-settings-manager.model.js'
2
3export interface PublicServerSetting {
4 publicSettings: SettingEntries
5}
diff --git a/packages/models/src/plugins/server/settings/register-server-setting.model.ts b/packages/models/src/plugins/server/settings/register-server-setting.model.ts
new file mode 100644
index 000000000..8cde8eaaa
--- /dev/null
+++ b/packages/models/src/plugins/server/settings/register-server-setting.model.ts
@@ -0,0 +1,12 @@
1import { RegisterClientFormFieldOptions } from '../../client/index.js'
2
3export type RegisterServerSettingOptions = RegisterClientFormFieldOptions & {
4 // If the setting is not private, anyone can view its value (client code included)
5 // If the setting is private, only server-side hooks can access it
6 // Mainly used by the PeerTube client to get admin config
7 private: boolean
8}
9
10export interface RegisteredServerSettings {
11 registeredSettings: RegisterServerSettingOptions[]
12}