Skip to content

There can be more than Notion and Miro. AFFiNE(pronounced [ə‘fain]) is a next-gen knowledge base that brings planning, sorting and creating all together. Privacy first, open-source, customizable and ready to use.

feat: add build flag `enableAllPageFilter` (#2562)

Himself6590afed1e74eb
diff --git a/apps/web/preset.config.mjs b/apps/web/preset.config.mjs
index beb9477f4c..7a7a94408d 100644
--- a/apps/web/preset.config.mjs
+++ b/apps/web/preset.config.mjs
@@ -18,6 +18,9 @@ export const blockSuiteFeatureFlags = {
* @type {import('@affine/env').BuildFlags}
*/
export const buildFlags = {
+ enableAllPageFilter: process.env.ENABLE_ALL_PAGE_FILTER
+ ? process.env.ENABLE_ALL_PAGE_FILTER === 'true'
+ : false,
enableImagePreviewModal: process.env.ENABLE_IMAGE_PREVIEW_MODAL
? process.env.ENABLE_IMAGE_PREVIEW_MODAL === 'true'
: true,
diff --git a/packages/env/src/config.ts b/packages/env/src/config.ts
index 97e3ac5af0..804b4dc611 100644
--- a/packages/env/src/config.ts
+++ b/packages/env/src/config.ts
@@ -6,6 +6,12 @@ import { z } from 'zod';
import { getUaHelper } from './ua-helper';
export const buildFlagsSchema = z.object({
+ /**
+ * todo: remove this build flag when filter feature is ready.
+ *
+ * filter feature in the all pages.
+ */
+ enableAllPageFilter: z.boolean(),
enableImagePreviewModal: z.boolean(),
enableTestProperties: z.boolean(),
enableBroadCastChannelProvider: z.boolean(),