From 73f7041be01f635c4c30eddd8ac0f989247e976b Mon Sep 17 00:00:00 2001 From: Andy Smith Date: Tue, 22 Jul 2025 15:01:14 -0500 Subject: [PATCH] Hide placeholder when list is inserted --- app/assets/stylesheets/actiontext-lexical.css | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/app/assets/stylesheets/actiontext-lexical.css b/app/assets/stylesheets/actiontext-lexical.css index a77fb96a4..6bc80a8c1 100644 --- a/app/assets/stylesheets/actiontext-lexical.css +++ b/app/assets/stylesheets/actiontext-lexical.css @@ -18,8 +18,11 @@ } } + /* Lexical still uses the `lexical-editor--empty` class if you have a list + started with no other characters. Here, we won't show the placeholder if + you've clicked the List button in the toolbar. */ &.lexical-editor--empty { - .lexical-editor__content::before { + .lexical-editor__content:not(:has(ul, ol))::before { content: attr(placeholder); color: currentColor; cursor: text;