mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-07-20 03:26:47 +08:00
fix(server): use new LocalWorkspace ServerFeature instead (#13091)
keep compatibility close AF-2720 #### PR Dependency Tree * **PR #13091** 👈 This tree was auto-generated by [Charcoal](https://github.com/danerwilliams/charcoal) <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit ## Summary by CodeRabbit * **New Features** * Added a new `LocalWorkspace` feature flag to server configuration, enabling more flexible feature management. * **Deprecations** * The `allowGuestDemoWorkspace` flag is now deprecated and will be removed in version 0.25.0. Please use the `features` array for feature checks instead. * **Bug Fixes** * Updated UI and logic throughout the app to rely on the new `LocalWorkspace` feature flag rather than the deprecated boolean flag. * **Chores** * Removed references to `allowGuestDemoWorkspace` from configuration, queries, and type definitions for improved consistency. <!-- end of auto-generated comment: release notes by coderabbit.ai --> #### PR Dependency Tree * **PR #13091** 👈 This tree was auto-generated by [Charcoal](https://github.com/danerwilliams/charcoal)
This commit is contained in:
@@ -7,7 +7,6 @@ query adminServerConfig {
|
||||
baseUrl
|
||||
name
|
||||
features
|
||||
allowGuestDemoWorkspace
|
||||
type
|
||||
initialized
|
||||
credentialsRequirement {
|
||||
|
||||
@@ -79,7 +79,6 @@ export const adminServerConfigQuery = {
|
||||
baseUrl
|
||||
name
|
||||
features
|
||||
allowGuestDemoWorkspace
|
||||
type
|
||||
initialized
|
||||
credentialsRequirement {
|
||||
@@ -2090,7 +2089,6 @@ export const serverConfigQuery = {
|
||||
baseUrl
|
||||
name
|
||||
features
|
||||
allowGuestDemoWorkspace
|
||||
type
|
||||
initialized
|
||||
credentialsRequirement {
|
||||
|
||||
@@ -7,7 +7,6 @@ query serverConfig {
|
||||
baseUrl
|
||||
name
|
||||
features
|
||||
allowGuestDemoWorkspace
|
||||
type
|
||||
initialized
|
||||
credentialsRequirement {
|
||||
|
||||
@@ -2349,7 +2349,10 @@ export enum SearchTable {
|
||||
|
||||
export interface ServerConfigType {
|
||||
__typename?: 'ServerConfigType';
|
||||
/** Whether allow guest users to create demo workspaces. */
|
||||
/**
|
||||
* Whether allow guest users to create demo workspaces.
|
||||
* @deprecated This field is deprecated, please use `features` instead. Will be removed in 0.25.0
|
||||
*/
|
||||
allowGuestDemoWorkspace: Scalars['Boolean']['output'];
|
||||
/** fetch latest available upgradable release of server */
|
||||
availableUpgrade: Maybe<ReleaseVersionType>;
|
||||
@@ -2383,6 +2386,7 @@ export enum ServerFeature {
|
||||
Copilot = 'Copilot',
|
||||
CopilotEmbedding = 'CopilotEmbedding',
|
||||
Indexer = 'Indexer',
|
||||
LocalWorkspace = 'LocalWorkspace',
|
||||
OAuth = 'OAuth',
|
||||
Payment = 'Payment',
|
||||
}
|
||||
@@ -2964,7 +2968,6 @@ export type AdminServerConfigQuery = {
|
||||
baseUrl: string;
|
||||
name: string;
|
||||
features: Array<ServerFeature>;
|
||||
allowGuestDemoWorkspace: boolean;
|
||||
type: ServerDeploymentType;
|
||||
initialized: boolean;
|
||||
availableUserFeatures: Array<FeatureType>;
|
||||
@@ -5736,7 +5739,6 @@ export type ServerConfigQuery = {
|
||||
baseUrl: string;
|
||||
name: string;
|
||||
features: Array<ServerFeature>;
|
||||
allowGuestDemoWorkspace: boolean;
|
||||
type: ServerDeploymentType;
|
||||
initialized: boolean;
|
||||
credentialsRequirement: {
|
||||
|
||||
Reference in New Issue
Block a user