mirror of
				https://github.com/TriliumNext/Notes.git
				synced 2025-10-31 21:11:30 +08:00 
			
		
		
		
	reduce top margin of first paragraph in text, closes #1286
This commit is contained in:
		
							parent
							
								
									1a262fe680
								
							
						
					
					
						commit
						a7f510783d
					
				| @ -38,6 +38,10 @@ const TPL = ` | |||||||
|         cursor: text !important; |         cursor: text !important; | ||||||
|     } |     } | ||||||
|      |      | ||||||
|  |     .note-detail-editable-text *:first-child { | ||||||
|  |         margin-top: 0 !important; | ||||||
|  |     } | ||||||
|  |      | ||||||
|     .note-detail-editable-text h1 { font-size: 2.0em; } |     .note-detail-editable-text h1 { font-size: 2.0em; } | ||||||
|     .note-detail-editable-text h2 { font-size: 1.8em; } |     .note-detail-editable-text h2 { font-size: 1.8em; } | ||||||
|     .note-detail-editable-text h3 { font-size: 1.6em; } |     .note-detail-editable-text h3 { font-size: 1.6em; } | ||||||
| @ -59,10 +63,6 @@ const TPL = ` | |||||||
|         /* This is because with empty content height of editor is 0 and it's impossible to click into it */ |         /* This is because with empty content height of editor is 0 and it's impossible to click into it */ | ||||||
|         min-height: 500px; |         min-height: 500px; | ||||||
|     } |     } | ||||||
|      |  | ||||||
|     .note-detail-editable-text p:first-child, .note-detail-editable-text::before { |  | ||||||
|         margin-top: 0; |  | ||||||
|     } |  | ||||||
|     </style> |     </style> | ||||||
| 
 | 
 | ||||||
|     <div class="note-detail-editable-text-editor" tabindex="300"></div> |     <div class="note-detail-editable-text-editor" tabindex="300"></div> | ||||||
|  | |||||||
| @ -49,6 +49,10 @@ function isInAncestor(noteId, ancestorNoteId) { | |||||||
| 
 | 
 | ||||||
|     const note = noteCache.notes[noteId]; |     const note = noteCache.notes[noteId]; | ||||||
| 
 | 
 | ||||||
|  |     if (!note) { | ||||||
|  |         return false; | ||||||
|  |     } | ||||||
|  | 
 | ||||||
|     for (const parentNote of note.parents) { |     for (const parentNote of note.parents) { | ||||||
|         if (isInAncestor(parentNote.noteId, ancestorNoteId)) { |         if (isInAncestor(parentNote.noteId, ancestorNoteId)) { | ||||||
|             return true; |             return true; | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 zadam
						zadam