merge main

This commit is contained in:
zxhlyh
2025-05-20 14:03:54 +08:00
221 changed files with 6686 additions and 3306 deletions

View File

@ -7,6 +7,7 @@ import type {
WeightedScoreEnum,
} from '@/models/datasets'
import type { UploadFileSetting } from '@/app/components/workflow/types'
import type { AccessMode } from '@/models/access-control'
export enum Theme {
light = 'light',
@ -359,6 +360,8 @@ export type App = {
updated_at: number
updated_by?: string
}
/** access control */
access_mode: AccessMode
}
export type AppSSO = {

View File

@ -23,7 +23,6 @@ export type SystemFeatures = {
sso_enforced_for_signin_protocol: SSOProtocol | ''
sso_enforced_for_web: boolean
sso_enforced_for_web_protocol: SSOProtocol | ''
enable_web_sso_switch_component: boolean
enable_marketplace: boolean
enable_email_code_login: boolean
enable_email_password_login: boolean
@ -32,6 +31,22 @@ export type SystemFeatures = {
is_allow_register: boolean
is_email_setup: boolean
license: License
branding: {
enabled: boolean
login_page_logo: string
workspace_logo: string
favicon: string
application_title: string
}
webapp_auth: {
enabled: boolean
allow_sso: boolean
sso_config: {
protocol: SSOProtocol | ''
}
allow_email_code_login: boolean
allow_email_password_login: boolean
}
}
export const defaultSystemFeatures: SystemFeatures = {
@ -39,7 +54,6 @@ export const defaultSystemFeatures: SystemFeatures = {
sso_enforced_for_signin_protocol: '',
sso_enforced_for_web: false,
sso_enforced_for_web_protocol: '',
enable_web_sso_switch_component: false,
enable_marketplace: false,
enable_email_code_login: false,
enable_email_password_login: false,
@ -51,4 +65,20 @@ export const defaultSystemFeatures: SystemFeatures = {
status: LicenseStatus.NONE,
expired_at: '',
},
branding: {
enabled: false,
login_page_logo: '',
workspace_logo: '',
favicon: '',
application_title: 'test title',
},
webapp_auth: {
enabled: false,
allow_sso: false,
sso_config: {
protocol: '',
},
allow_email_code_login: false,
allow_email_password_login: false,
},
}