From 0f9d11fd5c2e5776243192bb33028f9ae35fe872 Mon Sep 17 00:00:00 2001 From: JimmFly Date: Thu, 31 Oct 2024 05:01:52 +0000 Subject: [PATCH] feat(core): add createdBy property to default property (#8642) close AF-1563 --- packages/common/infra/src/modules/doc/constants.ts | 6 ++++++ tests/affine-local/e2e/page-properties.spec.ts | 2 ++ 2 files changed, 8 insertions(+) diff --git a/packages/common/infra/src/modules/doc/constants.ts b/packages/common/infra/src/modules/doc/constants.ts index 1aaf11f837..2fea3f35d5 100644 --- a/packages/common/infra/src/modules/doc/constants.ts +++ b/packages/common/infra/src/modules/doc/constants.ts @@ -33,4 +33,10 @@ export const BUILT_IN_CUSTOM_PROPERTY_TYPE = [ type: 'updatedAt', index: 'a0000005', }, + { + id: 'createdBy', + type: 'createdBy', + show: 'always-hide', + index: 'a0000006', + }, ] as DocCustomPropertyInfo[]; diff --git a/tests/affine-local/e2e/page-properties.spec.ts b/tests/affine-local/e2e/page-properties.spec.ts index 11e9dadf87..474735d1a8 100644 --- a/tests/affine-local/e2e/page-properties.spec.ts +++ b/tests/affine-local/e2e/page-properties.spec.ts @@ -128,6 +128,7 @@ test('property table reordering', async ({ page }) => { 'Journal', 'Created at', 'Updated at', + 'Created by', 'Number', 'Date', 'Checkbox', @@ -170,6 +171,7 @@ test('page info show more will show all properties', async ({ page }) => { 'Journal', 'Created at', 'Updated at', + 'Created by', 'Text', 'Number', 'Date',