Skip to content

armgit / plane

Public Imported from GitHub
0

πŸ”₯πŸ”₯πŸ”₯ Open-source Jira, Linear, Monday, and ClickUp alternative. Plane is a modern project management platform to manage tasks, sprints, docs, and triage.

fix: placeholder for list items (#5389)

M. Palanikannand9b0fe2aaa50
diff --git a/packages/editor/src/styles/editor.css b/packages/editor/src/styles/editor.css
index 2ec35dc259..1117b7c5cb 100644
--- a/packages/editor/src/styles/editor.css
+++ b/packages/editor/src/styles/editor.css
@@ -79,6 +79,7 @@
-moz-appearance: textfield;
}
+/* Placeholder only for the first line in an empty editor. */
.ProseMirror p.is-editor-empty:first-child::before {
content: attr(data-placeholder);
float: left;
@@ -87,6 +88,15 @@
height: 0;
}
+/* Display Placeholders on every new line. */
+.ProseMirror p.is-empty::before {
+ content: attr(data-placeholder);
+ float: left;
+ color: rgb(var(--color-text-400));
+ pointer-events: none;
+ height: 0;
+}
+
.ProseMirror li blockquote {
margin-top: 10px;
padding-inline-start: 1em;
@@ -110,14 +120,6 @@
display: none;
}
-.ProseMirror .is-empty::before {
- content: attr(data-placeholder);
- float: left;
- color: rgb(var(--color-text-400));
- pointer-events: none;
- height: 0;
-}
-
/* Custom image styles */
.ProseMirror img {
transition: filter 0.1s ease-in-out;