From 77cfb82645262daf866bfe59be5437ed3503c863 Mon Sep 17 00:00:00 2001 From: Aaryan Khandelwal Date: Tue, 21 Jan 2025 19:23:49 +0530 Subject: [PATCH 1/2] fix: sticky placeholder --- web/core/components/editor/sticky-editor/editor.tsx | 2 -- web/core/components/stickies/sticky/inputs.tsx | 8 +++++++- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/web/core/components/editor/sticky-editor/editor.tsx b/web/core/components/editor/sticky-editor/editor.tsx index 376a317c8c6..d31090b516e 100644 --- a/web/core/components/editor/sticky-editor/editor.tsx +++ b/web/core/components/editor/sticky-editor/editor.tsx @@ -43,7 +43,6 @@ export const StickyEditor = React.forwardRef <>, }} - placeholder={placeholder} containerClassName={cn(containerClassName, "relative")} {...rest} /> diff --git a/web/core/components/stickies/sticky/inputs.tsx b/web/core/components/stickies/sticky/inputs.tsx index e56f6927e04..b3a81cd6cc2 100644 --- a/web/core/components/stickies/sticky/inputs.tsx +++ b/web/core/components/stickies/sticky/inputs.tsx @@ -4,6 +4,8 @@ import { Controller, useForm } from "react-hook-form"; import { EditorRefApi } from "@plane/editor"; // plane types import { TSticky } from "@plane/types"; +// plane utils +import { isCommentEmpty } from "@plane/utils"; // hooks import { useWorkspace } from "@/hooks/store"; // components @@ -67,7 +69,11 @@ export const StickyInput = (props: TProps) => { onChange(description_html); handleSubmit(handleFormSubmit)(); }} - placeholder="Click to type here" + placeholder={(_, value) => { + const isContentEmpty = isCommentEmpty(value); + if (!isContentEmpty) return ""; + return "Click to type here"; + }} containerClassName="px-0 text-base min-h-[250px] w-full" uploadFile={async () => ""} showToolbar={showToolbar} From 8539e6ee6f07855ac99b4bf9025ddaa79ac305a5 Mon Sep 17 00:00:00 2001 From: Aaryan Khandelwal Date: Tue, 21 Jan 2025 19:27:42 +0530 Subject: [PATCH 2/2] chore: update gray color --- web/core/components/editor/sticky-editor/color-palette.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/core/components/editor/sticky-editor/color-palette.tsx b/web/core/components/editor/sticky-editor/color-palette.tsx index f6586121afc..a4fe05b7779 100644 --- a/web/core/components/editor/sticky-editor/color-palette.tsx +++ b/web/core/components/editor/sticky-editor/color-palette.tsx @@ -8,7 +8,7 @@ export const STICKY_COLORS_LIST: { { key: "gray", label: "Gray", - backgroundColor: "var(--editor-colors-gray-background)", + backgroundColor: "rgba(var(--color-background-90))", }, { key: "peach",