From 7fe8d7e96f6998b99098914fc4f844257dd1e79e Mon Sep 17 00:00:00 2001 From: JimmFly Date: Fri, 6 Sep 2024 10:06:19 +0000 Subject: [PATCH] fix(core): adjust editor settings preview style (#8146) close PD-1680 PD-1682 PD-1683 https://github.com/user-attachments/assets/49ed9ffe-8e8f-403d-91a0-e42b7f4ffb04 --- .../general-setting/editor/edgeless/note.tsx | 1 + .../general-setting/editor/edgeless/shape.tsx | 39 +++++++++++++------ .../editor/edgeless/snapshot.tsx | 3 +- .../general-setting/editor/style.css.ts | 24 ++++++++++++ 4 files changed, 54 insertions(+), 13 deletions(-) diff --git a/packages/frontend/core/src/components/affine/setting-modal/general-setting/editor/edgeless/note.tsx b/packages/frontend/core/src/components/affine/setting-modal/general-setting/editor/edgeless/note.tsx index a5548870c7..6f1864bf54 100644 --- a/packages/frontend/core/src/components/affine/setting-modal/general-setting/editor/edgeless/note.tsx +++ b/packages/frontend/core/src/components/affine/setting-modal/general-setting/editor/edgeless/note.tsx @@ -178,6 +178,7 @@ export const NoteSettings = () => { docName="note" keyName="affine:note" getElements={getElements} + height={240} /> { }; const isSelected = fillColor === value; return ( - + } + > {name} ); @@ -221,7 +231,12 @@ export const ShapeSettings = () => { }; const isSelected = strokeColor === value; return ( - + } + > {name} ); @@ -306,7 +321,12 @@ export const ShapeSettings = () => { }; const isSelected = color === value; return ( - + } + > {name} ); @@ -373,20 +393,15 @@ export const ShapeSettings = () => { firstUpdate={firstUpdate} > diff --git a/packages/frontend/core/src/components/affine/setting-modal/general-setting/editor/edgeless/snapshot.tsx b/packages/frontend/core/src/components/affine/setting-modal/general-setting/editor/edgeless/snapshot.tsx index 44b60afc92..31a46e57e5 100644 --- a/packages/frontend/core/src/components/affine/setting-modal/general-setting/editor/edgeless/snapshot.tsx +++ b/packages/frontend/core/src/components/affine/setting-modal/general-setting/editor/edgeless/snapshot.tsx @@ -12,7 +12,7 @@ import { isEqual } from 'lodash-es'; import { useCallback, useEffect, useRef } from 'react'; import { map, pairwise } from 'rxjs'; -import { snapshotContainer, snapshotTitle } from '../style.css'; +import { snapshotContainer, snapshotLabel, snapshotTitle } from '../style.css'; import { type DocName, getDocByName } from './docs'; import { getFrameBlock } from './utils'; @@ -126,6 +126,7 @@ export const EdgelessSnapshot = (props: Props) => { return (
{title}
+
{title}