From f9fff3d824802f3dc073221b6bc6f0ea6738e5e5 Mon Sep 17 00:00:00 2001 From: bepyan Date: Thu, 22 Aug 2024 02:50:22 +0900 Subject: [PATCH] =?UTF-8?q?feat:=20seo=20description=20=EC=97=B0=EB=8F=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../editor/sidebar/sidebar-settings-tab.tsx | 18 ++++++++++++++++-- src/lib/db/schema/invitations.query.ts | 1 + 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/src/components/editor/sidebar/sidebar-settings-tab.tsx b/src/components/editor/sidebar/sidebar-settings-tab.tsx index 03b45c2..2fdd94c 100644 --- a/src/components/editor/sidebar/sidebar-settings-tab.tsx +++ b/src/components/editor/sidebar/sidebar-settings-tab.tsx @@ -175,6 +175,7 @@ function SEOSection() { mutationFn: async () => { await updateInvitation({ id: editor.config.invitationId, + description: editor.config.invitationDesc, thumbnailUrl: editor.config.invitationThumbnail, }); }, @@ -198,7 +199,7 @@ function SEOSection() { 링크 공유시 보여지는 정보를 설정해보세요.

-
+
{ @@ -217,7 +218,6 @@ function SEOSection() { id="invitationThumbnail" disabled={isPending} componentPrefix={"이미지 링크"} - className="mt-1" defaultValue={editor.config.invitationThumbnail} onDebounceChange={(e) => { dispatch({ @@ -228,6 +228,20 @@ function SEOSection() { }); }} /> + { + dispatch({ + type: "UPDATE_CONFIG", + payload: { + invitationDesc: e.target.value, + }, + }); + }} + />
diff --git a/src/lib/db/schema/invitations.query.ts b/src/lib/db/schema/invitations.query.ts index 87b57d1..906b4a0 100644 --- a/src/lib/db/schema/invitations.query.ts +++ b/src/lib/db/schema/invitations.query.ts @@ -19,6 +19,7 @@ type CreateInvitationParams = Omit< type UpdateInvitationParams = { id: Invitation["id"]; title?: Invitation["title"]; + description?: Invitation["description"]; customFields?: Invitation["customFields"]; eventUrl?: Invitation["eventUrl"]; thumbnailUrl?: Invitation["thumbnailUrl"];