From deeea3428e98bccc5d1352b2cde10eb5a986695f Mon Sep 17 00:00:00 2001 From: EYHN Date: Fri, 13 Jun 2025 11:28:49 +0900 Subject: [PATCH] feat(core): update build in server config (#12807) ## Summary by CodeRabbit - **New Features** - Added support for Apple as an OAuth login provider across all server configurations. - Introduced Copilot Embedding as a new server feature. - **Changes** - Updated server features to replace Captcha with Indexer in all configurations. --- .../core/src/modules/cloud/constant.ts | 40 ++++++++++++++----- 1 file changed, 30 insertions(+), 10 deletions(-) diff --git a/packages/frontend/core/src/modules/cloud/constant.ts b/packages/frontend/core/src/modules/cloud/constant.ts index 89efeb0850..3a803e5ace 100644 --- a/packages/frontend/core/src/modules/cloud/constant.ts +++ b/packages/frontend/core/src/modules/cloud/constant.ts @@ -39,12 +39,16 @@ export const BUILD_IN_SERVERS: (ServerMetadata & { config: ServerConfig })[] = config: { serverName: 'Affine Cloud', features: [ - ServerFeature.Captcha, + ServerFeature.Indexer, ServerFeature.Copilot, + ServerFeature.CopilotEmbedding, ServerFeature.OAuth, ServerFeature.Payment, ], - oauthProviders: [OAuthProviderType.Google], + oauthProviders: [ + OAuthProviderType.Google, + OAuthProviderType.Apple, + ], type: ServerDeploymentType.Affine, credentialsRequirement: { password: { @@ -63,12 +67,16 @@ export const BUILD_IN_SERVERS: (ServerMetadata & { config: ServerConfig })[] = config: { serverName: 'Affine Cloud', features: [ - ServerFeature.Captcha, + ServerFeature.Indexer, ServerFeature.Copilot, + ServerFeature.CopilotEmbedding, ServerFeature.OAuth, ServerFeature.Payment, ], - oauthProviders: [OAuthProviderType.Google], + oauthProviders: [ + OAuthProviderType.Google, + OAuthProviderType.Apple, + ], type: ServerDeploymentType.Affine, credentialsRequirement: { password: { @@ -87,12 +95,16 @@ export const BUILD_IN_SERVERS: (ServerMetadata & { config: ServerConfig })[] = config: { serverName: 'Affine Cloud', features: [ - ServerFeature.Captcha, + ServerFeature.Indexer, ServerFeature.Copilot, + ServerFeature.CopilotEmbedding, ServerFeature.OAuth, ServerFeature.Payment, ], - oauthProviders: [OAuthProviderType.Google], + oauthProviders: [ + OAuthProviderType.Google, + OAuthProviderType.Apple, + ], type: ServerDeploymentType.Affine, credentialsRequirement: { password: { @@ -111,12 +123,16 @@ export const BUILD_IN_SERVERS: (ServerMetadata & { config: ServerConfig })[] = config: { serverName: 'Affine Cloud', features: [ - ServerFeature.Captcha, + ServerFeature.Indexer, ServerFeature.Copilot, + ServerFeature.CopilotEmbedding, ServerFeature.OAuth, ServerFeature.Payment, ], - oauthProviders: [OAuthProviderType.Google], + oauthProviders: [ + OAuthProviderType.Google, + OAuthProviderType.Apple, + ], type: ServerDeploymentType.Affine, credentialsRequirement: { password: { @@ -135,12 +151,16 @@ export const BUILD_IN_SERVERS: (ServerMetadata & { config: ServerConfig })[] = config: { serverName: 'Affine Cloud', features: [ - ServerFeature.Captcha, + ServerFeature.Indexer, ServerFeature.Copilot, + ServerFeature.CopilotEmbedding, ServerFeature.OAuth, ServerFeature.Payment, ], - oauthProviders: [OAuthProviderType.Google], + oauthProviders: [ + OAuthProviderType.Google, + OAuthProviderType.Apple, + ], type: ServerDeploymentType.Affine, credentialsRequirement: { password: {